unknown bash command?
unknown bash command?
I look at many places, but could not find bash information for d, gn and un. I saw this fragment for bash: Code:
[ "`d -gn`“ : "‘`d -un`” Thanks. |
d is obviously an abbreviation for one bash command, and -gn -un are arguments it accepts.
I thought possibly "date", however it does not appear to have those arguments, or at least mine does not. Any more details about how it is used? Where did you get that from? Someone's script? Horrible script writer if so. |
It looks as if it may have come from here (bottom answer): http://unix.stackexchange.com/questi...rs-under-linux
where it is: Code:
[ "`id -gn`" = "`id -un`" ] |
Excellent find hydrurga.
Well obviously it was misquoted or "found" somewhere else where it was already corrupted from it's original form. |
Thank you for responding.....
Quote:
Ops... I have to make corrections.... Excerpts: Code:
The Default umask The error on my part is "d" command should be "id" command. Now I know what id is,. I can now guess what gn and un are, i.e. group name and user name. but I was not able to find it in bash documentation.... |
If that's really what the book quotes, then write to the publisher and inform them that they have an error.
|
As for the pieces, the [ is like the program test. The backticks ` are command substitution and could better be written as $( … )
|
Sorry folks.
Please see corrections in original post. Thank you. |
Quote:
Does this resolve you question? |
!
Quote:
I found the answer in here: man id |
All times are GMT -5. The time now is 06:15 PM. |