westernhoogl.blogg.se

Copyclip helper
Copyclip helper





copyclip helper

In order to get the helper to open files that your main application needs, you have to create a in-secure Bookmark and use IPC to send that bookmark to the helper (I only just discovered this myself this year, I’ve been moving the users files around for a while now). It can only access a few folders on the system (namely the app support folder). The biggest problem with a Sandboxed helper is file access, it doesn’t have the same rights to files as your main application. There’s an implementation in my Sandbox Kit or (almost certain) there’s one in the MBS plugin. Helper apps should be run from Contents/Library/Helpers I can’t use a shell command, it’s not allowed in the MAS. But honestly, you only need something like the script above. Been there, done that: have had much fun.ĪFAIR there is a replacement (MBS?) so that you can use the shell for MAS. If theOutput “” and instr(theOutput, “can’t get real path”) = 0 then print theOutputįunction shellEncode(inValue as string) as stringĭim rvalue as string = replaceAll(inValue, " ", "\ ")Īnything else besides “ditto” gives problems with permissions. If right(AppPath, 4) “.app” then appPath = appPath + “.app”ĭim cmd as String = "/bin/mkdir -p " + appPath + “/Contents/Library/LoginItems”ĭim theOutput as string = doShellCommand(cmd)ĭim CountSlashes as integer = CountFields(ProjectShellPath, “/”)ĭim ProjectName as string = NthField(ProjectShellPath, “/”, CountSlashes)ĭim ProjectPath as String = Left(ProjectShellPath, Len(ProjectShellPath) - Len(ProjectName))ĭim PathToScheduler64 as String = ProjectPath + shellEncode(“Builds - max scheduler.rbp/OS X 64 bit”)Ĭmd = "usr/bin/ditto " + PathToScheduler64 + " " + appPath + “/Contents/Library/LoginItems” 'copy the scheduler to app/library/loginitemsĭim appPath as string = currentBuildLocation + “/” + shellEncode(currentBuildAppName) Here is my script to copy a helper into the main app:

copyclip helper

You can use the shell in your own IDE script.







Copyclip helper