-
June 5th, 2020, 20:52 #1
- Join Date
- Aug 2009
- Posts
- 261
Quickly zip to Extension (Ext) from Windows file menu (or Mod or Pak)
To quickly make an extension file from a directory from the Windows menu
Create a file named "sendToExt.ps1" with contents of:
Code:$extensionDirectory = "$args" $zipFile = $extensionDirectory + ".zip" $extFile = $extensionDirectory + ".ext" If (Test-path $zipFile) { Remove-Item $zipFile } If (Test-path $extFile) { Remove-Item $extFile } Add-Type -assembly "system.io.compression.filesystem" [io.compression.zipfile]::CreateFromDirectory($extensionDirectory, $zipFile) Rename-Item $zipFile -NewName $extFile
Then to add to the Windows menu, you have two choices:
1) To add under the "Send To" menu:
a) Create a shortcut to the powershell script
b) Put the shortcut in "C:\Users\<your user name>\AppData\Roaming\Microsoft\Windows\SendTo" (or just paste "shell:sendto" in file explorer)
b) Change the properties of the shortcut to have target of: powershell.exe "<path to powershell script>\\sendToExt.ps1"
2) To have as a separate menu item
a) Create a file name "regAddExt.reg" with contents of:
Code:Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Classes\directory\shell] @="Send To FG Ext" [HKEY_CURRENT_USER\Software\Classes\directory\shell\Send To FG Ext\command] @="powershell <path to powershell script>\\sendToExt.ps1 \"%1\""
You can easily modify this to make Mod or Pak files as well by changing the names to ".mod" or ".pak" instead
-
June 6th, 2020, 02:38 #2
Nice, thx for sharing.
Problems? See; How to Report Issues, Bugs & Problems
On Licensing & Distributing Community Content
Community Contributions: Gemstones, 5E Quick Ref Decal, Adventure Module Creation, Dungeon Trinkets, Balance Disturbed, Dungeon Room Descriptions
Note, I am not a SmiteWorks employee or representative, I'm just a user like you.
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks