sindresorhus / LaunchAtLogin-Legacy

Add “Launch at Login” functionality to your macOS app in seconds
MIT License
1.56k stars 123 forks source link

Is code signing necessary? #14

Closed B00jan closed 6 years ago

B00jan commented 6 years ago

Im trying to test the app without signing the app and it is not working. Is it necessary to sign it?

deadcoder0904 commented 6 years ago

Yes I was also wondering the same thing.

Another question: Does this work in Development, i.e, without putting it in Applications folder?

sindresorhus commented 6 years ago

Your questions are about launching at login in general and not specifically about this module. LaunchAtLogin just simplifies the process. Better direct questions like these to Apple.

sindresorhus commented 6 years ago

Is code signing necessary?

Not sure. I always codesign, so hasn't really been a problem for me.

Another question: Does this work in Development, i.e, without putting it in Applications folder?

Yes, but it might pick the wrong version of the app then. Archived versions (The ones in the Organizer) are also picked up by the launch service for some dumb reason. So if you have older versions there without LaunchAtLogin, the system might pick on of those at startup instead...

B00jan commented 6 years ago

I've noticed this error in my console. Do you now what am i doing wrong? Could not locate login item com.my.project-LaunchAtLoginHelper in the caller's bundle Could not enable login item: com.my.project-LaunchAtLoginHelper: 3: No such process

deadcoder0904 commented 6 years ago

@B00jan I got this too before and thank god I did save this StackOverflow answer.

I didn't know if it made it work but as sindresorhus has said here it gives me this exact response. I'll test it later tonight & post the solution if it works :)

sindresorhus commented 6 years ago

@B00jan Look in the exported app bundle if you have the helper app included and that it uses that bundle ID (check its Info.plist).

B00jan commented 6 years ago

No helper app included. So i guess something went wrong when importing pod in my project.

B00jan commented 6 years ago

Is "Run script only when installing", suposed to be checked in Run Script?

sindresorhus commented 6 years ago

It should not be checked.

B00jan commented 6 years ago

cp: /Users/ME/Library/Developer/Xcode/DerivedData/manager-goquldsquoncdqeegtdrwisfiodm/Build/Products/Debug/DSManager.app/Contents/Frameworks/LaunchAtLogin.framework/Resources/LaunchAtLoginHelper.app: No such file or directory : no identity found Command /bin/sh emitted errors but did not return a nonzero exit code to indicate failure

I have done everything from start, this is the error that i'm getting now. Sory for this much questions about something that is maybe obvious for you. I'm new at macOs programing, so some of my questions are probably stupid.

deadcoder0904 commented 6 years ago

I get the same error & posted it on another issue. If you do find a solution plz post it :)

B00jan commented 6 years ago

@deadcoder0904 Of course!

deadcoder0904 commented 6 years ago

@B00jan I used this project with Carthage & it worked. Here's a sample link that worked - https://github.com/deadcoder0904/LaunchAtLoginCart

B00jan commented 6 years ago

@deadcoder0904 tried it just now, and everything works.Thank you!. Code signing isn't necessary for launch at login to work.

deadcoder0904 commented 6 years ago

@B00jan Working with CocoaPods too. Find a solution here :)