This is a very basic GitHub Action to install an arbitrary tool from a templated url. It utilizes the tool-cache to optimize install times and supports a very basic token replace templating mechanism for the url you want to download your tool from.
Note
|
This Action took inspiration of several other tool setup Actions, however none of them seemed to be doing what I needed, so this exists now. |
This action does currently not utilize nor support using any form of authorization (i.e. the GitHub Token). If it is a requested feature it may get added.
Input | Required | TemplateLiteral | Description |
---|---|---|---|
|
|
|
The name of the tool you want to install via this action.
It also populates the |
|
|
|
Conditionally required if you to use the |
|
|
|
The version of the tool you want to install.
It also populates the |
|
|
|
The URL template to download your tool of choice from.
By default, this is set to a reasonable assumed url pattern for GitHub releases, yet you can overwrite it with your own template. |
|
|
|
In case you want to run a smoke test to validate that your tool was installed properly.
This only supports |
Note
|
The following
|
on:
# ...
jobs:
demo:
runs-on: ubuntu-latest
steps:
- name: "Install gino-keva"
uses: k3rnels-actions/setup-tool-binary@v1
with:
toolName: 'gino-keva'
toolRepository: 'philips-software'
toolVersion: '2.0.0'
urlTemplate: 'https://github.com/{{toolRepository}}/{{toolName}}/releases/download/v{{toolVersion}}/{{toolName}}'
smokeTestTemplate: '{{toolName}} --help'
- name: "Checkout Repo"
uses: actions/checkout@v3
# ...
All kinds of contributions are more than welcome! However, if you plan bigger changes please open an issue first to discuss your proposed changes 😉