摘要: 001、 (base) [root@PC1 test]# ls a.txt (base) [root@PC1 test]# cat a.txt ## 测试数据 1 2 3 1 2 3 1 2 3 ## 将相同的序列转换为行 (base) [root@PC1 test]# awk '{if(NR % 阅读全文
posted @ 2022-09-22 11:57 小鲨鱼2018 阅读(166) 评论(0) 推荐(0)
摘要: 001、脚本模板 #!/bin/bash #SBATCH -J TEST_NAME # 本次作业的名称 #SBATCH -p xhacnormala # 指定作业队列名 #SBATCH -o %j.result # %j将被作业号替代 #SBATCH -e %j.error # 错误日志输出 #SB 阅读全文
posted @ 2022-09-22 11:38 小鲨鱼2018 阅读(782) 评论(0) 推荐(0)
摘要: 001、 (base) [root@PC1 test]# seq 3 > a.txt (base) [root@PC1 test]# cat a.txt ## 测试数据 1 2 3 (base) [root@PC1 test]# echo >> a.txt ## 末尾追加一个空行 (base) [r 阅读全文
posted @ 2022-09-22 09:52 小鲨鱼2018 阅读(284) 评论(0) 推荐(0)
摘要: 001、basename命令可以获取末尾文件名和末尾目录名 (base) [root@PC1 home]# basename test2/a.txt a.txt (base) [root@PC1 home]# basename test2/dir01/ dir01 002、去除文件名后缀 (base 阅读全文
posted @ 2022-09-22 09:44 小鲨鱼2018 阅读(191) 评论(0) 推荐(0)
摘要: 001、 (base) [root@PC1 home]# date +%s 1663810406 (base) [root@PC1 home]# date +%s 1663810410 date +%s //从 1970 年 1 月 1 日 00:00:00 UTC 到目前为止的秒数(时间戳) 参考 阅读全文
posted @ 2022-09-22 09:34 小鲨鱼2018 阅读(544) 评论(0) 推荐(0)