Remove necessity of INSTALLER_SCRIPT
variable
This commit is contained in:
parent
c364b53d33
commit
bfcd7be17f
2 changed files with 3 additions and 3 deletions
|
@ -1,5 +1,6 @@
|
|||
#!/bin/env fish
|
||||
set -l dir (status dirname)
|
||||
set -l cmdline (cat /proc/$fish_pid/cmdline | string split0)
|
||||
source "$dir/../Scripts/config.fish"
|
||||
source "$dir/../Scripts/hooks.fish"
|
||||
|
||||
|
@ -9,7 +10,7 @@ if [ (id -u) -eq 0 ]
|
|||
rm ~/.bash_profile
|
||||
|
||||
if [ -z "$TMUX" ]
|
||||
tmux new-session (cat /proc/$fish_pid/cmdline | string split0)
|
||||
tmux new-session $cmdline
|
||||
else
|
||||
begin
|
||||
echo "Creating setup user"
|
||||
|
@ -28,7 +29,7 @@ if [ (id -u) -eq 0 ]
|
|||
echo "$name ALL=(ALL:ALL) NOPASSWD: ALL"
|
||||
end >"$sudoConfig"
|
||||
|
||||
and sudo --preserve-env --set-home --user "$name" "$INSTALLER_SCRIPT"
|
||||
and sudo --preserve-env --set-home --user "$name" $cmdline
|
||||
rm "$sudoConfig"
|
||||
userdel -rf "$name"
|
||||
end
|
||||
|
|
|
@ -72,7 +72,6 @@ function runSetup
|
|||
|
||||
wrapScript (
|
||||
string join " " \
|
||||
"INSTALLER_SCRIPT=$(string escape "$script")" \
|
||||
"CONFIG_NAME=$(string escape "$CONFIG_NAME")" \
|
||||
(string escape $script))
|
||||
|
||||
|
|
Loading…
Reference in a new issue