Skip to content

Instantly share code, notes, and snippets.

@AdilHindistan
Last active August 29, 2015 14:16
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AdilHindistan/0ae2e69643996c3ac75a to your computer and use it in GitHub Desktop.
Save AdilHindistan/0ae2e69643996c3ac75a to your computer and use it in GitHub Desktop.
## Find all files under C:\ that has changed today (Windows / Batch Scripting)
C:\>forfiles /p c: /s /d +0 /c "cmd /c echo @fdate 0x09 @path"
3/8/2015 "C:\Users\Adil\AppData\Local"
3/8/2015 "C:\Users\Adil\AppData\Local\Temp"
3/8/2015 "C:\Users\Adil\AppData\Local\Microsoft\Windows"
3/8/2015 "C:\Users\Adil\AppData\Local\Microsoft\Feeds\FeedsStore.feedsdb-ms"
3/8/2015 "C:\Users\Adil\AppData\Local\TechSmith\Snagit\CachedNotifications.json"
3/8/2015 "C:\Users\Adil\AppData\Roaming\Microsoft\Windows\Themes"
3/8/2015 "C:\Users\Adil\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\System Tools\Command Prompt.lnk"
3/8/2015 "C:\Users\Adil\AppData\Roaming\Microsoft\Windows\Themes\CachedFiles"
3/8/2015 "C:\Users\Adil\AppData\Roaming\Microsoft\Windows\Themes\CachedFiles\CachedImage_1920_1200_POS4.jpg"
/p <start_path>, default = `pwd`
/s recursive
/d dd/mm/yyyy or -x days from today, +x days from today
@fdate file date
0x09 TAB char
@path file path
http://ss64.com/nt/forfiles.html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment