1
0
Fork 0
mirror of https://git.madhouse-project.org/actions/nix.git synced 2024-11-23 20:19:16 +01:00
Thin Forgejo Actions to streamline common Nix tasks.
Find a file
Gergely Nagy 29ec176179 ci: Add a dummy workflow
For the badge to work, we need to run at least one workflow for every
push, otherwise Ironforge will be sad.

Signed-off-by: Gergely Nagy <me@gergo.csillger.hu>
2023-09-22 22:29:30 +02:00
.forgejo/workflows ci: Add a dummy workflow 2023-09-22 22:29:30 +02:00
build Add a nix/build action 2023-09-22 20:22:33 +02:00
develop develop: Run the user script with -eo pipefail 2023-09-22 22:08:47 +02:00
install Initial import 2023-09-22 19:37:47 +02:00
shell Add a nix/shell action 2023-09-22 21:43:51 +02:00
.gitignore Add a .gitignore file 2023-09-22 20:06:37 +02:00
COPYING.md Initial import 2023-09-22 19:37:47 +02:00
README.md Add a README 2023-09-22 22:26:09 +02:00

actions/nix

Build status

This repository provides a number of Forgejo Actions, all aimed at making it more pleasant to work with both Nix (either by running under NixOS, or using the Nix package manager on its own). The provided actions are listed below. All examples show the default inputs, unless otherwise specified. If the defaults are fine, those inputs can be safely omitted.

actions/nix/install

Usage

- name: Install Nix on the host
  uses: actions/nix/install@main
  with:
    install-url: "https://nixos.org/nix/install"

actions/nix/build

Usage

- name: Build a Nix package
  uses: actions/nix/build@main
  with:
    flake: .
    package: # there's no default, Nix itself will fall back to "default"
    logs: false

actions/nix/develop

Usage

- name: Run something in a development environment
  uses: actions/nix/develop@main
  with:
    flake: .
    package: # no default, see above
    run: |
      # No default here, either!      

The commands specified in the run input will be written to a shell script, and the shell script will be executed with bash -eo pipefail.

actions/nix/shell

Usage

- name: Run something in a Nix shell
  uses: actions/nix/shell@main
  with:
    flake: .
    package: # no default, see above
    run: |
      # No default here, either!      

The commands specified in the run input will be written to a shell script, and the shell script will be executed with bash -eo pipefail.