Vengo dal mondo Linux, dove se voglio generare un file digito per esempio:
'source / etc / profile'
Come faccio a farlo in Mac?
Vengo dal mondo Linux, dove se voglio generare un file digito per esempio:
'source / etc / profile'
Come faccio a farlo in Mac?
Terminal usa Bash di default e / bin / sh è anche Bash, quindi la sorgente dovrebbe funzionare nella maggior parte dei posti.
source non è definito da POSIX , ma è consentito da Bash in POSIX o quando è invocato come / bin / sh.
I messaggi di aiuto per l'origine e. sono identici:
$ help source .
source: source filename [arguments]
Read and execute commands from FILENAME and return. The pathnames
in $PATH are used to find the directory containing FILENAME. If any
ARGUMENTS are supplied, they become the positional parameters when
FILENAME is executed.
.: . filename [arguments]
Read and execute commands from FILENAME and return. The pathnames
in $PATH are used to find the directory containing FILENAME. If any
ARGUMENTS are supplied, they become the positional parameters when
FILENAME is executed.
Sto usando bash come shell sul mio Mac e posso usare "source". Ad esempio source .bash_profile
Leggi altre domande sui tag command-line administrator serveradmin