mirror of
https://github.com/LnL7/nix-darwin.git
synced 2025-03-28 02:37:09 +00:00
darwin-rebuild: fix activate without an existing profile
This commit is contained in:
parent
d56312be06
commit
7aa0ad23f4
1 changed files with 5 additions and 1 deletions
|
@ -114,10 +114,14 @@ if [ "$action" = list -o "$action" = rollback ]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
if [ "$action" = activate -o "$action" = rollback -o "$action" = check ]; then
|
||||
if [ "$action" = rollback -o "$action" = check ]; then
|
||||
systemConfig="$(cat $profile/systemConfig)"
|
||||
fi
|
||||
|
||||
if [ "$action" = activate ]; then
|
||||
systemConfig=$(readlink -f "${0%*/sw/bin/darwin-rebuild}")
|
||||
fi
|
||||
|
||||
if [ -z "$systemConfig" ]; then exit 0; fi
|
||||
|
||||
if [ "$action" = switch ]; then
|
||||
|
|
Loading…
Add table
Reference in a new issue