ed1t
ed1t

Reputation: 8709

get current path of the .app file being executed

How can I get the current path of my .app which is being executed in cocoa mac application?

I tried using NSTask to do pwd but returns me /

Upvotes: 6

Views: 5533

Answers (1)

ed1t
ed1t

Reputation: 8709

I found it by using [[NSBundle mainBundle] bundlePath]

Upvotes: 14

Related Questions