Bash: âbad interpreter: Too many levels of symbolic linksâ Error

Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
Recently I made a bash executable file with permissions 722 as I am almost perpetually root. The contents of the file are as follows:
#!/home/nolan/Documents/test/listFiles
[ $# -lt 1 ] && dirFocus = "" || dirFocus = $1
dirSize=$(ls -a $dirFocus | wc -w)
for ((a = 1; a <= $dirSize; a++)) ; do
i = 1
for ITEM in $(ls -a $dirFocus); do
declare -i i
declare -i a
if [ $a -eq $i ]; then
echo "$a : $ITEM"
fi
i = $[ $i + 1 ]
done
done
When run in terminal using:
root @ /home/nolan/Documents/test: bash listFiles
1 : .
2 : ..
3 : apple
4 : dirCheck
5 : ifTest
6 : ifTest.txt
7 : listFiles
8 : myscript
9 : nolan.txt
10 : pointer_to_apple
11 : scriptx.sh
12 : Stuff
13 : weekend
14 : weekend2
15 : weekend3
I receive this outcome as expected.
However the second I do:
root @ /home/nolan/Documents/test: ./listFiles
bash: ./listFiles: /home/nolan/Documents/test/listFiles: bad interpreter: Too
many levels of symbolic links
Is the error I get.
What exactly is going wrong? I've checked other forums but they don't seem to pertain to my situation.
linux bash
add a comment |Â
up vote
1
down vote
favorite
Recently I made a bash executable file with permissions 722 as I am almost perpetually root. The contents of the file are as follows:
#!/home/nolan/Documents/test/listFiles
[ $# -lt 1 ] && dirFocus = "" || dirFocus = $1
dirSize=$(ls -a $dirFocus | wc -w)
for ((a = 1; a <= $dirSize; a++)) ; do
i = 1
for ITEM in $(ls -a $dirFocus); do
declare -i i
declare -i a
if [ $a -eq $i ]; then
echo "$a : $ITEM"
fi
i = $[ $i + 1 ]
done
done
When run in terminal using:
root @ /home/nolan/Documents/test: bash listFiles
1 : .
2 : ..
3 : apple
4 : dirCheck
5 : ifTest
6 : ifTest.txt
7 : listFiles
8 : myscript
9 : nolan.txt
10 : pointer_to_apple
11 : scriptx.sh
12 : Stuff
13 : weekend
14 : weekend2
15 : weekend3
I receive this outcome as expected.
However the second I do:
root @ /home/nolan/Documents/test: ./listFiles
bash: ./listFiles: /home/nolan/Documents/test/listFiles: bad interpreter: Too
many levels of symbolic links
Is the error I get.
What exactly is going wrong? I've checked other forums but they don't seem to pertain to my situation.
linux bash
The first sentence of the question contains a falsehood, which is of course the basis of an answer.
â JdeBP
Aug 10 at 16:54
2
722permissions seem wrong. You want to give the world write permission?
â glenn jackman
Aug 10 at 18:15
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
Recently I made a bash executable file with permissions 722 as I am almost perpetually root. The contents of the file are as follows:
#!/home/nolan/Documents/test/listFiles
[ $# -lt 1 ] && dirFocus = "" || dirFocus = $1
dirSize=$(ls -a $dirFocus | wc -w)
for ((a = 1; a <= $dirSize; a++)) ; do
i = 1
for ITEM in $(ls -a $dirFocus); do
declare -i i
declare -i a
if [ $a -eq $i ]; then
echo "$a : $ITEM"
fi
i = $[ $i + 1 ]
done
done
When run in terminal using:
root @ /home/nolan/Documents/test: bash listFiles
1 : .
2 : ..
3 : apple
4 : dirCheck
5 : ifTest
6 : ifTest.txt
7 : listFiles
8 : myscript
9 : nolan.txt
10 : pointer_to_apple
11 : scriptx.sh
12 : Stuff
13 : weekend
14 : weekend2
15 : weekend3
I receive this outcome as expected.
However the second I do:
root @ /home/nolan/Documents/test: ./listFiles
bash: ./listFiles: /home/nolan/Documents/test/listFiles: bad interpreter: Too
many levels of symbolic links
Is the error I get.
What exactly is going wrong? I've checked other forums but they don't seem to pertain to my situation.
linux bash
Recently I made a bash executable file with permissions 722 as I am almost perpetually root. The contents of the file are as follows:
#!/home/nolan/Documents/test/listFiles
[ $# -lt 1 ] && dirFocus = "" || dirFocus = $1
dirSize=$(ls -a $dirFocus | wc -w)
for ((a = 1; a <= $dirSize; a++)) ; do
i = 1
for ITEM in $(ls -a $dirFocus); do
declare -i i
declare -i a
if [ $a -eq $i ]; then
echo "$a : $ITEM"
fi
i = $[ $i + 1 ]
done
done
When run in terminal using:
root @ /home/nolan/Documents/test: bash listFiles
1 : .
2 : ..
3 : apple
4 : dirCheck
5 : ifTest
6 : ifTest.txt
7 : listFiles
8 : myscript
9 : nolan.txt
10 : pointer_to_apple
11 : scriptx.sh
12 : Stuff
13 : weekend
14 : weekend2
15 : weekend3
I receive this outcome as expected.
However the second I do:
root @ /home/nolan/Documents/test: ./listFiles
bash: ./listFiles: /home/nolan/Documents/test/listFiles: bad interpreter: Too
many levels of symbolic links
Is the error I get.
What exactly is going wrong? I've checked other forums but they don't seem to pertain to my situation.
linux bash
linux bash
edited Aug 10 at 17:28
Kevin Kruse
339111
339111
asked Aug 10 at 16:45
NolanRudolph
163
163
The first sentence of the question contains a falsehood, which is of course the basis of an answer.
â JdeBP
Aug 10 at 16:54
2
722permissions seem wrong. You want to give the world write permission?
â glenn jackman
Aug 10 at 18:15
add a comment |Â
The first sentence of the question contains a falsehood, which is of course the basis of an answer.
â JdeBP
Aug 10 at 16:54
2
722permissions seem wrong. You want to give the world write permission?
â glenn jackman
Aug 10 at 18:15
The first sentence of the question contains a falsehood, which is of course the basis of an answer.
â JdeBP
Aug 10 at 16:54
The first sentence of the question contains a falsehood, which is of course the basis of an answer.
â JdeBP
Aug 10 at 16:54
2
2
722 permissions seem wrong. You want to give the world write permission?â glenn jackman
Aug 10 at 18:15
722 permissions seem wrong. You want to give the world write permission?â glenn jackman
Aug 10 at 18:15
add a comment |Â
2 Answers
2
active
oldest
votes
up vote
9
down vote
The first line of a script is the "shebang" line. It tells kernel (program loader) what program to run to interpret the script. Your script tries to run itself to interpret the script, which in turn calls itself to interpret the interpreter, and so on ad infinity.
When you run the script with bash filename, the kernel isn't invoked and bash is used to run the script which works.
Put
#! /bin/bash
to the first line and all will be fine.
BTW, create a user with limited privileges to experiment with the system. As root, you can easily destroy everything beyond repair.
1
That something continues ad infinitum is not a very good explanation of why it stops immediately with an error. (-:
â JdeBP
Aug 10 at 16:56
@JdeBP "Ad finem" then?
â Kusalananda
Aug 10 at 17:41
It doesn't error out immediately, "Linux allows at most BINPRM_MAX_RECURSION, that is 4, levels of nesting." (git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠, though that's different in current versions, might be this part: git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠).
â ilkkachu
Aug 10 at 19:57
That's immediate as far as the questioner is concerned, who described the behaviour as happening "the second" that xe attempted this. You're also looking at the wrong code in that first.ENOEXECis not the error in the question.
â JdeBP
Aug 11 at 0:34
add a comment |Â
up vote
4
down vote
choroba explained very well that your issue is with the shell script using itself as interpreter instead of bash.
Here's a suggestion for reimplementation of your script that
Does not contain syntax errors (
dirFocus = ""is, for example, a syntax error in that=should have no spaces around it in an assignment).Deals with filenames that have spaces and newlines (looping over the output of
lsdisqualifies any such filename, likewisewc -wwould get the wrong count if any filename contained spaces).Uses modern shell syntax (
$[ $i + 1 ]is obsoletebashsyntax).Introduces tiny improvement in output (adds
(dir)to directory names).
#!/bin/bash
shopt -s dotglob # make wildcards match hidden names by default
shopt -s nullglob # make wildcards expand to nothing if no match
count=0
for name in "$1:-."/*; do
count=$(( count + 1 ))
if [ -d "$name" ]; then
printf '%d : %s (dir)n' "$count" "$name##*/"
else
printf '%d : %sn' "$count" "$name##*/"
fi
done
This also does not expand the file list more than once, whereas your code does an ls on the whole directory for each name in the directory.
$1:-. means "use what's in $1 unless it's empty or unset, otherwise use .".
$name##*/ means "the string in $name, but without the bit up to the last /".
Thanks a lot man, this does wonders for me and my future scripts! I was playing around with one part I didn't understand, namely after "$1:-." where it's followed by /* ... what purpose does /* serve here? I get that if there's no parameter, then replace with "." but what does "./*" signify?
â NolanRudolph
Aug 11 at 4:39
@NolanRudolph*is a filename globbing character that matches any string in a filename, so the complete thing,$1:-./*expands to all filenames in the directory given by the first command line argument, or to all filenames in the current directory if no command line argument was given.
â Kusalananda
Aug 11 at 6:02
Awesome, thank you so much :D
â NolanRudolph
Aug 11 at 8:08
add a comment |Â
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
9
down vote
The first line of a script is the "shebang" line. It tells kernel (program loader) what program to run to interpret the script. Your script tries to run itself to interpret the script, which in turn calls itself to interpret the interpreter, and so on ad infinity.
When you run the script with bash filename, the kernel isn't invoked and bash is used to run the script which works.
Put
#! /bin/bash
to the first line and all will be fine.
BTW, create a user with limited privileges to experiment with the system. As root, you can easily destroy everything beyond repair.
1
That something continues ad infinitum is not a very good explanation of why it stops immediately with an error. (-:
â JdeBP
Aug 10 at 16:56
@JdeBP "Ad finem" then?
â Kusalananda
Aug 10 at 17:41
It doesn't error out immediately, "Linux allows at most BINPRM_MAX_RECURSION, that is 4, levels of nesting." (git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠, though that's different in current versions, might be this part: git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠).
â ilkkachu
Aug 10 at 19:57
That's immediate as far as the questioner is concerned, who described the behaviour as happening "the second" that xe attempted this. You're also looking at the wrong code in that first.ENOEXECis not the error in the question.
â JdeBP
Aug 11 at 0:34
add a comment |Â
up vote
9
down vote
The first line of a script is the "shebang" line. It tells kernel (program loader) what program to run to interpret the script. Your script tries to run itself to interpret the script, which in turn calls itself to interpret the interpreter, and so on ad infinity.
When you run the script with bash filename, the kernel isn't invoked and bash is used to run the script which works.
Put
#! /bin/bash
to the first line and all will be fine.
BTW, create a user with limited privileges to experiment with the system. As root, you can easily destroy everything beyond repair.
1
That something continues ad infinitum is not a very good explanation of why it stops immediately with an error. (-:
â JdeBP
Aug 10 at 16:56
@JdeBP "Ad finem" then?
â Kusalananda
Aug 10 at 17:41
It doesn't error out immediately, "Linux allows at most BINPRM_MAX_RECURSION, that is 4, levels of nesting." (git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠, though that's different in current versions, might be this part: git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠).
â ilkkachu
Aug 10 at 19:57
That's immediate as far as the questioner is concerned, who described the behaviour as happening "the second" that xe attempted this. You're also looking at the wrong code in that first.ENOEXECis not the error in the question.
â JdeBP
Aug 11 at 0:34
add a comment |Â
up vote
9
down vote
up vote
9
down vote
The first line of a script is the "shebang" line. It tells kernel (program loader) what program to run to interpret the script. Your script tries to run itself to interpret the script, which in turn calls itself to interpret the interpreter, and so on ad infinity.
When you run the script with bash filename, the kernel isn't invoked and bash is used to run the script which works.
Put
#! /bin/bash
to the first line and all will be fine.
BTW, create a user with limited privileges to experiment with the system. As root, you can easily destroy everything beyond repair.
The first line of a script is the "shebang" line. It tells kernel (program loader) what program to run to interpret the script. Your script tries to run itself to interpret the script, which in turn calls itself to interpret the interpreter, and so on ad infinity.
When you run the script with bash filename, the kernel isn't invoked and bash is used to run the script which works.
Put
#! /bin/bash
to the first line and all will be fine.
BTW, create a user with limited privileges to experiment with the system. As root, you can easily destroy everything beyond repair.
edited Aug 10 at 16:56
answered Aug 10 at 16:50
choroba
24.5k34168
24.5k34168
1
That something continues ad infinitum is not a very good explanation of why it stops immediately with an error. (-:
â JdeBP
Aug 10 at 16:56
@JdeBP "Ad finem" then?
â Kusalananda
Aug 10 at 17:41
It doesn't error out immediately, "Linux allows at most BINPRM_MAX_RECURSION, that is 4, levels of nesting." (git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠, though that's different in current versions, might be this part: git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠).
â ilkkachu
Aug 10 at 19:57
That's immediate as far as the questioner is concerned, who described the behaviour as happening "the second" that xe attempted this. You're also looking at the wrong code in that first.ENOEXECis not the error in the question.
â JdeBP
Aug 11 at 0:34
add a comment |Â
1
That something continues ad infinitum is not a very good explanation of why it stops immediately with an error. (-:
â JdeBP
Aug 10 at 16:56
@JdeBP "Ad finem" then?
â Kusalananda
Aug 10 at 17:41
It doesn't error out immediately, "Linux allows at most BINPRM_MAX_RECURSION, that is 4, levels of nesting." (git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠, though that's different in current versions, might be this part: git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠).
â ilkkachu
Aug 10 at 19:57
That's immediate as far as the questioner is concerned, who described the behaviour as happening "the second" that xe attempted this. You're also looking at the wrong code in that first.ENOEXECis not the error in the question.
â JdeBP
Aug 11 at 0:34
1
1
That something continues ad infinitum is not a very good explanation of why it stops immediately with an error. (-:
â JdeBP
Aug 10 at 16:56
That something continues ad infinitum is not a very good explanation of why it stops immediately with an error. (-:
â JdeBP
Aug 10 at 16:56
@JdeBP "Ad finem" then?
â Kusalananda
Aug 10 at 17:41
@JdeBP "Ad finem" then?
â Kusalananda
Aug 10 at 17:41
It doesn't error out immediately, "Linux allows at most BINPRM_MAX_RECURSION, that is 4, levels of nesting." (git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠, though that's different in current versions, might be this part: git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠).
â ilkkachu
Aug 10 at 19:57
It doesn't error out immediately, "Linux allows at most BINPRM_MAX_RECURSION, that is 4, levels of nesting." (git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠, though that's different in current versions, might be this part: git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/⦠).
â ilkkachu
Aug 10 at 19:57
That's immediate as far as the questioner is concerned, who described the behaviour as happening "the second" that xe attempted this. You're also looking at the wrong code in that first.
ENOEXEC is not the error in the question.â JdeBP
Aug 11 at 0:34
That's immediate as far as the questioner is concerned, who described the behaviour as happening "the second" that xe attempted this. You're also looking at the wrong code in that first.
ENOEXEC is not the error in the question.â JdeBP
Aug 11 at 0:34
add a comment |Â
up vote
4
down vote
choroba explained very well that your issue is with the shell script using itself as interpreter instead of bash.
Here's a suggestion for reimplementation of your script that
Does not contain syntax errors (
dirFocus = ""is, for example, a syntax error in that=should have no spaces around it in an assignment).Deals with filenames that have spaces and newlines (looping over the output of
lsdisqualifies any such filename, likewisewc -wwould get the wrong count if any filename contained spaces).Uses modern shell syntax (
$[ $i + 1 ]is obsoletebashsyntax).Introduces tiny improvement in output (adds
(dir)to directory names).
#!/bin/bash
shopt -s dotglob # make wildcards match hidden names by default
shopt -s nullglob # make wildcards expand to nothing if no match
count=0
for name in "$1:-."/*; do
count=$(( count + 1 ))
if [ -d "$name" ]; then
printf '%d : %s (dir)n' "$count" "$name##*/"
else
printf '%d : %sn' "$count" "$name##*/"
fi
done
This also does not expand the file list more than once, whereas your code does an ls on the whole directory for each name in the directory.
$1:-. means "use what's in $1 unless it's empty or unset, otherwise use .".
$name##*/ means "the string in $name, but without the bit up to the last /".
Thanks a lot man, this does wonders for me and my future scripts! I was playing around with one part I didn't understand, namely after "$1:-." where it's followed by /* ... what purpose does /* serve here? I get that if there's no parameter, then replace with "." but what does "./*" signify?
â NolanRudolph
Aug 11 at 4:39
@NolanRudolph*is a filename globbing character that matches any string in a filename, so the complete thing,$1:-./*expands to all filenames in the directory given by the first command line argument, or to all filenames in the current directory if no command line argument was given.
â Kusalananda
Aug 11 at 6:02
Awesome, thank you so much :D
â NolanRudolph
Aug 11 at 8:08
add a comment |Â
up vote
4
down vote
choroba explained very well that your issue is with the shell script using itself as interpreter instead of bash.
Here's a suggestion for reimplementation of your script that
Does not contain syntax errors (
dirFocus = ""is, for example, a syntax error in that=should have no spaces around it in an assignment).Deals with filenames that have spaces and newlines (looping over the output of
lsdisqualifies any such filename, likewisewc -wwould get the wrong count if any filename contained spaces).Uses modern shell syntax (
$[ $i + 1 ]is obsoletebashsyntax).Introduces tiny improvement in output (adds
(dir)to directory names).
#!/bin/bash
shopt -s dotglob # make wildcards match hidden names by default
shopt -s nullglob # make wildcards expand to nothing if no match
count=0
for name in "$1:-."/*; do
count=$(( count + 1 ))
if [ -d "$name" ]; then
printf '%d : %s (dir)n' "$count" "$name##*/"
else
printf '%d : %sn' "$count" "$name##*/"
fi
done
This also does not expand the file list more than once, whereas your code does an ls on the whole directory for each name in the directory.
$1:-. means "use what's in $1 unless it's empty or unset, otherwise use .".
$name##*/ means "the string in $name, but without the bit up to the last /".
Thanks a lot man, this does wonders for me and my future scripts! I was playing around with one part I didn't understand, namely after "$1:-." where it's followed by /* ... what purpose does /* serve here? I get that if there's no parameter, then replace with "." but what does "./*" signify?
â NolanRudolph
Aug 11 at 4:39
@NolanRudolph*is a filename globbing character that matches any string in a filename, so the complete thing,$1:-./*expands to all filenames in the directory given by the first command line argument, or to all filenames in the current directory if no command line argument was given.
â Kusalananda
Aug 11 at 6:02
Awesome, thank you so much :D
â NolanRudolph
Aug 11 at 8:08
add a comment |Â
up vote
4
down vote
up vote
4
down vote
choroba explained very well that your issue is with the shell script using itself as interpreter instead of bash.
Here's a suggestion for reimplementation of your script that
Does not contain syntax errors (
dirFocus = ""is, for example, a syntax error in that=should have no spaces around it in an assignment).Deals with filenames that have spaces and newlines (looping over the output of
lsdisqualifies any such filename, likewisewc -wwould get the wrong count if any filename contained spaces).Uses modern shell syntax (
$[ $i + 1 ]is obsoletebashsyntax).Introduces tiny improvement in output (adds
(dir)to directory names).
#!/bin/bash
shopt -s dotglob # make wildcards match hidden names by default
shopt -s nullglob # make wildcards expand to nothing if no match
count=0
for name in "$1:-."/*; do
count=$(( count + 1 ))
if [ -d "$name" ]; then
printf '%d : %s (dir)n' "$count" "$name##*/"
else
printf '%d : %sn' "$count" "$name##*/"
fi
done
This also does not expand the file list more than once, whereas your code does an ls on the whole directory for each name in the directory.
$1:-. means "use what's in $1 unless it's empty or unset, otherwise use .".
$name##*/ means "the string in $name, but without the bit up to the last /".
choroba explained very well that your issue is with the shell script using itself as interpreter instead of bash.
Here's a suggestion for reimplementation of your script that
Does not contain syntax errors (
dirFocus = ""is, for example, a syntax error in that=should have no spaces around it in an assignment).Deals with filenames that have spaces and newlines (looping over the output of
lsdisqualifies any such filename, likewisewc -wwould get the wrong count if any filename contained spaces).Uses modern shell syntax (
$[ $i + 1 ]is obsoletebashsyntax).Introduces tiny improvement in output (adds
(dir)to directory names).
#!/bin/bash
shopt -s dotglob # make wildcards match hidden names by default
shopt -s nullglob # make wildcards expand to nothing if no match
count=0
for name in "$1:-."/*; do
count=$(( count + 1 ))
if [ -d "$name" ]; then
printf '%d : %s (dir)n' "$count" "$name##*/"
else
printf '%d : %sn' "$count" "$name##*/"
fi
done
This also does not expand the file list more than once, whereas your code does an ls on the whole directory for each name in the directory.
$1:-. means "use what's in $1 unless it's empty or unset, otherwise use .".
$name##*/ means "the string in $name, but without the bit up to the last /".
edited Aug 11 at 8:45
answered Aug 10 at 18:05
Kusalananda
106k14209327
106k14209327
Thanks a lot man, this does wonders for me and my future scripts! I was playing around with one part I didn't understand, namely after "$1:-." where it's followed by /* ... what purpose does /* serve here? I get that if there's no parameter, then replace with "." but what does "./*" signify?
â NolanRudolph
Aug 11 at 4:39
@NolanRudolph*is a filename globbing character that matches any string in a filename, so the complete thing,$1:-./*expands to all filenames in the directory given by the first command line argument, or to all filenames in the current directory if no command line argument was given.
â Kusalananda
Aug 11 at 6:02
Awesome, thank you so much :D
â NolanRudolph
Aug 11 at 8:08
add a comment |Â
Thanks a lot man, this does wonders for me and my future scripts! I was playing around with one part I didn't understand, namely after "$1:-." where it's followed by /* ... what purpose does /* serve here? I get that if there's no parameter, then replace with "." but what does "./*" signify?
â NolanRudolph
Aug 11 at 4:39
@NolanRudolph*is a filename globbing character that matches any string in a filename, so the complete thing,$1:-./*expands to all filenames in the directory given by the first command line argument, or to all filenames in the current directory if no command line argument was given.
â Kusalananda
Aug 11 at 6:02
Awesome, thank you so much :D
â NolanRudolph
Aug 11 at 8:08
Thanks a lot man, this does wonders for me and my future scripts! I was playing around with one part I didn't understand, namely after "$1:-." where it's followed by /* ... what purpose does /* serve here? I get that if there's no parameter, then replace with "." but what does "./*" signify?
â NolanRudolph
Aug 11 at 4:39
Thanks a lot man, this does wonders for me and my future scripts! I was playing around with one part I didn't understand, namely after "$1:-." where it's followed by /* ... what purpose does /* serve here? I get that if there's no parameter, then replace with "." but what does "./*" signify?
â NolanRudolph
Aug 11 at 4:39
@NolanRudolph
* is a filename globbing character that matches any string in a filename, so the complete thing, $1:-./* expands to all filenames in the directory given by the first command line argument, or to all filenames in the current directory if no command line argument was given.â Kusalananda
Aug 11 at 6:02
@NolanRudolph
* is a filename globbing character that matches any string in a filename, so the complete thing, $1:-./* expands to all filenames in the directory given by the first command line argument, or to all filenames in the current directory if no command line argument was given.â Kusalananda
Aug 11 at 6:02
Awesome, thank you so much :D
â NolanRudolph
Aug 11 at 8:08
Awesome, thank you so much :D
â NolanRudolph
Aug 11 at 8:08
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f461850%2fbash-bad-interpreter-too-many-levels-of-symbolic-links-error%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
The first sentence of the question contains a falsehood, which is of course the basis of an answer.
â JdeBP
Aug 10 at 16:54
2
722permissions seem wrong. You want to give the world write permission?â glenn jackman
Aug 10 at 18:15