From c3f252d36d8ddc0e2ae5123b15b34d9eb7f5c9f8 Mon Sep 17 00:00:00 2001 From: Juan Ibiapina Date: Wed, 22 May 2024 23:52:30 +0200 Subject: [PATCH] doc: Add installation section to README --- README.md | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/README.md b/README.md index 4bfd561..b825f1e 100644 --- a/README.md +++ b/README.md @@ -16,6 +16,42 @@ a directory (and subdirectories) of scripts. - **Completions:** Supports auto completion of subcommands. - **Cross-platform:** Works on Linux and macOS. +## Installation + +### Homebrew + +```sh +brew install juanibiapina/tap/sub +``` + +### Nix with Flakes + +Add sub to your flake inputs: + +```nix +{ + inputs = { + sub = { + url = "github:juanibiapina/sub"; + inputs.nixpkgs.follows = "nixpkgs"; # Optional + }; + }; + + # ... +} +``` + +Then add it to your packages: + +```nix +{ + environment.systemPackages = with pkgs; [ + inputs.sub.packages."${pkgs.system}".sub + # ... + ]; +} +``` + ## Overview `sub` is meant to be used as the entry point for a CLI. Given the following