docs: Updated README with how to test action

releases/v3
Tycho Bokdam 2023-03-02 11:49:44 +01:00
parent 858fe562a4
commit 997a172ef5
No known key found for this signature in database
GPG Key ID: F1180857DB997467
3 changed files with 9 additions and 30 deletions

View File

@ -7,6 +7,7 @@ on:
jobs: jobs:
release: release:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: ${{ !env.ACT }}
steps: steps:
- name: Checkout code - name: Checkout code
uses: actions/checkout@v2 uses: actions/checkout@v2

View File

@ -7,6 +7,7 @@ on:
jobs: jobs:
run-tag-latest: run-tag-latest:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: ${{ !env.ACT }}
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2

View File

@ -234,43 +234,20 @@ Use a deploy key
If you'd like to contribute to this project, all you need to do is clone and install [act](https://github.com/nektos/act) this project and run: If you'd like to contribute to this project, all you need to do is clone and install [act](https://github.com/nektos/act) this project and run:
> Make sure that `main: 'src/index.js'` is updated to `main: '../src/index.js'` inside the `action.yml`
> Note: The image used is 18 gb! > Note: The image used is 18 gb!
```shell ```shell
$ yarn install $ yarn install
# To run / test json versioning # To run / test one specific job
$ act -j test-json -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token $ act -j <workflow job name> -P ubuntu-latest=catthehacker/ubuntu:full-20.04 --quiet
# Example
$ act -j test-json -P ubuntu-latest=catthehacker/ubuntu:full-20.04 --quiet
# To run / test git versioning # To run all tests
$ act -j test-git -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token $ act pull_request -P ubuntu-latest=catthehacker/ubuntu:full-20.04 --quiet
# To run / test git fallback versioning
$ act -j test-git-fallback -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
# To run / test yaml versioning
$ act -j test-yaml -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
# To run / test toml versioning
$ act -j test-toml -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
# To run / test empty / new files test
$ act -j test-[json/toml/yaml]-[empty/new] -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
# To run pre-commit test
$ act -j test-pre-commit -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
# To run / multiple files test
$ act -j multiple-files -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
# To run / config file path test
$ act -j test-config-file-path -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
# To run pre-changelog-generation test
$ act -j test-pre-changelog-generation -P ubuntu-latest=nektos/act-environments-ubuntu:18.04 -s github_token=fake-token
``` ```
catthehacker/ubuntu:full-20.04
## [License](./LICENSE) ## [License](./LICENSE)
Conventional Changelog Action is [MIT licensed](./LICENSE). Conventional Changelog Action is [MIT licensed](./LICENSE).