setup-rokit/README.md

53 lines
2.3 KiB
Markdown
Raw Permalink Normal View History

2022-07-18 03:55:50 +01:00
<div align="center">
2024-07-15 14:52:05 +01:00
<h1><code>setup-rokit</code></h1>
2022-07-18 03:55:50 +01:00
<p>
2024-08-10 12:15:08 +01:00
<a href="https://github.com/CompeyDev/setup-rokit/actions?query=workflow%3Atest"><img src="https://github.com/CompeyDev/setup-rokit/workflows/test/badge.svg" alt="CI" /></a>
2022-07-18 03:55:50 +01:00
</p>
</div>
2024-07-15 14:52:05 +01:00
GitHub action to install and run [rokit](https://github.com/rojo-rbx/rokit); a toolchain manager.
2022-07-18 03:55:50 +01:00
## Usage
2024-07-15 14:52:05 +01:00
Use the latest released version of `rokit` with default parameters:
2022-07-18 03:55:50 +01:00
```yaml
steps:
2024-08-13 16:32:33 +01:00
- uses: CompeyDev/setup-rokit@v0.1.2
2022-07-18 03:55:50 +01:00
```
2024-07-15 14:52:05 +01:00
For a list of default parameter values, [check here](https://github.com/CompeyDev/setup-rokit/blob/main/action.yml#L5-L20).
2022-07-18 03:55:50 +01:00
2023-09-20 18:49:25 +01:00
### Advanced
For more advanced cases, use the parameters below.
```yaml
steps:
2024-08-13 16:32:33 +01:00
- uses: CompeyDev/setup-rokit@v0.1.2
with:
2024-07-15 14:52:05 +01:00
version: v1.0.0 # name of git tag in rokit (uses latest tag by default)
path: some_dir/my_project # path to project dir containing a `rokit.toml`, `aftman.toml`, or `foreman.toml` ("." (current dir) by default)
2023-12-30 05:22:08 +00:00
cache: false # whether to enable binary caching between runs (false by default)
token: ${{ github.token }} # GitHub token to bypass rate limit (${{ github.token }} set by default)
```
2022-07-18 03:55:50 +01:00
2023-12-30 05:22:08 +00:00
## Inputs
### `version`
2024-07-15 14:52:05 +01:00
The git tag of `rokit` to install from releases and use. By default this input will be assigned to the latest version of `rokit`.
2023-12-30 05:22:08 +00:00
### `path`
2024-07-15 14:52:05 +01:00
The path to the directory containing the `rokit.toml` to install tools from. The default is the current directory (`.`).
2023-12-30 05:22:08 +00:00
### `cache`
2024-07-15 14:52:05 +01:00
Enable to cache tools installed by `rokit`, the default value of this input is `false`. Note, in many cases enabling this feature will slow down the `setup-rokit` action.
2023-12-30 05:22:08 +00:00
There are a few reasons you may choose to enable caching:
* Action runs often, causing the GitHub rate-limit to be reached
* A large amount of tools to install
* Server downloading from is slow
2023-12-30 05:28:53 +00:00
In any case, it is recommended to benchmark before enabling this feature.
2023-12-30 05:22:08 +00:00
### `token`
2024-07-15 14:52:05 +01:00
Set to a GitHub token to be used by `rokit` to increase the GitHub rate-limit. Note, these two options, `${{ github.token }}` and `${{ secrets.GITHUB_TOKEN }}`, are equivalent and passed by default. **Thus, you do not need to specify this parameter unless you are using a token different from the owner of the repository.**
2023-12-30 05:22:08 +00:00
2022-07-18 03:55:50 +01:00
## Credits
2024-07-15 18:26:57 +01:00
[@ok-nick](https://github.com/ok-nick) - Creating `setup-aftman` which `setup-rokit` is a fork of
2023-12-30 05:22:08 +00:00