Skip to content

update deps

update deps #24

Workflow file for this run

name: Publish Development Package
on:
push:
branches:
- main
jobs:
publish-dev:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 22
registry-url: https://npm.pkg.github.com/
- name: Set up Git User
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "[email protected]"
- name: Install Dependencies
run: npm ci
- name: Build Package
run: npm run build
- name: Configure npm for Authenticated Access
run: |
echo "@bl1231:registry=https://npm.pkg.github.com" >> .npmrc
echo "//npm.pkg.github.com/:_authToken=${{ secrets.GITHUB_TOKEN }}" >> .npmrc
- name: Get Current Dev Version and Increment
id: version
run: |
CURRENT_VERSION=$(npm show @bl1231/bilbomd-mongodb-schema@dev version --registry=https://npm.pkg.github.com/ || echo "0.0.0-dev.0")
echo "Current Version: $CURRENT_VERSION"
NEW_VERSION=$(npx semver "$CURRENT_VERSION" --increment prerelease --preid dev)
echo "New Version: $NEW_VERSION"
echo "NEW_VERSION=$NEW_VERSION" >> $GITHUB_ENV
- name: Update Version and Publish
run: |
npm version $NEW_VERSION --no-git-tag-version
npm publish --tag dev
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}