Rename hooks
This commit is contained in:
parent
1407092c98
commit
3466fd63e2
2 changed files with 5 additions and 5 deletions
|
@ -66,14 +66,14 @@ function runSetup
|
|||
cp -r "$nixPkgsDir" "$mountDir/$nixPkgsDir"
|
||||
end
|
||||
|
||||
function prepareAction
|
||||
function actionInitialization
|
||||
echo "Partitioning drives..."
|
||||
and getOSConfig partition.script >"$script"
|
||||
and "$script"
|
||||
and rm "$script"
|
||||
end
|
||||
|
||||
function postAction
|
||||
function actionPostRun
|
||||
echo "Setup finished!"
|
||||
and echo "This machine will reboot in 5 seconds..."
|
||||
and echo "Press CTRL-C to abort..."
|
||||
|
|
|
@ -14,14 +14,14 @@ function runAction -V dir
|
|||
set -x CONFIG_NAME "$config"
|
||||
end
|
||||
|
||||
and runHook prepareAction || true
|
||||
and runHook actionInitialization || true
|
||||
|
||||
echo "Flagging repository as safe..."
|
||||
sudo git config --system --add safe.directory (realpath "$(status dirname)/../..")
|
||||
|
||||
and runHook preAction || true
|
||||
and runHook actionPreRun || true
|
||||
$argv
|
||||
and runHook postAction || true
|
||||
and runHook actionPostRun || true
|
||||
sudo git config remove-section --system safe || true
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue