Unix command that takes no arguments [closed]

Clash Royale CLAN TAG#URR8PPP
Don't ask why, but is there a Unix command that takes no arguments?
command-line
closed as too broad by Kusalananda, Jeff Schaller, Christopher, A.B, penguin359 Jan 11 at 0:01
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment |
Don't ask why, but is there a Unix command that takes no arguments?
command-line
closed as too broad by Kusalananda, Jeff Schaller, Christopher, A.B, penguin359 Jan 11 at 0:01
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
1
Are you looking for a command that would error if given arguments, or that just don't process their arguments? I'm not immediately thinking of any in the former category (though one would be easy to create, and they may well exist), but the latter category has various examples. And of course there are many unix commands that do something useful without any arguments, but I'm guessing that's not what you're asking.
– lindes
Feb 22 '11 at 9:56
10
I can't help myself. Why? :P
– gnud
Feb 22 '11 at 14:11
Without further explanation what the issue is, whether "arguments" means options or operands or both, or why the question is asked in the first place, the question is unclear and too broad.
– Kusalananda
Jan 10 at 9:45
add a comment |
Don't ask why, but is there a Unix command that takes no arguments?
command-line
Don't ask why, but is there a Unix command that takes no arguments?
command-line
command-line
edited Feb 22 '11 at 19:54
Gilles
533k12810721594
533k12810721594
asked Feb 22 '11 at 9:43
user4976
closed as too broad by Kusalananda, Jeff Schaller, Christopher, A.B, penguin359 Jan 11 at 0:01
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
closed as too broad by Kusalananda, Jeff Schaller, Christopher, A.B, penguin359 Jan 11 at 0:01
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
1
Are you looking for a command that would error if given arguments, or that just don't process their arguments? I'm not immediately thinking of any in the former category (though one would be easy to create, and they may well exist), but the latter category has various examples. And of course there are many unix commands that do something useful without any arguments, but I'm guessing that's not what you're asking.
– lindes
Feb 22 '11 at 9:56
10
I can't help myself. Why? :P
– gnud
Feb 22 '11 at 14:11
Without further explanation what the issue is, whether "arguments" means options or operands or both, or why the question is asked in the first place, the question is unclear and too broad.
– Kusalananda
Jan 10 at 9:45
add a comment |
1
Are you looking for a command that would error if given arguments, or that just don't process their arguments? I'm not immediately thinking of any in the former category (though one would be easy to create, and they may well exist), but the latter category has various examples. And of course there are many unix commands that do something useful without any arguments, but I'm guessing that's not what you're asking.
– lindes
Feb 22 '11 at 9:56
10
I can't help myself. Why? :P
– gnud
Feb 22 '11 at 14:11
Without further explanation what the issue is, whether "arguments" means options or operands or both, or why the question is asked in the first place, the question is unclear and too broad.
– Kusalananda
Jan 10 at 9:45
1
1
Are you looking for a command that would error if given arguments, or that just don't process their arguments? I'm not immediately thinking of any in the former category (though one would be easy to create, and they may well exist), but the latter category has various examples. And of course there are many unix commands that do something useful without any arguments, but I'm guessing that's not what you're asking.
– lindes
Feb 22 '11 at 9:56
Are you looking for a command that would error if given arguments, or that just don't process their arguments? I'm not immediately thinking of any in the former category (though one would be easy to create, and they may well exist), but the latter category has various examples. And of course there are many unix commands that do something useful without any arguments, but I'm guessing that's not what you're asking.
– lindes
Feb 22 '11 at 9:56
10
10
I can't help myself. Why? :P
– gnud
Feb 22 '11 at 14:11
I can't help myself. Why? :P
– gnud
Feb 22 '11 at 14:11
Without further explanation what the issue is, whether "arguments" means options or operands or both, or why the question is asked in the first place, the question is unclear and too broad.
– Kusalananda
Jan 10 at 9:45
Without further explanation what the issue is, whether "arguments" means options or operands or both, or why the question is asked in the first place, the question is unclear and too broad.
– Kusalananda
Jan 10 at 9:45
add a comment |
4 Answers
4
active
oldest
votes
true and false are two examples.
Or did you mean commands that take no options? I can't think of any, but the original Unix version of echo didn't take any options. There's even a story about it how it came to take options.
yesis another one.
– asoundmove
Feb 22 '11 at 12:44
2
@asoundmoveyesdoesn't require an argument, but it does accept/use one.
– gnud
Feb 22 '11 at 13:43
1
As is so often the case, this largely depends on what Unix implementation you are using. Yes, POSIX doesn't specify any arguments fortrue, but that doesn't stop the GNU project:true --helpyieldsAufruf: /bin/true NAME oder: /bin/true OPTION Aufruf: %s [ignorierte Kommandzeilen-Argument] oder: %s OPTION Mit einem Status-Code beenden, der erfolgreiche Ausführung signalisiert.(21 lines total.) You'll notice that it is even localized!
– Jörg W Mittag
Feb 22 '11 at 19:32
add a comment |
nologin takes no arguments and is widely available on Linux and BSD.
On CentOS 4 and 5, the arch command takes no arguments. On other linux distros, arch is now provided by GNU coreutils which takes --version and --help. With CentOS 4 and 5 it comes from util-linux which differs from GNU's version.
A lot of the things in GNU coreutils take only --help and --version, if you look at different Unixes that don't use GNU coreutils, they don't accept any arguments: sync, true, false, whoami, pwd, groups, users
add a comment |
:, true, false, reset, clear, line, chkdupexe and arch all take no arguments.
I'm sure they accept them, but they ignore them.
OMG.. true and false are commands!... must try this: true; echo $? ... 0 | false; echo $? ... 1 ... yup! ... an ineresting bit if info... bash is different :)
– Peter.O
Feb 22 '11 at 17:17
add a comment |
If you accidentally run docker ps a (instead of docker ps -a) you'll actually get a message:
"docker ps" accepts no arguments.
Kinda reminds me of my wife.
add a comment |
4 Answers
4
active
oldest
votes
4 Answers
4
active
oldest
votes
active
oldest
votes
active
oldest
votes
true and false are two examples.
Or did you mean commands that take no options? I can't think of any, but the original Unix version of echo didn't take any options. There's even a story about it how it came to take options.
yesis another one.
– asoundmove
Feb 22 '11 at 12:44
2
@asoundmoveyesdoesn't require an argument, but it does accept/use one.
– gnud
Feb 22 '11 at 13:43
1
As is so often the case, this largely depends on what Unix implementation you are using. Yes, POSIX doesn't specify any arguments fortrue, but that doesn't stop the GNU project:true --helpyieldsAufruf: /bin/true NAME oder: /bin/true OPTION Aufruf: %s [ignorierte Kommandzeilen-Argument] oder: %s OPTION Mit einem Status-Code beenden, der erfolgreiche Ausführung signalisiert.(21 lines total.) You'll notice that it is even localized!
– Jörg W Mittag
Feb 22 '11 at 19:32
add a comment |
true and false are two examples.
Or did you mean commands that take no options? I can't think of any, but the original Unix version of echo didn't take any options. There's even a story about it how it came to take options.
yesis another one.
– asoundmove
Feb 22 '11 at 12:44
2
@asoundmoveyesdoesn't require an argument, but it does accept/use one.
– gnud
Feb 22 '11 at 13:43
1
As is so often the case, this largely depends on what Unix implementation you are using. Yes, POSIX doesn't specify any arguments fortrue, but that doesn't stop the GNU project:true --helpyieldsAufruf: /bin/true NAME oder: /bin/true OPTION Aufruf: %s [ignorierte Kommandzeilen-Argument] oder: %s OPTION Mit einem Status-Code beenden, der erfolgreiche Ausführung signalisiert.(21 lines total.) You'll notice that it is even localized!
– Jörg W Mittag
Feb 22 '11 at 19:32
add a comment |
true and false are two examples.
Or did you mean commands that take no options? I can't think of any, but the original Unix version of echo didn't take any options. There's even a story about it how it came to take options.
true and false are two examples.
Or did you mean commands that take no options? I can't think of any, but the original Unix version of echo didn't take any options. There's even a story about it how it came to take options.
edited Feb 22 '11 at 9:59
answered Feb 22 '11 at 9:53
MikelMikel
39.2k1099125
39.2k1099125
yesis another one.
– asoundmove
Feb 22 '11 at 12:44
2
@asoundmoveyesdoesn't require an argument, but it does accept/use one.
– gnud
Feb 22 '11 at 13:43
1
As is so often the case, this largely depends on what Unix implementation you are using. Yes, POSIX doesn't specify any arguments fortrue, but that doesn't stop the GNU project:true --helpyieldsAufruf: /bin/true NAME oder: /bin/true OPTION Aufruf: %s [ignorierte Kommandzeilen-Argument] oder: %s OPTION Mit einem Status-Code beenden, der erfolgreiche Ausführung signalisiert.(21 lines total.) You'll notice that it is even localized!
– Jörg W Mittag
Feb 22 '11 at 19:32
add a comment |
yesis another one.
– asoundmove
Feb 22 '11 at 12:44
2
@asoundmoveyesdoesn't require an argument, but it does accept/use one.
– gnud
Feb 22 '11 at 13:43
1
As is so often the case, this largely depends on what Unix implementation you are using. Yes, POSIX doesn't specify any arguments fortrue, but that doesn't stop the GNU project:true --helpyieldsAufruf: /bin/true NAME oder: /bin/true OPTION Aufruf: %s [ignorierte Kommandzeilen-Argument] oder: %s OPTION Mit einem Status-Code beenden, der erfolgreiche Ausführung signalisiert.(21 lines total.) You'll notice that it is even localized!
– Jörg W Mittag
Feb 22 '11 at 19:32
yes is another one.– asoundmove
Feb 22 '11 at 12:44
yes is another one.– asoundmove
Feb 22 '11 at 12:44
2
2
@asoundmove
yes doesn't require an argument, but it does accept/use one.– gnud
Feb 22 '11 at 13:43
@asoundmove
yes doesn't require an argument, but it does accept/use one.– gnud
Feb 22 '11 at 13:43
1
1
As is so often the case, this largely depends on what Unix implementation you are using. Yes, POSIX doesn't specify any arguments for
true, but that doesn't stop the GNU project: true --help yields Aufruf: /bin/true NAME oder: /bin/true OPTION Aufruf: %s [ignorierte Kommandzeilen-Argument] oder: %s OPTION Mit einem Status-Code beenden, der erfolgreiche Ausführung signalisiert. (21 lines total.) You'll notice that it is even localized!– Jörg W Mittag
Feb 22 '11 at 19:32
As is so often the case, this largely depends on what Unix implementation you are using. Yes, POSIX doesn't specify any arguments for
true, but that doesn't stop the GNU project: true --help yields Aufruf: /bin/true NAME oder: /bin/true OPTION Aufruf: %s [ignorierte Kommandzeilen-Argument] oder: %s OPTION Mit einem Status-Code beenden, der erfolgreiche Ausführung signalisiert. (21 lines total.) You'll notice that it is even localized!– Jörg W Mittag
Feb 22 '11 at 19:32
add a comment |
nologin takes no arguments and is widely available on Linux and BSD.
On CentOS 4 and 5, the arch command takes no arguments. On other linux distros, arch is now provided by GNU coreutils which takes --version and --help. With CentOS 4 and 5 it comes from util-linux which differs from GNU's version.
A lot of the things in GNU coreutils take only --help and --version, if you look at different Unixes that don't use GNU coreutils, they don't accept any arguments: sync, true, false, whoami, pwd, groups, users
add a comment |
nologin takes no arguments and is widely available on Linux and BSD.
On CentOS 4 and 5, the arch command takes no arguments. On other linux distros, arch is now provided by GNU coreutils which takes --version and --help. With CentOS 4 and 5 it comes from util-linux which differs from GNU's version.
A lot of the things in GNU coreutils take only --help and --version, if you look at different Unixes that don't use GNU coreutils, they don't accept any arguments: sync, true, false, whoami, pwd, groups, users
add a comment |
nologin takes no arguments and is widely available on Linux and BSD.
On CentOS 4 and 5, the arch command takes no arguments. On other linux distros, arch is now provided by GNU coreutils which takes --version and --help. With CentOS 4 and 5 it comes from util-linux which differs from GNU's version.
A lot of the things in GNU coreutils take only --help and --version, if you look at different Unixes that don't use GNU coreutils, they don't accept any arguments: sync, true, false, whoami, pwd, groups, users
nologin takes no arguments and is widely available on Linux and BSD.
On CentOS 4 and 5, the arch command takes no arguments. On other linux distros, arch is now provided by GNU coreutils which takes --version and --help. With CentOS 4 and 5 it comes from util-linux which differs from GNU's version.
A lot of the things in GNU coreutils take only --help and --version, if you look at different Unixes that don't use GNU coreutils, they don't accept any arguments: sync, true, false, whoami, pwd, groups, users
edited Feb 22 '11 at 14:19
answered Feb 22 '11 at 13:58
Mark McKinstryMark McKinstry
8,98932423
8,98932423
add a comment |
add a comment |
:, true, false, reset, clear, line, chkdupexe and arch all take no arguments.
I'm sure they accept them, but they ignore them.
OMG.. true and false are commands!... must try this: true; echo $? ... 0 | false; echo $? ... 1 ... yup! ... an ineresting bit if info... bash is different :)
– Peter.O
Feb 22 '11 at 17:17
add a comment |
:, true, false, reset, clear, line, chkdupexe and arch all take no arguments.
I'm sure they accept them, but they ignore them.
OMG.. true and false are commands!... must try this: true; echo $? ... 0 | false; echo $? ... 1 ... yup! ... an ineresting bit if info... bash is different :)
– Peter.O
Feb 22 '11 at 17:17
add a comment |
:, true, false, reset, clear, line, chkdupexe and arch all take no arguments.
I'm sure they accept them, but they ignore them.
:, true, false, reset, clear, line, chkdupexe and arch all take no arguments.
I'm sure they accept them, but they ignore them.
answered Feb 22 '11 at 16:12
amphetamachineamphetamachine
3,81522338
3,81522338
OMG.. true and false are commands!... must try this: true; echo $? ... 0 | false; echo $? ... 1 ... yup! ... an ineresting bit if info... bash is different :)
– Peter.O
Feb 22 '11 at 17:17
add a comment |
OMG.. true and false are commands!... must try this: true; echo $? ... 0 | false; echo $? ... 1 ... yup! ... an ineresting bit if info... bash is different :)
– Peter.O
Feb 22 '11 at 17:17
OMG.. true and false are commands!... must try this: true; echo $? ... 0 | false; echo $? ... 1 ... yup! ... an ineresting bit if info... bash is different :)
– Peter.O
Feb 22 '11 at 17:17
OMG.. true and false are commands!... must try this: true; echo $? ... 0 | false; echo $? ... 1 ... yup! ... an ineresting bit if info... bash is different :)
– Peter.O
Feb 22 '11 at 17:17
add a comment |
If you accidentally run docker ps a (instead of docker ps -a) you'll actually get a message:
"docker ps" accepts no arguments.
Kinda reminds me of my wife.
add a comment |
If you accidentally run docker ps a (instead of docker ps -a) you'll actually get a message:
"docker ps" accepts no arguments.
Kinda reminds me of my wife.
add a comment |
If you accidentally run docker ps a (instead of docker ps -a) you'll actually get a message:
"docker ps" accepts no arguments.
Kinda reminds me of my wife.
If you accidentally run docker ps a (instead of docker ps -a) you'll actually get a message:
"docker ps" accepts no arguments.
Kinda reminds me of my wife.
answered Jan 10 at 8:44
Nahshon pazNahshon paz
16618
16618
add a comment |
add a comment |
1
Are you looking for a command that would error if given arguments, or that just don't process their arguments? I'm not immediately thinking of any in the former category (though one would be easy to create, and they may well exist), but the latter category has various examples. And of course there are many unix commands that do something useful without any arguments, but I'm guessing that's not what you're asking.
– lindes
Feb 22 '11 at 9:56
10
I can't help myself. Why? :P
– gnud
Feb 22 '11 at 14:11
Without further explanation what the issue is, whether "arguments" means options or operands or both, or why the question is asked in the first place, the question is unclear and too broad.
– Kusalananda
Jan 10 at 9:45