Wow, keep up the great work! I made compression work on linux and added a github action to build for both mac/linux https://github.com/thecloudexpanse/sit/pull/3
Thanks! Appreciate your contributions. I haven't been testing my changes on Linux to this point, so the github action will certainly help.Wow, keep up the great work! I made compression work on linux and added a github action to build for both mac/linux https://github.com/thecloudexpanse/sit/pull/3
tell application "Finder"
--Creating an array for selected files
set SelectedItems to {}
-- Create an array for the POSIX list of paths
set POSIXList to {}
-- We transfer the paths of all selected files and directories to the array
set SelectedItems to selection as alias list
-- We go through each chosen path
repeat with SelectedItem in SelectedItems
-- We take the path in quotation marks and convert it to POSIX format and add a space
set end of POSIXList to (quoted form of POSIX path of SelectedItem) & " "
end repeat
-- Determine the root by the first selected file or directory
set RootFolder to POSIX path of ((container of SelectedItem) as alias) as text
-- Set the name of the archive
set ArchName to quoted form of (RootFolder & "Archive.sit")
-- SIT It!
do shell script "/usr/local/bin/sit -o" & space & ArchName & space & POSIXList
end tell
Stuffit 1.5.1 or 5.x archive?You can have this functionality without having StuffIt Deluxe 16 installed.
Thanks! I had noticed that my quick-and-dirty script was only handling one selection, and really needed to iterate over the list as you have done.@thecloud I have some similar solutions for shortcuts on AppleScript, so I adapted them quickly enough.
There is nothing stored in the resource fork of a StuffIt 1.5.1 file. They would not have a resource fork if they were created by the StuffIt 1.5.1 program. I proved this to myself just now by creating a new archive in StuffIt 1.5.1, adding some files to it, saving, and quitting StuffIt. Then I tried opening it with ResEdit and got the dialog "This file does not have a resource fork. Do you want to add one?"There was some debate here about the need to encode Stuffit 1.5.1 *.sit files (for uploading to Macintosh Garden, etc.) using BinHex or MacBinary. The thinking was initially that the older v1.5.1 lacked Resource Forks, but then the dialog got kind of convoluted and nothing specific was mentioned about why older SIT files may get corrupted when uploaded. Thoughts?
sit tool? i.e. if you specify a -b option, the output is encoded as .sit.bin instead of just .sit?If you are talking about why I linked to that discussion in the other forum, the answer is because if we don’t say anything here, I think some people might Google that other forum, and be a bit confused about whether they need to encode or not. But as we discussed here, it seems to be pretty clear that there is no need to encode SIT files.@JDW And the attack of cloned messages?![]()
I think that "cloned messages" is referring to your messages #31 and #32 in this thread, which looks like a minor edit that got saved as a whole new message. There were at least 3 copies of that message yesterday but one is gone today.If you are talking about why I linked to that discussion in the other forum, the answer is because if we don’t say anything here, I think some people might Google that other forum, and be a bit confused about whether they need to encode or not. But as we discussed here, it seems to be pretty clear that there is no need to encode SIT files.
macbinary encode --type 2 Archive.sitHuh? I never had any issues with it encoding native resource forks…The `macbinary` tool that ships as part of macOS is useless for most Mac files, since it only works if the input files are in AppleSingle or AppleDouble encoding.
Ah! It looks like I was mistaken... I had something called `macbinary` in /usr/local/bin which was a symbolic link to another program called `megatron`. Not sure how that got installed.Huh? I never had any issues with it encoding native resource forks…
$ macbinary TestArchive.sit
TestArchive.sit is not an adouble file.
$ macbinary encode --type 2 TestArchive.sit
encode: No such file or directory
--type: No such file or directory
2: No such file or directory
TestArchive.sit is not an adouble file
$ macbinary encode --type 2 TestLZW.sit
$ ls -la TestLZW*
-rw-r--r-- 1 ken staff 214615 Nov 21 14:21 TestLZW.sit
-rw-r--r-- 1 ken staff 214784 Nov 29 13:52 TestLZW.sit.bin