- #! /bin/sh
- NowDateTime=$(date +%Y%m%d%H%M%S)
-
- mkdir -p $NowDateTime
- cp Makefile $NowDateTime/
- cd $NowDateTime
- vim test.c
- if [ ! -f test.c ]
- then
- cd ..
- rm -r $NowDateTime
- fi
- #! /bin/sh
- NowDateTime=$(date +%Y%m%d%H%M%S)
-
- mkdir -p $NowDateTime
- cp Makefile $NowDateTime/
- cd $NowDateTime
- vim test.c
- if [ ! -f test.c ]
- then
- cd ..
- rm -r $NowDateTime
- fi