nix-on-droid: add -I argument

This commit is contained in:
Tobias Happ 2020-01-08 20:56:12 +01:00 committed by Alexander Sosedkin
parent 9323f2f573
commit d9fd49b6c4

View file

@ -25,10 +25,11 @@ function doHelp() {
echo " -h|--help Print this help" echo " -h|--help Print this help"
echo " -n|--dry-run Do a dry run, only prints what actions would be taken" echo " -n|--dry-run Do a dry run, only prints what actions would be taken"
echo " -v|--verbose Verbose output" echo " -v|--verbose Verbose output"
echo " -f|--file Path to config file" echo " -f|--file FILE Path to config file"
echo echo
echo "Options passed on to nix build" echo "Options passed on to nix build"
echo echo
echo " -I|--include PATH"
echo " --cores NUM" echo " --cores NUM"
echo " --keep-failed" echo " --keep-failed"
echo " --keep-going" echo " --keep-going"
@ -90,10 +91,10 @@ function doSwitchGeneration() {
} }
COMMAND=
COMMAND_ARGS=() COMMAND_ARGS=()
PASSTHROUGH_OPTS=() COMMAND=
CONFIG_FILE= CONFIG_FILE=
PASSTHROUGH_OPTS=()
while [[ $# -gt 0 ]]; do while [[ $# -gt 0 ]]; do
opt="$1" opt="$1"
@ -110,6 +111,10 @@ while [[ $# -gt 0 ]]; do
doHelp doHelp
exit 0 exit 0
;; ;;
-I|--include)
PASSTHROUGH_OPTS+=(-I "$1")
shift
;;
-n|--dry-run) -n|--dry-run)
export DRY_RUN=1 export DRY_RUN=1
;; ;;