Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #270027

Re: date for week

From Greg Wooledge <greg@wooledge.org>
Newsgroups linux.debian.user
Subject Re: date for week
Date 2024-06-11 01:50 +0200
Message-ID <INWVX-21IG-5@gated-at.bofh.it> (permalink)
References <INWCB-21Cc-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Jun 11, 2024 at 07:19:42AM +0800, Jeff Peng wrote:
> While I expect the output should be:
> 
> $ date +%such_a_option
> Tuesday
> 
> or
> $ date +%such_a_option
> Tue
> 
> does date command has this option?

You can run the command "man date" to read the short version of the
documentation.  This will include the information you wanted.  Search
for "week" and it takes you right there:

       %a     locale's abbreviated weekday name (e.g., Sun)

       %A     locale's full weekday name (e.g., Sunday)

       %b     locale's abbreviated month name (e.g., Jan)

       %B     locale's full month name (e.g., January)

       %c     locale's date and time (e.g., Thu Mar  3 23:05:25 2005)

Should you ever feel a need to read the longer version of the
documentation, it's in GNU info pages.  So you would need to type
the command "info coreutils date" to get to it.  And then you'd need
to figure out the user interface of the "info" program, which is not
intuitive unless you happen to be an emacs power user already.

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

date for week Jeff Peng <jeff@tls-mail.com> - 2024-06-11 01:30 +0200
  Re: date for week Roberto C. Sánchez <roberto@debian.org> - 2024-06-11 01:30 +0200
    Re: date for week Jeff Peng <jeff@tls-mail.com> - 2024-06-11 01:50 +0200
  Re: date for week Greg Wooledge <greg@wooledge.org> - 2024-06-11 01:50 +0200
    info vs. man (was: Re: date for week) Max Nikulin <manikulin@gmail.com> - 2024-06-11 18:30 +0200
      Re: info vs. man (was: Re: date for week) Greg Wooledge <greg@wooledge.org> - 2024-06-11 20:10 +0200
        Re: info vs. man Max Nikulin <manikulin@gmail.com> - 2024-06-12 18:10 +0200
  Re: date for week "rtnetzlof@windstream.net" <rtnetzlof@windstream.net> - 2024-06-11 01:50 +0200

csiph-web