c++ - How would I get a project to run in Terminal through Xcode? -



c++ - How would I get a project to run in Terminal through Xcode? -

is possible me nail run in xcode , have project compiled g++ compiler open terminal window , run it?

so pretty much want xcode run these commands when nail run:

g++ [source] ./a.out

and @ point terminal window open programme running.

how (if it's possible)?

i had settle running programme in terminal window kept open while coding in xcode. had xcode compile programme 'a.out' file whenever built programme in xcode. did running 'run script'. here's how did it:

go screen can edit build settings. under 'targets' in side menu, click on project go 'build phases' tab , click 'add build phase' button from list drops downwards select 'add run script'

then input xcode when building programme in box under shell command box. commands this:

cd [path program]

g++ [program]

(i can't block code formatting work here).

now have maintain terminal window open in directory of program. run a.out whenever need run programme in terminal. not exclusively automated, there's 1 step had hoped for, isn't bad.

c++ xcode terminal g++

Comments

Popular posts from this blog

How do I check if an insert was successful with MySQLdb in Python? -

delphi - blogger via idHTTP : error 400 bad request -

postgresql - ERROR: operator is not unique: unknown + unknown -