当前位置:网站首页>【Batch】learning notes
【Batch】learning notes
2022-07-02 06:26:00 【bryant_meng】

不好意思上错图了

1 什么是 bat
bat 是 batch 的缩写,先看看百度百科上的定义
bat (批处理文件类型) 批处理文件,在DOS和Windows(任意)系统中,.bat文件是可执行文件,由一系列命令构成,其中可以包含对其他程序的调用。这个文件的每一行都是一条DOS命令(大部分时候就好像我们在DOS提示符下执行的命令行一样),你可以使用DOS下的 Edit 或者 Windows 的记事本(notepad)等任何文本文件编辑工具创建和修改批处理文件。
下面介绍一些基本的脚本操作
2 基本操作
注释
注释代码,英文输入法下两个冒号
::代码
暂停
运行结束后暂停,pause,黑窗口不会自动退出
代码
pause
设置变量
%echo off
SET var=2021_12_17
echo %var%
pause
使用变量的时候也是 %var% 等价于 2021_12_17
更多关于变量的操作可以参考 .bat批处理(三):变量声明、设置、拼接、截取
删除整个文件夹
分为两步
第一步删除掉所有子文件夹中的内容
del /q/a/f/s 文件夹路径\"."
第二步删除所有空文件夹(黑窗口会让自己判定一下 yes or no)
rd /s 文件夹路径\
例如删除 hello 文件夹
del /q/a/f/s C:\personal\hello\"."
rd /s C:\personal\hello\
复制 / 移动
copy src dst
move src dst
一个劲在那 cp 和 mv 的人不会只有我一个吧
切换磁盘
cd 不行,需要 cd /d
cd /d D:\xxx
别一个劲在那 cd cd 以为电脑坏了
查看文件列表
不是 ls,用 dir
dir
边栏推荐
- Installation and use of image data crawling tool Image Downloader
- Classloader and parental delegation mechanism
- SSM garbage classification management system
- Thesis writing tip2
- What if the notebook computer cannot run the CMD command
- 【MagNet】《Progressive Semantic Segmentation》
- [medical] participants to medical ontologies: Content Selection for Clinical Abstract Summarization
- Proof and understanding of pointnet principle
- What if the laptop task manager is gray and unavailable
- Implementation of purchase, sales and inventory system with ssm+mysql
猜你喜欢

【MEDICAL】Attend to Medical Ontologies: Content Selection for Clinical Abstractive Summarization

Using compose to realize visible scrollbar
![[model distillation] tinybert: distilling Bert for natural language understanding](/img/c1/e1c1a3cf039c4df1b59ef4b4afbcb2.png)
[model distillation] tinybert: distilling Bert for natural language understanding

Interpretation of ernie1.0 and ernie2.0 papers

SSM student achievement information management system
![[tricks] whiteningbert: an easy unsupervised sentence embedding approach](/img/8e/3460fed55f2a21f8178e7b6bf77d56.png)
[tricks] whiteningbert: an easy unsupervised sentence embedding approach

Classloader and parental delegation mechanism
![[introduction to information retrieval] Chapter 7 scoring calculation in search system](/img/cc/a5437cd36956e4c239889114b783c4.png)
[introduction to information retrieval] Chapter 7 scoring calculation in search system

【Mixup】《Mixup:Beyond Empirical Risk Minimization》

What if a new window always pops up when opening a folder on a laptop
随机推荐
使用百度网盘上传数据到服务器上
MMDetection安装问题
Pointnet understanding (step 4 of pointnet Implementation)
Timeout docking video generation
Solve the problem of latex picture floating
Apple added the first iPad with lightning interface to the list of retro products
自然辩证辨析题整理
基于pytorch的YOLOv5单张图片检测实现
Conversion of numerical amount into capital figures in PHP
Generate random 6-bit invitation code in PHP
[CVPR‘22 Oral2] TAN: Temporal Alignment Networks for Long-term Video
【Wing Loss】《Wing Loss for Robust Facial Landmark Localisation with Convolutional Neural Networks》
【深度学习系列(八)】:Transoform原理及实战之原理篇
Ppt skills
Using compose to realize visible scrollbar
Classloader and parental delegation mechanism
TimeCLR: A self-supervised contrastive learning framework for univariate time series representation
conda常用命令
ModuleNotFoundError: No module named ‘pytest‘
Mmdetection trains its own data set -- export coco format of cvat annotation file and related operations