Re: How to make Xcode launch a different app when "Running" my code?
On 18 Sep 2016, at 14:54, Uli Kusterer wrote: > > On 18 Sep 2016, at 12:02, Gabriel Zachmann wrote: >> When I "Run" my code in Xcode (i.e., hit CMD-R), I would like Xcode to build >> the code, copy the product to its destination, >> and then run a *different* application, not the product it has built. >> (all on macOS, not iOS) > > Sure! Pick "Edit Scheme..." from the target selection popup in your Xcode > window's toolbar. There, select the "Run" entry on the left. In the "Info" > tab, you can set the executable to run to any executable in your project, or > another arbitrary one. This is IMO the best approach, but as an addendum you probably want to think about whether the scheme should be shared or not. By default, build schemes are per user, so if you have multiple people working on your project you’ll need each of them to set this up, and depending on how you’ve set your source control up it might also not check in per-user things in the project file (I know I tend to set things up so per-user stuff isn’t saved, to avoid bloating commits with random Xcode state that nobody else cares about). There’s a “Shared” checkbox on “Edit Scheme…” sheet for that purpose. IMHO this is quite a confusing area, because by default Xcode auto generates schemes and they’ll look them same for everyone who opens a project, which leads people to expect that changes they make will persist for everyone else. That isn’t the case. Kind regards, Alastair. -- http://alastairs-place.net ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: How to make Xcode launch a different app when "Running" my code?
Add a post build script to launch something? Look in build phases. Sent from my iPhone > On Sep 18, 2016, at 5:02 AM, Gabriel Zachmann wrote: > > When I "Run" my code in Xcode (i.e., hit CMD-R), I would like Xcode to build > the code, copy the product to its destination, > and then run a *different* application, not the product it has built. > (all on macOS, not iOS) > > Does anyone know how that is possible? > > I haven't found it in Xcode's documentation, and couldn't find a hint with > Google. > I am using Xcode 7.3.1. > > Thanks a lot in advance. > > Best regards, > Gabriel. > > > > > > ___ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > https://lists.apple.com/mailman/options/cocoa-dev/zav%40mac.com > > This email sent to z...@mac.com ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: How to make Xcode launch a different app when "Running" my code?
On 18 Sep 2016, at 12:02, Gabriel Zachmann wrote: > When I "Run" my code in Xcode (i.e., hit CMD-R), I would like Xcode to build > the code, copy the product to its destination, > and then run a *different* application, not the product it has built. > (all on macOS, not iOS) Sure! Pick "Edit Scheme..." from the target selection popup in your Xcode window's toolbar. There, select the "Run" entry on the left. In the "Info" tab, you can set the executable to run to any executable in your project, or another arbitrary one. Cheers, -- Uli Kusterer "The Witnesses of TeachText are everywhere..." http://stacksmith.org ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
Re: How to make Xcode launch a different app when "Running" my code?
You could try adding a run shell script phase at the end of the compilation to substitute the executable. -- __Pascal Bourguignon__ > On 18 Sep 2016, at 12:02, Gabriel Zachmann wrote: > > When I "Run" my code in Xcode (i.e., hit CMD-R), I would like Xcode to build > the code, copy the product to its destination, > and then run a *different* application, not the product it has built. > (all on macOS, not iOS) > > Does anyone know how that is possible? > > I haven't found it in Xcode's documentation, and couldn't find a hint with > Google. > I am using Xcode 7.3.1. > > Thanks a lot in advance. > > Best regards, > Gabriel. > > > > > > ___ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > Please do not post admin requests or moderator comments to the list. > Contact the moderators at cocoa-dev-admins(at)lists.apple.com > > Help/Unsubscribe/Update your Subscription: > https://lists.apple.com/mailman/options/cocoa-dev/pjb%40informatimago.com > > This email sent to p...@informatimago.com ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com
How to make Xcode launch a different app when "Running" my code?
When I "Run" my code in Xcode (i.e., hit CMD-R), I would like Xcode to build the code, copy the product to its destination, and then run a *different* application, not the product it has built. (all on macOS, not iOS) Does anyone know how that is possible? I haven't found it in Xcode's documentation, and couldn't find a hint with Google. I am using Xcode 7.3.1. Thanks a lot in advance. Best regards, Gabriel. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com