Official GitHub Action to install Brioche, a delicious package manager.
setup-brioche
installs Brioche on GitHub-hosted or self-hosted runners, enabling your workflows to seamlessly use Brioche for managing packages and scripts. This Action sets up the environment quickly, ensuring that Brioche is ready for use in subsequent steps of your workflow.
Add the setup-brioche
Action to your workflow to install Brioche:
jobs:
setup-brioche:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup Brioche
uses: brioche-dev/setup-brioche@v1
with:
version: 'v0.1.3' # Optional, specify a version or use the default (v0.1.3)
install-dir: '/custom/install/path' # Optional, specify a custom installation path
- name: Verify Brioche installation
run: brioche --version # Check that Brioche is available
version
: (Optional) The version of Brioche to install. Defaults tov0.1.3
(the latest version).install-dir
: (Optional) The directory where Brioche should be installed. Defaults to$HOME/.local/bin
.
This Action runs a shell script that:
- Downloads the specified version of Brioche based on the runner's OS and architecture.
- Installs Brioche into the install directory (defaults to
$HOME/.local/bin
). - Updates
$PATH
so Brioche and any installed packages are available in subsequent steps.
Here's a complete workflow example:
name: CI with Brioche
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Setup Brioche
uses: brioche-dev/setup-brioche@v1
# with:
# version: 'v0.1.3' # Optional
# install-dir: '$HOME/custom/install/path' # Optional
- name: Build package
run: brioche build -o output
- name: Install "Hello world"
run: |
brioche install -r hello_world
hello-world
This Action uses GitHub's logging groups to make output more readable. You will see collapsible log groups for stages like downloading, validating, and installing Brioche, making it easier to debug if needed.
- Ensure the version specified in the
version
input is valid and available. - If Brioche isn't recognized in your shell, make sure the install path is correctly set in your environment.
This project is licensed under the MIT License.
For issues, feature requests, or questions, please open an issue in this repository or visit the Brioche GitHub page.