neiam /action-setup-beam
action-setup-beam
public · Issues · Pulls · Labels · Forks · Compare · Actions queued
⭐
Log in to mark this repository.
Tweak/readme (#295)
7f9edf8 · Paulo F. Oliveira · 2024-06-28 11:48
Files changed
modified
README.md
+77
−69
@@ -153,7 +153,69 @@ with the following correspondence.
| 153 | 153 | | `gleam-version` | `gleam` |
| 154 | 154 | | `rebar3-version` | `rebar` |
| 155 | 155 | |
| 156 | −### Example (Erlang/OTP + Elixir, on Ubuntu) | |
| 156 | +### Alternative hex.pm mirrors | |
| 157 | + | |
| 158 | +It is possible to use alternative hex.pm mirror(s), in their declared order, with | |
| 159 | +option `hexpm-mirrors`. By default, the action will use `builds.hex.pm`. | |
| 160 | +To use other alternative mirrors, add one per line, as shown below. | |
| 161 | + | |
| 162 | +```yaml | |
| 163 | +# create this in .github/workflows/ci.yml | |
| 164 | +on: push | |
| 165 | + | |
| 166 | +jobs: | |
| 167 | + test: | |
| 168 | + runs-on: ubuntu-latest | |
| 169 | + steps: | |
| 170 | + - uses: actions/checkout@v4 | |
| 171 | + - uses: erlef/setup-beam@v1 | |
| 172 | + with: | |
| 173 | + otp-version: '26' | |
| 174 | + # Use `cdn.jsdelivr.net/hex` as an alternative to `builds.hex.pm` | |
| 175 | + hexpm-mirrors: https://cdn.jsdelivr.net/hex | |
| 176 | +``` | |
| 177 | + | |
| 178 | +Alternatively, you may try `cdn.jsdelivr.net/hex` if `builds.hex.pm` fails: | |
| 179 | + | |
| 180 | +```yaml | |
| 181 | +# create this in .github/workflows/ci.yml | |
| 182 | +on: push | |
| 183 | + | |
| 184 | +jobs: | |
| 185 | + test: | |
| 186 | + runs-on: ubuntu-latest | |
| 187 | + steps: | |
| 188 | + - uses: actions/checkout@v4 | |
| 189 | + - uses: erlef/setup-beam@v1 | |
| 190 | + with: | |
| 191 | + otp-version: '26' | |
| 192 | + hexpm-mirrors: | | |
| 193 | + https://builds.hex.pm | |
| 194 | + https://cdn.jsdelivr.net/hex | |
| 195 | +``` | |
| 196 | + | |
| 197 | +### Environment variables | |
| 198 | + | |
| 199 | +Base installation folders (useful for e.g. fetching headers for NIFs) are available in the following | |
| 200 | +environment variables: | |
| 201 | + | |
| 202 | +- `INSTALL_DIR_FOR_OTP`: base folder for Erlang/OTP | |
| 203 | +- `INSTALL_DIR_FOR_ELIXIR`: base folder for Elixir | |
| 204 | +- `INSTALL_DIR_FOR_GLEAM`: base folder for Gleam | |
| 205 | +- `INSTALL_DIR_FOR_REBAR3`: base folder for `rebar3` | |
| 206 | + | |
| 207 | +In each of these you'll find folder `bin` where the appropriate binaries, platform-dependant, | |
| 208 | +are found (i.e. `erl`, `erl.exe`, `rebar3`, `rebar3.exe`, ...). | |
| 209 | + | |
| 210 | +### Elixir Problem Matchers | |
| 211 | + | |
| 212 | +The Elixir Problem Matchers in this repository are adapted from | |
| 213 | +[here](https://github.com/fr1zle/vscode-elixir/blob/45eddb589acd7ac98e0c7305d1c2b24668ca709a/package.json#L70-L118). | |
| 214 | +See [MATCHER_NOTICE](MATCHER_NOTICE.md) for license details. | |
| 215 | + | |
| 216 | +## Examples | |
| 217 | + | |
| 218 | +### Erlang/OTP + Elixir, on Ubuntu | |
| 157 | 219 | |
| 158 | 220 | ```yaml |
| 159 | 221 | # create this in .github/workflows/ci.yml |
@@ -177,7 +239,7 @@ jobs:
| 177 | 239 | - run: mix test |
| 178 | 240 | ``` |
| 179 | 241 | |
| 180 | −### Example (Erlang/OTP + `rebar3`, on Ubuntu) | |
| 242 | +### Erlang/OTP + `rebar3`, on Ubuntu | |
| 181 | 243 | |
| 182 | 244 | ```yaml |
| 183 | 245 | # create this in .github/workflows/ci.yml |
@@ -200,7 +262,7 @@ jobs:
| 200 | 262 | - run: rebar3 ct |
| 201 | 263 | ``` |
| 202 | 264 | |
| 203 | −### Example (Erlang/OTP + `rebar3`, on Windows) | |
| 265 | +### Erlang/OTP + `rebar3`, on Windows | |
| 204 | 266 | |
| 205 | 267 | ```yaml |
| 206 | 268 | # create this in .github/workflows/ci.yml |
@@ -218,7 +280,7 @@ jobs:
| 218 | 280 | - run: rebar3 ct |
| 219 | 281 | ``` |
| 220 | 282 | |
| 221 | −### Example (Gleam on Ubuntu) | |
| 283 | +### Gleam on Ubuntu | |
| 222 | 284 | |
| 223 | 285 | ```yaml |
| 224 | 286 | # create this in .github/workflows/ci.yml |
@@ -236,7 +298,7 @@ jobs:
| 236 | 298 | - run: gleam test |
| 237 | 299 | ``` |
| 238 | 300 | |
| 239 | −### Example (Gleam on Ubuntu without OTP) | |
| 301 | +### Gleam on Ubuntu without OTP | |
| 240 | 302 | |
| 241 | 303 | ```yaml |
| 242 | 304 | # create this in .github/workflows/ci.yml |
@@ -256,67 +318,9 @@ jobs:
| 256 | 318 | |
| 257 | 319 | **Note**: the `otp-version: false` input is only applicable when installing Gleam. |
| 258 | 320 | |
| 259 | −## Alternative hex.pm mirrors | |
| 321 | +## The project | |
| 260 | 322 | |
| 261 | −It is possible to use alternative hex.pm mirror(s), in their declared order, with | |
| 262 | −option `hexpm-mirrors`. By default, the action will use `builds.hex.pm`. | |
| 263 | −To use other alternative mirrors, add one per line, as shown below. | |
| 264 | − | |
| 265 | −```yaml | |
| 266 | −# create this in .github/workflows/ci.yml | |
| 267 | −on: push | |
| 268 | − | |
| 269 | −jobs: | |
| 270 | − test: | |
| 271 | − runs-on: ubuntu-latest | |
| 272 | − steps: | |
| 273 | − - uses: actions/checkout@v4 | |
| 274 | − - uses: erlef/setup-beam@v1 | |
| 275 | − with: | |
| 276 | − otp-version: '26' | |
| 277 | − # Use `cdn.jsdelivr.net/hex` as an alternative to `builds.hex.pm` | |
| 278 | − hexpm-mirrors: https://cdn.jsdelivr.net/hex | |
| 279 | −``` | |
| 280 | − | |
| 281 | −Alternatively, you may try `cdn.jsdelivr.net/hex` if `builds.hex.pm` fails: | |
| 282 | − | |
| 283 | −```yaml | |
| 284 | −# create this in .github/workflows/ci.yml | |
| 285 | −on: push | |
| 286 | − | |
| 287 | −jobs: | |
| 288 | − test: | |
| 289 | − runs-on: ubuntu-latest | |
| 290 | − steps: | |
| 291 | − - uses: actions/checkout@v4 | |
| 292 | − - uses: erlef/setup-beam@v1 | |
| 293 | − with: | |
| 294 | − otp-version: '26' | |
| 295 | − hexpm-mirrors: | | |
| 296 | − https://builds.hex.pm | |
| 297 | − https://cdn.jsdelivr.net/hex | |
| 298 | −``` | |
| 299 | − | |
| 300 | −## Environment variables | |
| 301 | − | |
| 302 | −Base installation folders (useful for e.g. fetching headers for NIFs) are available in the following | |
| 303 | −environment variables: | |
| 304 | − | |
| 305 | −- `INSTALL_DIR_FOR_OTP`: base folder for Erlang/OTP | |
| 306 | −- `INSTALL_DIR_FOR_ELIXIR`: base folder for Elixir | |
| 307 | −- `INSTALL_DIR_FOR_GLEAM`: base folder for Gleam | |
| 308 | −- `INSTALL_DIR_FOR_REBAR3`: base folder for `rebar3` | |
| 309 | − | |
| 310 | −In each of these you'll find folder `bin` where the appropriate binaries, platform-dependant, | |
| 311 | −are found (i.e. `erl`, `erl.exe`, `rebar3`, `rebar3.exe`, ...). | |
| 312 | − | |
| 313 | −## Elixir Problem Matchers | |
| 314 | − | |
| 315 | −The Elixir Problem Matchers in this repository are adapted from | |
| 316 | −[here](https://github.com/fr1zle/vscode-elixir/blob/45eddb589acd7ac98e0c7305d1c2b24668ca709a/package.json#L70-L118). | |
| 317 | −See [MATCHER_NOTICE](MATCHER_NOTICE.md) for license details. | |
| 318 | − | |
| 319 | −## Action versioning | |
| 323 | +### Versioning | |
| 320 | 324 | |
| 321 | 325 | `setup-beam` has three version paths, described below, for example version `1.8.0`: |
| 322 | 326 |
@@ -328,14 +332,18 @@ We make a real effort to not introduce incompatibilities without changing the ma
| 328 | 332 | version number. To be extra safe against changes causing issues in your CI you should specify |
| 329 | 333 | an exact version with `@vx.y.z`. |
| 330 | 334 | |
| 331 | −## License | |
| 335 | +### License | |
| 332 | 336 | |
| 333 | 337 | The scripts and documentation in this project are released under the [MIT license](LICENSE.md). |
| 334 | 338 | |
| 335 | −## Contributing | |
| 339 | +### Contributing | |
| 336 | 340 | |
| 337 | 341 | Check out [this doc](CONTRIBUTING.md). |
| 338 | 342 | |
| 339 | −## Current Status | |
| 343 | +### Code of Conduct | |
| 344 | + | |
| 345 | +This project's code of conduct is made explicit in [CODE_OF_CONDUCT.md](https://github.com/erlef/setup-beam/blob/main/CODE_OF_CONDUCT.md). | |
| 346 | + | |
| 347 | +### Security | |
| 340 | 348 | |
| 341 | −This action is in active development. | |
| 349 | +This project's security policy is made explicit in [SECURITY.md](https://github.com/erlef/setup-beam/blob/main/SECURITY.md). |
Parents: a6e26b2