dev.fron.io nixrc / 8d741e0
shell: attempt getFlake Tony Olagbaiye 1 year, 3 days ago
1 changed file(s) with 14 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
0 { pkgs ? import <nixpkgs> { }, my ? import ./pkgs pkgs pkgs }:
0 { nixpkgs ? if isNull (builtins.getFlake or null)
1 then <nixpkgs> else builtins.getFlake "nixpkgs"
2 , pkgs ? import nixpkgs { }
3 , my ? import ./pkgs pkgs pkgs
4 }:
15
26 let
37 shFlagsRules = rules: ''
2226 ARGS="$ARGS --show-trace"
2327 fi
2428
29 if [ $FLAGS_verbose -eq $FLAGS_TRUE ]; then
30 ARGS="$ARGS -vv"
31 fi
32
2533 echo '> nixos-rebuild' $ARGS ${operation}
2634 source $(which nixos-rebuild) $ARGS ${operation}
2735 '';
3846 ${shFlagsRules ''
3947 DEFINE_string 'host' "" 'Host to build' 'H'
4048 DEFINE_boolean 'showtrace' false 'Show verbose traces' 't'
49 DEFINE_boolean 'verbose' false 'Show verbose logs' 'v'
4150 ''}
4251 ${rebuild "switch"}
4352
4958 ${shFlagsRules ''
5059 DEFINE_string 'host' "" 'Host to build' 'H'
5160 DEFINE_boolean 'showtrace' false 'Show verbose traces' 't'
61 DEFINE_boolean 'verbose' false 'Show verbose logs' 'v'
5262 ''}
5363 ${rebuild "test"}
5464
6676 ${shFlagsRules ''
6777 DEFINE_string 'host' "" 'Host to build' 'H'
6878 DEFINE_boolean 'showtrace' false 'Show verbose traces' 't'
79 DEFINE_boolean 'verbose' false 'Show verbose logs' 'v'
6980 ''}
7081 ${rebuild "boot"}
7182 '';
7384 ${shFlagsRules ''
7485 DEFINE_string 'host' "" 'Host to build' 'H'
7586 DEFINE_boolean 'showtrace' false 'Show verbose traces' 't'
87 DEFINE_boolean 'verbose' false 'Show verbose logs' 'v'
7688 ''}
7789 ${rebuild "dry-activate"}
7890 '';
8092 ${shFlagsRules ''
8193 DEFINE_string 'host' "" 'Host to build' 'H'
8294 DEFINE_boolean 'showtrace' false 'Show verbose traces' 't'
95 DEFINE_boolean 'verbose' false 'Show verbose logs' 'v'
8396 ''}
8497 ${rebuild "dry-build"}
8598 '';