mrbonkers Posted May 21, 2008 Share Posted May 21, 2008 bless -mount "$3/" -setBoot and "$1/Contents/Resources/SetHidden" "$3" \ what do they mean? the $3 and $1. i've tried googling but i dont know what to look for. Link to comment https://www.insanelymac.com/forum/topic/106086-whats-3-2-1-etc-mean/ Share on other sites More sharing options...
lord_muad_dib Posted May 21, 2008 Share Posted May 21, 2008 that lne is inserted on a bash script? if yes, they are the "arguments" you insert in the command line Link to comment https://www.insanelymac.com/forum/topic/106086-whats-3-2-1-etc-mean/#findComment-753966 Share on other sites More sharing options...
mrbonkers Posted May 21, 2008 Author Share Posted May 21, 2008 #!/bin/sh "$1/Contents/Resources/SetHidden" "$3" \ "$1/Contents/Resources/hidden_MacOS9" if [ "x$CF_USER_DATA_STRING" != "x" ]; then echo "$CF_USER_DATA_STRING" > "$3/var/root/.CFUserTextEncoding"; "$3/usr/sbin/chown" -f root:wheel "$3/var/root/.CFUserTextEncoding"; "$3/bin/chmod" -f 644 "$3/var/root/.CFUserTextEncoding"; fi bless -mount "$3/" -setBoot diskutil repairPermissions "$3/" "$3/bin/chmod" -R 755 "$3/System/Library/Extensions/" "$3/usr/sbin/chown" -R root:wheel "$3/System/Library/Extensions/" "$1/Contents/Resources/SetHidden" "$3" \ "$1/Contents/Resources/hidden_MacOS9" diskutil repairPermissions "$3/" exit 0 alright so it must be something=$1? but the above code does not have that line. could you explain? Link to comment https://www.insanelymac.com/forum/topic/106086-whats-3-2-1-etc-mean/#findComment-753968 Share on other sites More sharing options...
HansDampf633 Posted May 21, 2008 Share Posted May 21, 2008 assuming the scripts name is "myscript.sh" you would start it from the Terminal like this: ./myscript arg1 arg2 arg3 Within the script you could access those arguments with $1,$2 and $3 $0 is usually the name of the called executable, in this case myscript.sh Link to comment https://www.insanelymac.com/forum/topic/106086-whats-3-2-1-etc-mean/#findComment-753979 Share on other sites More sharing options...
mrbonkers Posted May 21, 2008 Author Share Posted May 21, 2008 alright. i got that part. thanks you. Link to comment https://www.insanelymac.com/forum/topic/106086-whats-3-2-1-etc-mean/#findComment-753985 Share on other sites More sharing options...
Recommended Posts