Wednesday 20 March 2019

bash - What does 'source' do?


$ whatis source
source: nothing appropriate.
$ man source
No manual entry for source
$ source
bash: source: filename argument required
source: usage: source filename [arguments]

It exists, and it is runnable. Why isn't there any documentation about it in Ubuntu? What does it do? How can I install documentation about it?



Answer



source is a bash shell built-in command that executes the content of the file passed as argument, in the current shell. It has a synonym in . (period).



Syntax


. filename [arguments]

source filename [arguments]

No comments:

Post a Comment

How can I VLOOKUP in multiple Excel documents?

I am trying to VLOOKUP reference data with around 400 seperate Excel files. Is it possible to do this in a quick way rather than doing it m...