Skip to content

Commit

Permalink
Use github package registry
Browse files Browse the repository at this point in the history
  • Loading branch information
bmcdorman committed Oct 27, 2022
1 parent 1a90905 commit 5bafe36
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 3 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Publish to GPR
on:
release:
types: ["created"]
jobs:
build:
runs-on: "ubuntu-latest"
timeout-minutes: 10
strategy:
fail-fast: false
matrix:
node-version: [13.x]
steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install Dependencies
run: yarn install
- name: Build
run: yarn run build
publish-gpr:
runs-on: "ubuntu-latest"
needs: ["build"]
steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
registry-url: https://npm.pkg.github.com
scope: "@kipr"
- name: Publish to GPR
run: yarn publish
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3 changes: 3 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
node_modules
.git
.gitignore
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@kipr:registry=https://npm.pkg.github.com
8 changes: 5 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@
"author": "KISS Institute for Practical Robotics",
"license": "GPLv3",
"private": false,
"publishConfig": {
"registry": "https://npm.pkg.github.com"
},
"scripts": {
"build": "tsc",
"install": "yarn run build"
"build": "tsc"
},
"peerDependencies": {
"devDependencies": {
"typescript": "^4.8.4"
}
}

0 comments on commit 5bafe36

Please sign in to comment.