@@ -59,15 +59,32 @@ jobs:
5959 - name : Build project
6060 run : npm run build-ui
6161
62- - name : Bump version
63- id : bump_version
62+ - name : Bump version (manual)
6463 working-directory : packages/ui
65- run : pnpm version ${{ github.event.inputs.version_type }} --no-git-tag-version --ignore-scripts
64+ id : bump
65+ run : |
66+ NEW_VERSION=$(node -e "
67+ const fs = require('fs');
68+ const pkg = require('./package.json');
69+ const type = process.env.BUMP;
70+ const semver = require('semver');
71+ pkg.version = semver.inc(pkg.version, type);
72+ fs.writeFileSync('package.json', JSON.stringify(pkg, null, 2));
73+ console.log(pkg.version);
74+ ")
75+ echo "NEW_VERSION=$NEW_VERSION" >> $GITHUB_OUTPUT
76+ env :
77+ BUMP : ${{ github.event.inputs.version_type }}
78+
79+ # - name: Bump version
80+ # id: bump_version
81+ # working-directory: packages/ui
82+ # run: pnpm version ${{ github.event.inputs.version_type }} --no-git-tag-version --ignore-scripts
6683
67- - name : Get new version
68- id : version
69- working-directory : packages/ui
70- run : echo "NEW_VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT
84+ # - name: Get new version
85+ # id: version
86+ # working-directory: packages/ui
87+ # run: echo "NEW_VERSION=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT
7188
7289 # - name: Commit version bump
7390 # run: |
7693 # git add .
7794 # git commit -m "chore: bump @orama/ui v${{ steps.version.outputs.NEW_VERSION }}"
7895 # git tag "v${{ steps.version.outputs.NEW_VERSION }}"
79- # git push origin HEAD --follow -tags
96+ # git push && git push - -tags
8097
8198 # - name: Publish to NPM
8299 # working-directory: packages/ui
0 commit comments