Knightmare Posted August 22, 2018 Report Share Posted August 22, 2018 I'm trying to add Display Driver Uninstaller to a collection of tools that I'm putting together but the file that is downloaded is a self extracting 7zip exe file. I know how to start the file automatically once it is downloaded but then it pops up with a screen asking me where I want to unpack the files. I would like for the whole process to be automated, since it is just for my recovery usb and I'm in any need for it at the moment. Link to comment Share on other sites More sharing options...
shawn Posted August 22, 2018 Report Share Posted August 22, 2018 have you just tried the 7z app with an output folder? 7z x -y -o"{root}PATH\" "{file}" Link to comment Share on other sites More sharing options...
Knightmare Posted August 23, 2018 Author Report Share Posted August 23, 2018 Well that was easy. Thanks! Now I just need to figure out how to exclude the root folder that has the version name, or rename the folder once it's extracted. Link to comment Share on other sites More sharing options...
shawn Posted August 28, 2018 Report Share Posted August 28, 2018 IF it was distributed with a "root folder" then you might be able to use the "-spe" feature of 7zip to ignore it. Give it a try and see if that works. Sometimes renaming the downloaded file to what would be the root folder will allow -spe to work even in situations where it otherwise fails. More about that issue here. Link to comment Share on other sites More sharing options...
shawn Posted August 28, 2018 Report Share Posted August 28, 2018 Another option where root folders are using version numbers (as is the case with DDU) in the root folder is to rename the destination folder before unzipping and then rename it back to the generic version when finished. move "\Ketarin\Drivers\DDU" "DDU v{version}" 7z -spe ... move "\Ketarin\Drivers\DDU v{version}" "DDU" Link to comment Share on other sites More sharing options...
Knightmare Posted September 16, 2018 Author Report Share Posted September 16, 2018 What is -spe? For some reason, the post commands aren't running automatically: 7z x "{file}" -o"{root}SyMenu\ProgramFiles\" -y move "{root}SyMenu\ProgramFiles\DDU v{ver}" "{root}SyMenu\ProgramFiles\Display Driver Uninstaller" del /q "{root}SyMenu\ProgramFiles\DDU*.exe" Other than it, it's doing what I want it to do. EDIT: I think the issue was that there was a Display Driver Uninstaller folder in SyMenu root folder. Issue seems to be resolved. Link to comment Share on other sites More sharing options...
shawn Posted September 19, 2018 Report Share Posted September 19, 2018 "-spe" is a 7-zip switch that means "ignore root folder" or, more specifically "eliminate duplication of root folder for extract command." More about "-spe" here. Note the case MUST BE EQUIVALENT. "post commands" only run if the download actually happened. you may need to "force download" to cause them to run. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now