shell 获取当前日期,当前时间
2016-04-04 23:03
543 查看
1. 获取当前日期:
shell代码:
2. 获取当前日期和时间
shell代码:
结果:
shell代码:
cur_date="`date +%Y-%m-%d`"结果:
2. 获取当前日期和时间
shell代码:
cur_dateTime="`date +%Y-%m-%d,%H:%m:%s`"
结果:
相关文章推荐
- [置顶] linux shell 中的 2>&1 用法说明
- linux shell 中的 2>&1 用法说明
- Shell脚本学习之sed详解
- shell 之 printf
- Shell中的字符串操作
- Windows PowerShell妙用
- android shell打包
- 小黑的日常折腾-复制外部命令的可执行文件和依赖库文件到指定目录下的对应目录
- 将PHP作为Shell脚本语言使用
- Shell Script介绍及变量使用
- -bash: rz: command not found
- shell 中的for、while循环及if语句
- 慕课linux学习笔记(二)Xshell与虚拟机的连接
- shell 与 /etc/shells 功能
- Linux Shell 学习笔记3:环境变量的操作及相关命令
- shell 常用命令语法简介
- 输入adb shell 时 提示error: more than one device and emulator
- 输入adb shell 时 提示error: more than one device and emulator
- 深度学习整体认识Deep Learning in a Nutshell
- Shell练习 验证号码