Tower Help & Support

Command Line Environment

When you run Git from the command line, it runs in the environment as set up by your Shell. GUI OS X apps, however, have no knowledge about your shell - and the PATH environment can be changed in many different places. The actual environment they run in even varies depending on how the application has been started (from Spotlight, Finder, the Dock, or from the Terminal with the open command or our CLI tool)...

To provide you with a configurable environment, Tower supports the definition of environment variables. These variables are stored in a file named environment.plist, which is formatted in PLIST XML and can be located under ~/Library/Application Support/com.fournova.Tower3/.

From version 10.2 onwards, you can define these custom environment variables within the new Environment tab in Settings.

A sample to define your path could look like this:

Key: PATH
Value: /usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin

You can add additional key-value pairs as needed. For example, if your hook script needs some variable to work properly, you can introduce it like this in the environment.plist:

If your hook script needs some variable to work properly, you can introduce it like this in the environment.plist

Key: YOUR_VARIABLE
Value: YOUR_VALUE

In case you're using a special authentication mechanism, you can set this up here too.

Please note that environment variables like $HOME aren't supported in the environment.plist. Also note that using relative paths might cause problems, which is why you should consider using absolute paths.