Help with Leopard's Terminal.app

One of my favorite features with the old Terminal.app was the ability to create .term files with specific username/host combinations to easily SSH to my most used servers (see: http://www.macosxhints.com/article.php?story=20061009135231362). The nice part was that those term files could specify just the initial SSH command and the window title and let the rest of the settings be inherited from the default .term file.

This no longer seems to work in Leopard as far as I can tell. I've played around with it a bit, but haven't gotten it to work without copying all settings from an existing .terminal file.

Can someone either share how that functionality can be accomplished using the new Terminal.app or point me to documentation of the new Terminal.app's plist properties? Any help would be much appreciated.

MacBook Pro, Mac OS X (10.5.1)

Posted on Nov 27, 2007 1:33 AM

Reply
11 replies

Sep 10, 2018 1:05 PM in response to Tab77

Hey man! I think I got a solution for you!

I was wondering how to create an executable .term file myself and found a breakthrough when I realized that Leopard implemented quite a few changes in Terminal.app -- namely, in the preferences window.

Here's what I did:

1. Open Terminal.app

2. Open preferences (Command + ,)

3. Notice how Terminal now has 4 tabs in Leopard! Click on the Settings tab and select a template on the left that you like (this will be the layout for your new .term file). Click the little wheel icon at the bottom and select "Duplicate Settings". This will now create a backup of the original template with which to work with (i.e. edit with an Execution String).

4. Give the new Duplicate a name of your choice. If you'd like, edit the window's size (i.e. columns, rows, the title, etc.) When your all done and ready, click the "Shell" button/tab on the right hand side (still in the overall "Settings" tab).

5. Check the little box next to "Run command" and enter your shell command in the right! This is the equivalent to the ExecutionString code on 10.4's .term file.

6. You can tweak it further by editing the "When the shell exits", or window size, etc. -- anything you like.

7. Once you've tweaked all your settings, click on the little wheel again and select "Export..." and save your .term file!

Now you can always double click on your new .term file and it'll launch your command just like before because you've tweaked its Execution String!!!

Hope this helps!

*Happy Holidays =)*

Sep 10, 2018 1:05 PM in response to Bill Scott

I too am curious if anyone has had any luck just using Terminal.app as well.

Do you think chmod 500 to the Terminal plist file would do the trick? By that I mean, essentially prevent from writing to the com.apple.Terminal.plist file? Of course only temporarily but...

🙂

Nov 27, 2007 9:47 AM in response to Tab77

The easiest workaround is to open an existing .term file and add

<dict>
<key>WindowSettings</key>
<array>
<dict>
[. . .]
<key>ExecutionString</key>
<string>ssh [CUSTOM COMMAND HERE]</string>
[. . .]
</dict>
</array>
</dict>


In particular, you'll want the key/string pair between the ellipses ([. . .]) since you'll be editing an existing .term file/plist. Place your custom command in the brackets where indicated.

hth,

msq

Feb 26, 2008 3:44 AM in response to Glenn.M

I have exactly the same problem.

I can't create a .terminal file with some parameters and where the parameters not set would be loaded from the default preferences from Terminal.app.

The fact that it creates a new setting set for each ssh shortcut I use is really a big problem for me : I can't change a settings for all my shortcuts. For example, I changed my key mappings lately, and now if I want to use it for each ssh shortcut, I have to re-save each single ssh shortcut after having modified the key mapping for each single one...

May 2, 2008 8:56 AM in response to Tab77

This really is a bad excuse for coding. When you click a saved .terminal link, you get another entry in the plist file.

I use OnMyCommand to right click on my desktop and select a terminal (ssh connection. It launches a simple open command that opens the .terminal file. Duplicates everywhere. Come on apple, get us a workaround!!!!!

May 26, 2008 6:58 PM in response to Tab77

Another example of Apple making a formerly useful program less and less useful with every release. Even going in and modifying the .term file directly does NOT allow you to choose where on the screen the window pops up. I had managed, through this ridiculous workaround of editing the file in a text editor, to have a few icons that opened up connections to servers with the proper coloring and proper window placement. Now Apple has made that flat-out impossible instead of just ludicrously difficult.

I guess it's time to download iTerm and give up on this stupid application. I hope someone is working on replacements for iPhoto and iCal.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Help with Leopard's Terminal.app

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.