command line registry tracking and versioning

Discussion in 'Software' started by ntmgc246, Dec 25, 2005.

  1. ntmgc246

    ntmgc246 Private E-2

    Hi,

    I would like to keep track of what's happening with the registry when various things are installed and executed, and have this info available for scripting with the usual tools (perl, shell(sh/ksh/bash)). So I would like to create and keep snapshots (I've installed a version control software for this) of complete WinXP registry, so I can review changes between snapshots. Creating of snapshots is needed in REGEDIT4 format, and must be fully executable from command line (no desktop interaction). [I actually have Cygwin installed for command-line access.]

    Any idea which tools can dump into regedit4 format from command line? (regedit / regedt32 only dumps in regedit5 format :rolleyes: )

    thx !

    PS: the snapshots should always have same order of lines, so version control doesn't keep 5MB for every snapshot.
     
  2. ntmgc246

    ntmgc246 Private E-2

    OK, I found the answer: export as reg5, then convert into (nearly) reg4:

    regedit.exe /e f2.reg5

    /cygdrive/c/WINDOWS/system32/cmd /C 'type f2.reg5 > f2.reg5.typed.reg4'

    perl -pe 'BEGIN{$/="\r\n\r\n"};s/Windows Registry Editor Version 5.00/REGEDIT4/; s/\\\r\n //g;' f2.reg5.typed.reg4 | perl -pe '/=hex\((2|7)\):/ and s/([0-9a-f][0-9a-f]),(..)(,|\r)/$1$3/g;' > f2.reg4

    hope that helps !

    ntmgc246
     

MajorGeeks.Com Menu

Downloads All In One Tweaks \ Android \ Anti-Malware \ Anti-Virus \ Appearance \ Backup \ Browsers \ CD\DVD\Blu-Ray \ Covert Ops \ Drive Utilities \ Drivers \ Graphics \ Internet Tools \ Multimedia \ Networking \ Office Tools \ PC Games \ System Tools \ Mac/Apple/Ipad Downloads

Other News: Top Downloads \ News (Tech) \ Off Base (Other Websites News) \ Way Off Base (Offbeat Stories and Pics)

Social: Facebook \ YouTube \ Twitter \ Tumblr \ Pintrest \ RSS Feeds