linux命令整理
2017-01-23 10:13
253 查看
1.) 显示文件夹下各个文件大小(包含目录和文件)
du -hs *
2.) shell校验日期格式有效性
du -hs *
2.) shell校验日期格式有效性
#!/bin/sh # para # $1 date format # $2 date value # if input bit not enough, result comes to be wrong function check_date() { echo "##### " $* " #####" if [[ "$2" = `date -d "$2" +"$1"` ]] then echo "format($1) date($2)" right return 0; else echo "format($1) date($2)" wrong return 1; fi } check_date "$1" "$2"
相关文章推荐
- linux命令名字由来--整理
- LINUX最常用命令整理
- linux 常用命令整理
- 近期常用linux命令整理
- 拿到一个linux下的shell之后,有用的命令整理
- LINUX: 常用命令解析和技巧整理
- linux下mysql命令大全 整理
- [整理]Linux命令--档案目录管理
- [整理]Linux命令--复制文件和目录
- linux下mysql命令大全 整理
- 关于linux 的基本命令(整理)
- Linux 命令整理(一)
- Linux 命令整理(一)
- Linux命令整理
- Linux常用操作命令整理
- LINUX入门级常用命令20条整理
- linux常用命令(整理中)
- Linux下的基本命令和工具--整理笔记
- Ubuntu Linux系统下apt-get命令整理
- redhat-linux基础命令整理