Linked Questions

20 votes
5 answers
2k views

I am confused by "one only dot - space - shell script name" (like . myshellscript) and "path to shell script" (like ./myshellscript) commands. What for they are? I noticed the command . myshellscript ...
YarLinux's user avatar
  • 1,193
15 votes
4 answers
3k views

t is a simple script What is different between two case below : $ . t and $ ./t
Bahram Barazandeh's user avatar
8 votes
1 answer
16k views

What is the difference between . script.sh ./script.sh and source script.sh ?
ankagarwal's user avatar
6 votes
1 answer
13k views

I have the following shell script TEST=/foopath export TEST It is in a file called test.sh and on which I ran chmod +x test.sh When I run ./test.sh I expect that I can then execute echo $TEST and ...
ams's user avatar
  • 1,398
0 votes
2 answers
5k views

According to the Flask official tutorial: Now, whenever you want to work on a project, you only have to activate the corresponding environment. On OS X and Linux, do the following: $ . venv/bin/...
nalzok's user avatar
  • 441
2 votes
3 answers
2k views

Possible Duplicate: Using ‘.’ to execute files in bash I was trying to figure out how to export my environmental via script instead of changing my .bashrc file. I found this old useful post that ...
grebwerd's user avatar
  • 155
5 votes
1 answer
875 views

I've downloaded an installation package of weblogic server and in the README, there's this command to execute: Linux/Mac $ . ./configure.sh It's not the first time I see this. Why is there an extra ...
NeplatnyUdaj's user avatar
0 votes
3 answers
854 views

I thought I will write a bash script to set the alias I frequently use, and also to change the command promt. Below is my script. #!/bin/bash # Make useful aliases alias c='clear' alias p='pwd' ...
sps's user avatar
  • 1,456
1 vote
2 answers
3k views

We have two scripts, first.sh and second.sh. We run first.sh from second.sh using the . (source) command. I am stuck at this script, first.sh value="myvalue" export value oldvalue="othervalue" ...
nikhil2000's user avatar
3 votes
1 answer
643 views

#!/usr/bin/env bash scriptdir="$HOME" touch $scriptdir/foo.txt . "$scriptdir/foo.txt" || { echo "Missing '$scriptdir/foo.txt'. Exiting." ; exit 1 ;} echo "$scriptdir/foo.txt is present" echo rm "$...
Bleakley's user avatar
  • 183
-1 votes
1 answer
2k views

I have written a shell script named startup.sh which does a lot of things (basically start a lot of things for me after turning on my local machine) - here is an excerpt: #!/bin/bash gnome-terminal --...
Blackbam's user avatar
  • 191
3 votes
1 answer
388 views

Please excuse me if I am not clear while asking questions. I will try my best to be very clear while asking questions. While learning Embedded Linux, we are setting an environment for our project. ...
user3600064's user avatar
1 vote
1 answer
964 views

I caught myself out; I couldn't log into root after I made a script and called it from ~/.bashrc. ~/.bashrc: #... do stuff then run my script source ~/myscript.sh ~/myscript.sh: #!/bin/bash if [...
Jayy's user avatar
  • 227
1 vote
1 answer
1k views

I am trying to automate adding Homebrew to my path in a shell script, but these two lines do not evaluate inside my shell script: #!/bin/sh eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)&...
unrealapex's user avatar
0 votes
2 answers
356 views

I want to export all the variables located in a .conf. So I followed this https://unix.stackexchange.com/a/79077/56901 answer. setenv.sh #!/usr/bin/env bash DIR="$( cd "$( dirname "${BASH_SOURCE[0]}...
Avinash Raj's user avatar
  • 3,759

15 30 50 per page