aboutsummaryrefslogtreecommitdiff
path: root/rui.go
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-09-21 15:54:00 -0700
committerFuwn <[email protected]>2024-09-21 15:54:00 -0700
commit267683280287223d0ea018de007dbb17d52e8b6d (patch)
treed5fa6ddbd6a2526e2085cbc07a3aaa16c7765afb /rui.go
parentb871077822a5a01c99b66caaa10c6411eb5b9b70 (diff)
downloadrui-267683280287223d0ea018de007dbb17d52e8b6d.tar.xz
rui-267683280287223d0ea018de007dbb17d52e8b6d.zip
feat(rui): allow-unfree flag
Diffstat (limited to 'rui.go')
-rw-r--r--rui.go14
1 files changed, 14 insertions, 0 deletions
diff --git a/rui.go b/rui.go
index 00c7adb..778783a 100644
--- a/rui.go
+++ b/rui.go
@@ -55,6 +55,20 @@ func main() {
}
},
Suggest: true,
+ Flags: []cli.Flag{
+ &cli.BoolFlag{
+ Name: "allow-unfree",
+ Action: func(c *cli.Context, b bool) error {
+ state := "0"
+
+ if b {
+ state = "1"
+ }
+
+ return os.Setenv("NIXPKGS_ALLOW_UNFREE", state)
+ },
+ },
+ },
Commands: []*cli.Command{
{
Name: "hs",