Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @ECHO OFF
- @SETLOCAL ENABLEDELAYEDEXPANSION
- Rem | Get Each Folder In Directory
- for /f "delims=" %%A in ('dir /a:d /b') do (
- Rem | Loop Lines Within ChangeLog
- set "FirstLine="
- set "LoopCount=0"
- for /f "tokens=1,2 delims= " %%B in ('type "%%~fA\changelog.txt"') do (
- Rem | Get First Line
- if "!LoopCount!"=="0" (
- Rem | Get First 2 Words Of ChangeLogs First Line
- set "FirstLine=%%B %%C"
- set "LoopCount=1"
- )
- )
- echo Folder: %%A ^| Changelog: !FirstLine!
- )
- pause
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement