linux date英文时间,linux date命令参数及用法详解--linux查看修改系统时间(国外英文资料).doc...

linux date命令参数及用法详解--linux查看修改系统时间(国外英文资料)

linux date命令参数及用法详解--linux查看修改系统时间(国外英文资料)

The date command

The function of the date command is to display and set the system date and time.

The general format of this command is: date [option] displays the time format (in the form of +, followed by format)

Date sets the time format

The meanings of the options in the command are:

-d datestr, the date datestr displays the date described by the datestr

-s datestr - set datestr sets the date for the datestr description

-u, -universal displays or sets the universal time domain

% H hours (00.. 23)

% I hours (01.. 12)

% k hours (0.23)

% l hours (1.. 12)

% M (00.. 59)

% p shows AM or PM

% r time (hh: mm: ss AM or PM), 12 hours

% s is the number of seconds passed from 00:00:00 on January 1, 1970

% S seconds (00.. 59)

% T time (HHH: mm: ss)

% X display the format of time (% H: % S)

The % Z time zone date field

(Sun.. Sat)

(Sunday.)

(Jan. Dec)

The full name of % B is January.

% c date and time (Mon 11:8 14:12:46 CST 1999)

The first few days of a month (01.. 31)

% D date (mm/dd/yy)

The % h is the same as the % b option

The first few days of the year (001.. 366)

% m month (01.12)

The day of the week (0 for Sunday)

The first weeks of the year (00.. 53, Monday is the first day)

% x displays the format of the date (mm/dd/yy)

The last two digits of % y (1999 is 99)

% Y years (e.g. 1970, 1996, etc.)

It is important to note that only a super user can set the time with the date command, and the average user can only use the date command to display the time.

The following environment variables will affect the execution of the date command. The information is compiled at

LANG determines the default locale that will be used when LC_ALL and the corresponding environment variables (at the beginning of the LC_) do not specify the locale.

LC_ALL determines the locale of any locale of any locale that is set by LANG or any environment variable that starts with LC_.

LC_CTYPE determines the byte sequence of text data to be interpreted as a lang

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值