update engine-publish

This commit is contained in:
coyotte508 2025-08-09 21:12:20 +00:00
commit c82c1b978f
3 changed files with 696 additions and 947 deletions

View file

@ -29,9 +29,15 @@ jobs:
- run: pnpm install
- run: git config --global user.name github-actions
- run: git config --global user.email bot@github.com
- run: yarn config set version-git-message "Engine v%s"
- run: yarn version --${{ github.event.inputs.newversion }}
- run: sed -i 's:powergrid-engine:@boardgamers/powergrid-engine:' package.json
# - run: yarn config set version-git-message "Engine v%s"
# - run: yarn version --${{ github.event.inputs.newversion }}
- run: |
PACKAGE_VERSION=$(node -p "require('./package.json').version")
BUMPED_VERSION=$(node -p "require('semver').inc('$PACKAGE_VERSION', '${{ github.event.inputs.newversion }}')")
# Update package.json with the new version
node -e "const fs = require('fs'); const package = JSON.parse(fs.readFileSync('./package.json')); package.version = '$BUMPED_VERSION'; fs.writeFileSync('./package.json', JSON.stringify(package, null, '\t') + '\n');"
git add .
git commit -m "🔖 powergrid-engine $BUMPED_VERSION"
- run: pnpm publish --access public --no-git-checks .
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

View file

@ -11,6 +11,7 @@
"lint-staged": "^10.5.4",
"prettier": "^2.2.1",
"prettier-plugin-organize-imports": "^1.1.1",
"semver": "^7.7.2",
"typescript": "^4.1.5"
},
"lint-staged": {

1630
pnpm-lock.yaml generated

File diff suppressed because it is too large Load diff