Skip to content

Instantly share code, notes, and snippets.

@shibacho
Created July 4, 2016 20:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shibacho/0ad9ab63ccb83c2f84f41b1b38b8ddd6 to your computer and use it in GitHub Desktop.
Save shibacho/0ad9ab63ccb83c2f84f41b1b38b8ddd6 to your computer and use it in GitHub Desktop.
(BMS zip extraction) bmscompression.bat で圧縮したzipを解凍し元々のzipファイルを削除する
REM What do this batch file?
REM Extract and delete bms zips.
REM BMS zipファイルを解凍し、元のzipファイルを削除します
REM How to use
REM Copy to one up hierarchy of the BMS folder location and execute.
REM BMSフォルダの一つ上のフォルダに置いてダブルクリックします。
@echo off
REM location of 7za.exe
REM 7zipのコマンドライン版7zaは自分で適当な場所に置いてください
set exe="C:\7za\7za.exe"
set T1=%TIME: =0%
REM --------------------------------
for /D %%d in (*) do (
echo Change directory %%d...
cd "%%d"
for %%i in (*.zip) do (
echo "Extracting %CD%\%%d\%%i -> %%~ni"
%exe% x "-o%CD%\%%d" "%%i" >> NUL
echo "Deleting %%i"
del "%%i" >> NUL
)
cd ..
)
set T2=%TIME: =0%
echo Begin time:%T1%
echo End time:%T2%
echo Done. Enjoy bms!
PAUSE
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment