Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

Commit

Permalink
More project bump fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
barankyle committed Oct 27, 2022
1 parent c72fac9 commit af729e2
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 37 deletions.
62 changes: 30 additions & 32 deletions .github/workflows/publish-npm-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,41 +45,39 @@ jobs:
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Delete root package.json
run: rm package.json
- name: Install cross-env and ts-node
run: npm install [email protected] [email protected] [email protected] [email protected]
- name: Bump default and template project version
run: node scripts/bump-project-versions.js
- name: Run npm install
run: npm install
- name: Bump default and template project versions
run: npm run bump-project-versions
- name: Run git add
run: git add .
- name: Commit changes
run: git commit -m ${{ github.event.release.tag_name }}
- name: Push changes to new branch
run: git push --no-verify origin ${{ env.pr_branch_name }}
- name: Create version bump PR
uses: repo-sync/pull-request@v2
with:
destination_branch: ${{ github.event.release.target_commitish }}
github_token: ${{ secrets.GITHUB_TOKEN }}
source_branch: ${{ env.pr_branch_name }}
pr_title: ${{ github.event.release.tag_name }}
pr_body: Bump version to ${{ github.event.release.tag_name }}
- name: Publish to npm
run: npm run publish-no-verify
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Update package repo to GitHub Packages
run: npm run update-name-gh-package
- name: Run git add
run: git add .
- name: Commit changes
run: git commit -m 'GH Packages'
- name: Config npm registry token
run: npm config set '//npm.pkg.github.com/:_authToken' "${NPM_TOKEN}"
env:
NPM_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Publish to GitHub Packages
run: npm run publish-github
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
# - name: Create version bump PR
# uses: repo-sync/pull-request@v2
# with:
# destination_branch: ${{ github.event.release.target_commitish }}
# github_token: ${{ secrets.GITHUB_TOKEN }}
# source_branch: ${{ env.pr_branch_name }}
# pr_title: ${{ github.event.release.tag_name }}
# pr_body: Bump version to ${{ github.event.release.tag_name }}
# - name: Publish to npm
# run: npm run publish-no-verify
# env:
# NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# - name: Update package repo to GitHub Packages
# run: npm run update-name-gh-package
# - name: Run git add
# run: git add .
# - name: Commit changes
# run: git commit -m 'GH Packages'
# - name: Config npm registry token
# run: npm config set '//npm.pkg.github.com/:_authToken' "${NPM_TOKEN}"
# env:
# NPM_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# - name: Publish to GitHub Packages
# run: npm run publish-github
# env:
# NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@
"validate": "npm run lint && lerna run validate",
"version-increment": "lerna version --conventional-commits --yes",
"version-increment-no-tag": "lerna version --conventional-commits --yes --no-git-tag-version",
"bump-project-versions": "cross-env ts-node --swc scripts/bump-project-versions.js"
"bump-project-versions": "cross-env ts-node --swc scripts/bump-project-versions.ts"
},
"types": "lib/",
"pre-commit": [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
/* eslint-disable @typescript-eslint/no-var-requires */
const fs = require('fs')
const appRootPath = require('app-root-path')
const cli = require('cli')
const path = require('path')
import fs from 'fs'
import appRootPath from 'app-root-path'
import cli from 'cli'
import path from 'path'

cli.enable('status');

Expand Down

0 comments on commit af729e2

Please sign in to comment.