doc
-l
prints
-rw-r--r-- 1 hakw 14 Jan 24 18:40 foo.sh
-a
shows hidden files
ll
is an alias for ls -al
source ./foo.sh
is the same as . ./foo.sh
.
ensures that the virtual environment’s variables are set within the current shell, and not in a subprocess (which then disappears, having no useful effect).
cd $(mktemp -d)
echo "export FOOO=1" >> foo.sh
chmod +x foo.sh
./foo.sh
echo $FOOO # prints nothing, var FOOO disappears after the sunprocess returns.
cd $(mktemp -d)
echo "export FOOO=1" >> foo.sh
chmod +x foo.sh
source ./foo.sh
echo $FOOO # prints 1, source command sets the var FOOO
mktemp
creates a temp file
-d
creates a temp directory
+x
makes file executable