Skip to content

Commit

Permalink
ci: add npm publish
Browse files Browse the repository at this point in the history
  • Loading branch information
axetroy committed Dec 5, 2020
1 parent bfc347c commit 09cb54d
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
8 changes: 7 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,16 @@ jobs:
run: |
./cmd/whatchanged/run.sh --tpl=release.tpl --output=release.md
- name: Run GoReleaser
- name: Release to Github
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist --release-notes=./release.md
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}

- name: Publish to NPM
uses: JS-DevTools/npm-publish@v1
with:
package: ./npm/package.json
token: ${{ secrets.NPM_TOKEN }}
15 changes: 13 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,17 @@ SOURCE CODE:

### Installation

#### Install via npm

```bash
# install in global
npm install -g whatchanged
# run the command once
npx whatchanged
```

#### Install via shell

If you are using Linux/macOS. you can install it with the following command:

```shell
Expand All @@ -122,10 +133,10 @@ curl -fsSL https://raw.githubusercontent.com/axetroy/whatchanged/master/install.
# or install specified version
curl -fsSL https://raw.githubusercontent.com/axetroy/whatchanged/master/install.sh | bash -s v0.2.1
# or install from gobinaries.com
curl -sf https://gobinaries.com/axetroy/[email protected].0 | sh
curl -sf https://gobinaries.com/axetroy/[email protected].2 | sh
```

Or
#### Install from Github release page

Download the executable file for your platform at [release page](https://github.com/axetroy/whatchanged/releases)

Expand Down

0 comments on commit 09cb54d

Please sign in to comment.