Batch-script-del

提供:Dev Guides
2020年6月23日 (火) 09:41時点におけるMaintenance script (トーク | 投稿記録)による版 (Imported from text file)
(差分) ← 古い版 | 最新版 (差分) | 新しい版 → (差分)
移動先:案内検索

バッチスクリプト-DEL

このバッチコマンドは、ディレクトリではなくファイルを削除します。

構文

del [filename]

次の例は、 del コマンドのさまざまなバリエーションを示しています。

@echo off
Rem Deletes the file lists.txt in C:\
del C:\lists.txt
Rem Deletes all files recursively in all nested directories
del/s *.txt
Rem Deletes all files recursively in all nested directories , but asks for the
confirmation from the user first
Del/p/s *.txt

出力

すべてのアクションは、バッチファイルの説明に従って実行されます。