You are not logged in.

#1 2018-06-05 19:22:53

fromagegb
Member
Registered: 2018-06-05
Posts: 10

[SOLVED] failed to register

Hello.  I am now successfully running arch, and thought I should register to join and learn.  However, the answer to the registration question "date -u +%V$(uname)|sha512sum|sed 's/\W//g'" persistently was wrong.  Luckily I searched to eventually find that "Linux" can be substituted for "$(uname)", and now I can post this question.  (Perhaps that itself is a test to discern if the applicant can look things up?)

While "uname" returns "Linux", "$(uname)" means nothing, and "%V$ is not a valid format option for the date command.  What does the dollar sign mean, and do I have something wrong with my system to give that problem?

Last edited by fromagegb (2018-06-05 20:15:36)

Offline

#2 2018-06-05 19:36:49

loqs
Member
Registered: 2014-03-06
Posts: 19,113

Re: [SOLVED] failed to register

$(uname) the string of the result of a subshell executing uname.  According to man 1 date %V is a valid format control sequence.

Offline

#3 2018-06-05 19:41:56

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: [SOLVED] failed to register

Your clock was likely wrong.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#4 2018-06-05 19:42:23

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,543
Website

Re: [SOLVED] failed to register

Both the process substitution of $(...) and the date parameters are POSIX-compliant, so even if you are not using BASH as your shell, it should work fine ... unless of course you are using something like fish or maybe xonsh, or some other exotic non-POSIX-compatible (as it not even a superset of POSIX) shell.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#5 2018-06-05 20:21:26

fromagegb
Member
Registered: 2018-06-05
Posts: 10

Re: [SOLVED] failed to register

Thanks all.  Marking as solved even though I am using bash, had not changed the clock at all, and    echo $(uname)    does indeed return    Linux
I am in, and I can learn what subshells are all about.

Offline

Board footer

Powered by FluxBB