sit - Create StuffIt archives on Unix systems

thecloud

New Tinkerer
Oct 2, 2025
28
24
3
Last edited:
  • Like
Reactions: eric

V.Yakob

Tinkerer
Sep 6, 2023
115
45
28
Syktyvkar
@thecloud I have some similar solutions for shortcuts on AppleScript, so I adapted them quickly enough.

AppleScript:
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
 

Attachments

  • shortcut.png
    shortcut.png
    167.8 KB · Views: 7
  • Sit It!.png
    Sit It!.png
    481.2 KB · Views: 7