Forklift Setapp not working

Hi,

Forklift from SetApp isn’t working. Looking at the script I think the layout of menus has changed as the direct menu item “Copy Path to Clipboard” seems to have gone. It has been replaced by a “Copy Path” submenu under the File menu, with format options inside it (UNIX, URL, Percent-Decoded URL, Name, Terminal, Windows).

I used Claude to update the script to the following, which now works. There might well be a better of doing it.

use framework "Foundation"
use AppleScript version "2.4" -- Yosemite (10.10) or later
use scripting additions
property NSMutableCharacterSet : a reference to current application's NSMutableCharacterSet

on urlEncode(input)
	tell current application's NSString to set rawUrl to stringWithString_(input)
	set charset to NSMutableCharacterSet's URLQueryAllowedCharacterSet's mutableCopyWithZone:(missing value)
	charset's removeCharactersInString:"?"
	set theEncodedURL to rawUrl's stringByAddingPercentEncodingWithAllowedCharacters:charset
	return theEncodedURL as Unicode text
end urlEncode

tell application "System Events"
	tell process "ForkLift"
		set the clipboard to ""
		delay 0.3
		click menu item "UNIX" of menu 1 of menu item "Copy Path" of menu "File" of menu bar 1
		delay 0.3
		set theURL to "file://" & my urlEncode(the clipboard)
	end tell
end tell

return theURL