diff --git a/.github/workflows/release-backend.yaml b/.github/workflows/release-backend.yaml deleted file mode 100644 index 036c0660..00000000 --- a/.github/workflows/release-backend.yaml +++ /dev/null @@ -1,61 +0,0 @@ -name: release backend -on: - workflow_dispatch: - inputs: - bump_version: - type: choice - description: "bump version" - default: minor - options: - # major version bumps do only manually - - minor - - patch - -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: false - -jobs: - - run-checks: - uses: ./.github/workflows/code-checks.yaml - with: - branch_ref: ${{ github.ref }} - - release-python: - needs: run-checks - timeout-minutes: 20 - runs-on: ubuntu-22.04 - environment: release - permissions: - contents: write - # IMPORTANT: this permission is mandatory for trusted publishing - id-token: write - - steps: - - name: Checkout - uses: actions/checkout@v3 - with: - ref: ${{ github.ref }} - - - name: Setup git user - run: | - git config --global user.name "$(git --no-pager log --format=format:'%an' -n 1)" - git config --global user.email "$(git --no-pager log --format=format:'%ae' -n 1)" - - - name: Install poetry - run: pip install poetry - - - name: Prepare Python - uses: actions/setup-python@v4 - with: - python-version: '3.11' - cache: 'poetry' - - - name: Prepare release - run: ./bin/release-backend.sh ${{ github.event.inputs.bump_version }} - - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 - with: - packages-dir: ffun/dist/ diff --git a/.github/workflows/release-frontend.yaml b/.github/workflows/release-frontend.yaml deleted file mode 100644 index ef087c27..00000000 --- a/.github/workflows/release-frontend.yaml +++ /dev/null @@ -1,58 +0,0 @@ -name: release frontend -on: - workflow_dispatch: - inputs: - bump_version: - type: choice - description: "bump version" - default: minor - options: - # major version bumps do only manually - - minor - - patch - -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: false - -jobs: - - run-checks: - uses: ./.github/workflows/code-checks.yaml - with: - branch_ref: ${{ github.ref }} - - release-frontend: - needs: run-checks - timeout-minutes: 20 - runs-on: ubuntu-22.04 - environment: release - permissions: - contents: write - # IMPORTANT: this permission is mandatory for trusted publishing - id-token: write - - steps: - - name: Checkout - uses: actions/checkout@v3 - with: - ref: ${{ github.ref }} - - - name: Setup git user - run: | - git config --global user.name "$(git --no-pager log --format=format:'%an' -n 1)" - git config --global user.email "$(git --no-pager log --format=format:'%ae' -n 1)" - - - name: Prepare Node - uses: actions/setup-node@v3 - with: - registry-url: 'https://registry.npmjs.org' - - - name: Prepare release - run: ./bin/release-frontend.sh ${{ github.event.inputs.bump_version }} - - - name: Publish package distributions to NPM - working-directory: site - run: npm publish - env: - NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_SECRET }} diff --git a/bin/release-backend.sh b/bin/release-backend.sh deleted file mode 100755 index 90a33e83..00000000 --- a/bin/release-backend.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/usr/bin/bash - -set -e - -export BUMP_VERSION=$1 - -cd ./ffun - -echo "Bumping version as $BUMP_VERSION" - -export FFUN_VERSION=$(poetry version $BUMP_VERSION --short) -export FFUN_VERSION_TAG="backend-$FFUN_VERSION" - -echo "New version is $FFUN_VERSION" -echo "New version tag $FFUN_VERSION_TAG" - -echo "Building Python package" - -poetry build - -echo "Commit changes" - -git add -A -git commit -m "Backend release ${FFUN_VERSION}" -git push - -echo "Create tag" - -git tag $FFUN_VERSION_TAG -git push origin $FFUN_VERSION_TAG diff --git a/bin/release-frontend.sh b/bin/release-frontend.sh deleted file mode 100755 index 1b94f4f2..00000000 --- a/bin/release-frontend.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/bash - -set -e - -export BUMP_VERSION=$1 - -cd ./site - -echo "Bumping version as $BUMP_VERSION" - -export FFUN_VERSION=$(npm version --tag-version-prefix "" $BUMP_VERSION) -export FFUN_VERSION_TAG="frontend-$FFUN_VERSION" - -echo "New version is $FFUN_VERSION" -echo "New version tag $FFUN_VERSION_TAG" - -echo "Commit changes" - -git add -A -git commit -m "Frontend release ${FFUN_VERSION}" -git push - -echo "Create tag" - -git tag $FFUN_VERSION_TAG -git push origin $FFUN_VERSION_TAG