mise-action/README.md

42 lines
834 B
Markdown
Raw Normal View History

# Example Workflow
2023-01-14 08:11:40 -06:00
```yaml
2023-02-21 23:34:44 -06:00
name: test
on:
pull_request:
branches:
- main
push:
branches:
- main
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
2023-08-27 12:12:44 -05:00
- uses: jdx/rtx-action@v1
2023-02-21 23:34:44 -06:00
with:
tool_versions: |
shellcheck 0.9.0
- run: shellcheck scripts/*.sh
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
2023-08-27 12:12:44 -05:00
- uses: jdx/rtx-action@v1
2023-02-21 23:34:44 -06:00
# .tool-versions will be read from repo root
- run: node ./my_app.js
2023-01-14 08:11:40 -06:00
```
2023-12-07 17:44:02 -06:00
Alternatively, rtx is easy to use in GitHub Actions even without this:
```yaml
jobs:
build:
steps:
2023-12-07 17:49:37 -06:00
- run: |
2023-12-11 16:37:16 -06:00
curl https://rtx.jdx.dev/install.sh | sh
2023-12-07 17:49:37 -06:00
echo "$HOME/.local/share/rtx/bin" >> $GITHUB_PATH
echo "$HOME/.local/share/rtx/shims" >> $GITHUB_PATH
2023-12-07 17:44:02 -06:00
```