From 314fb72f92443c92b873466ba4a9057a1f0eba8a Mon Sep 17 00:00:00 2001 From: Simon Date: Tue, 4 Mar 2025 10:19:55 +0100 Subject: [PATCH] =?UTF-8?q?ci(#202):=20=F0=9F=91=B7=20Start=20working=20on?= =?UTF-8?q?=20CI?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add Semantic Release for automating Releasing versions --- .github/workflows/auto-release.yml | 33 ++++++++++++++++++++++++++++++ .releaserc.yml | 9 ++++++++ 2 files changed, 42 insertions(+) create mode 100644 .github/workflows/auto-release.yml create mode 100644 .releaserc.yml diff --git a/.github/workflows/auto-release.yml b/.github/workflows/auto-release.yml new file mode 100644 index 0000000..afb8b46 --- /dev/null +++ b/.github/workflows/auto-release.yml @@ -0,0 +1,33 @@ +name: Automatic Release +run-name: Release a new version of the Icons on PR's merging + +on: + pull_request: + types: + - closed + branches: + - main + +jobs: + semantic-release: + if: "!contains(github.event.head_commit.message, 'ci:')" + + name: Semantic Release + runs-on: ubuntu-latest + permissions: + contents: write + + steps: + # Checkout data from the repository + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + persist-credentials: false + + # Run Semantic-release-action with the included release + - name: Semantic Release + uses: cycjimmy/semantic-release-action@v4 + id: semantic # Need an `id` for output variables + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.releaserc.yml b/.releaserc.yml new file mode 100644 index 0000000..6114e05 --- /dev/null +++ b/.releaserc.yml @@ -0,0 +1,9 @@ +plugins: + - "@semantic-release/commit-analyzer" + - "@semantic-release/release-notes-generator" + - "@semantic-release/changelog" + - "@semantic-release/git" + - "@semantic-release/github" + +branches: + - main \ No newline at end of file