Skip to content

Commit ee78d66

Browse files
committed
project: Add publish action and update package.json.
1 parent a0e5e20 commit ee78d66

File tree

2 files changed

+41
-3
lines changed

2 files changed

+41
-3
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
on: [push, pull_request]
2+
jobs:
3+
release:
4+
runs-on: ubuntu-latest
5+
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
6+
steps:
7+
- uses: actions/checkout@v2
8+
with:
9+
fetch-depth: 0
10+
- name: Fetch next version
11+
id: nextVersion
12+
uses: freezy/[email protected]
13+
with:
14+
tagPrefix: 'v'
15+
- name: Publish
16+
run: |
17+
echo "//registry.visualpinball.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
18+
npm version ${{ steps.nextVersion.outputs.nextVersion }} --no-git-tag-version --allow-same-version
19+
npm publish
20+
env:
21+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
22+
- name: Create Release
23+
uses: actions/create-release@v1
24+
with:
25+
tag_name: ${{ steps.nextVersion.outputs.nextTag }}
26+
release_name: ${{ steps.nextVersion.outputs.nextTag }}
27+
prerelease: ${{ steps.nextVersion.outputs.isPrerelease }}
28+
env:
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
30+

package.json

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
{
22
"name": "org.visualpinball.engine.unity.hdrp",
3-
"version": "0.1.0",
3+
"version": "0.0.1-preview.0",
44
"displayName": "Visual Pinball Engine (HDRP)",
5-
"description": "Adds support for the High Definition Render Pipeline.",
5+
"description": "High Definition Render Pipeline support",
6+
"keywords": [ "Unity", "HDRP" ],
67
"unity": "2020.2",
78
"unityRelease": "0b12",
89
"dependencies": {
@@ -20,5 +21,12 @@
2021
"Kleis Auke Wolthuizen <[email protected]>",
2122
"Eli Curtz <[email protected]>",
2223
"Pandeli"
23-
]
24+
],
25+
"repository": {
26+
"url": "https://github.com/VisualPinball/VisualPinball.Unity.Hdrp.git",
27+
"type": "git"
28+
},
29+
"publishConfig": {
30+
"registry": "https://registry.visualpinball.org"
31+
}
2432
}

0 commit comments

Comments
 (0)