Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

AmestrisXServe

macrumors 6502
Original poster
Feb 6, 2014
263
4
On on eof my servers, every time that I launch terminal, it resets to the factory settings, and the factory themes.

I have done all of the following:
Create custom theme (Theme.terminal)
Import Theme.terminal
Select Theme.terminal
Set Theme.terminal as default.
Open a Terminal window (the settings work).
Exit Terminal, and relaunch: Settings revert, and Theme.terminal is absent; needs to be imported again.

I further have opened Terminal.app, and navigated to the path:
Terminal.app/Contents/Resources/Initial Settings/

In that directory, I have added Theme..terminal, but it is still not in the list of themes.

I then replaced basic.terminal with a (renamed) Theme.terminal.

This has no effect.

Does anyone have any suggestions in order to permanently add a theme file, or what plist keys to edit, in order to add one? Perhaps some plist file has incorrect permissions attributes?

Is this a known bug?

The specific Terminal version is 2.0.2.
 
On on eof my servers, every time that I launch terminal, it resets to the factory settings, and the factory themes.

I have done all of the following:
Create custom theme (Theme.terminal)
Import Theme.terminal
Select Theme.terminal
Set Theme.terminal as default.
Open a Terminal window (the settings work).
Exit Terminal, and relaunch: Settings revert, and Theme.terminal is absent; needs to be imported again.

I further have opened Terminal.app, and navigated to the path:
Terminal.app/Contents/Resources/Initial Settings/

In that directory, I have added Theme..terminal, but it is still not in the list of themes.

I then replaced basic.terminal with a (renamed) Theme.terminal.

This has no effect.

Does anyone have any suggestions in order to permanently add a theme file, or what plist keys to edit, in order to add one? Perhaps some plist file has incorrect permissions attributes?

Is this a known bug?

The specific Terminal version is 2.0.2.
Where are the themes supposed to be stored? Maybe there is a permissions issue on the folder where they are stored?

I suggest this because I tried this. Changed settings, created a new theme even and restarted Terminal each time. Every time it held the settting I made. So what you are experiencing is not happening to me. I'm on 10.5.8.
 
That is something that I would like to know, as changing the files inside the Terminal.app package has had no effect. This is clearly, aberrant behaviour, which is why I am posting about it.

In my reckoning, the the,es should be in that path, specified above. I do not know where themes that you manually add are (or should be) stored, nor do I know what preference files handle theme and terminal setting arbitration.

I have examined several plists, but I do not know which are pertinent, and if I can use absolute paths for the key value normally assigned to 'Basic', or if that is a pointer to an internal component.

Naught that I have done has made any difference, at all, at all.
 
Little off topic:

I do not understand why people quote question, especially when their answer is first reply in the thread :confused:
 
Pretty sure that stuff is saved in your bash profile.

That would be rather odd, given that there is a com.apple.terminal.plist file, that has keys for this sort of thing. The bash.profile is useful to set bash-specific settings, but not settings for Terminal.app

For example, you can use bash-settings to set colours for specific console message, set up an initial path, etc.; but not things specific to Terminal.app, such as a background image. Those settings should be in the plist, and the themes should be inside the Terminal.app package, so it is baffling that shifting them about doesn;t seem to do anything, although I have not reset the server since doing this, so it may not do a thing until I do.

(I have exited, and relaunched Terminal.app.)

Do you know if v2.0.2 is the latest version of Terminal for 10.5.8?

Little off topic:

I do not understand why people quote question, especially when their answer is first reply in the thread :confused:

I quote people, to ensure that there is no confusion with regard to my responses. In the case of an initial post, you are correct that it is not necessary, however, it is a habit that I have, to keep threads consistent, and especially important in this post, to ensure that my response is visible directed at the desired subjects.
 
Not the slightest odd. In doing so Apple would be adhering to the POSIX compliance of Mac OS X and following standard terminal forms.
 
I don't know if this will help but here's what I found

That's obviously not current, but it led me to look at Terminal on the G4 at work. The G4 here is running Leopard, but guess what? Unlike my G4 at home it's exhibiting the same behaviour you describe. So, I poked around.

Down there at the bottom where you make your settings is the + and - buttons to add or subtract settings. Right NEXT to it is a large button that says DEFAULT.

Once you have your settings set the way you want them in preferences (for Terminal) press the DEFAULT button! It will gray out and your settings will be saved!

I quit out of Terminal on the work G4 having done this and bingo, settings were retained when I reopened Terminal!

Hope that helps!

Hmmm…oh wait you already tried that right?

EDIT: I think the plist file is here: ~/Library/Preferences/com.apple.Terminal.plist
 
Last edited:
I don't know if this will help but here's what I found

That's obviously not current, but it led me to look at Terminal on the G4 at work. The G4 here is running Leopard, but guess what? Unlike my G4 at home it's exhibiting the same behaviour you describe. So, I poked around.

Down there at the bottom where you make your settings is the + and - buttons to add or subtract settings. Right NEXT to it is a large button that says DEFAULT.

Once you have your settings set the way you want them in preferences (for Terminal) press the DEFAULT button! It will gray out and your settings will be saved!

I quit out of Terminal on the work G4 having done this and bingo, settings were retained when I reopened Terminal!

Hope that helps!

Hmmm…oh wait you already tried that right?

EDIT: I think the plist file is here: ~/Library/Preferences/com.apple.Terminal.plist

That would be the file that I have examined to date.

Not the slightest odd. In doing so Apple would be adhering to the POSIX compliance of Mac OS X and following standard terminal forms.

I will examine this, but I reiterate, that I doubt that Terminal.app-specific settings would apply there, as those settings only apply to bash, and Terminal.app also handles non-standard shell settings. To my knowledge, bash-profile handles ANSI and ASCII colour codes, but not HSV/RGB codes for 24-bit colour depth, background images, and other programme-specific settings, set per terminal programme.

The settings should be stored in com.apple.terminal.plist, but I am unsure of the formatting involved for setting a custom file, in place of 'Basic' in the keys therein.

I manually edited the permissions on com.apple.terminal.plist, and setting 'everyone' to r/w fixed this problem. Somehow, wheel was removed from the plist.

I don;t know how I removed system.wheel from the plists in my account: I can only suspect that at some point, that I'd propagated permissions from a source that did not include wheel. This could mean that I would be in for more broken plists, and as the wheel user is not visible in the normal operations dialogue, I am going to need to jump through some hoops to fix this.
 
Last edited:
That would be the file that I have examined to date.
Does the modification date of ~/Library/Preferences/com.apple.terminal.plist change after you make settings changes in Terminal and quit? That file is where all the settings are saved. If not, I'd suspect incorrect permissions on it or your home folder in general, or a corrupt plist. Try just deleting that preference file if you haven't already to see if it makes a difference.
In 10.9 Terminal, for a theme to apply in windows on startup, it's necessary to go to the "Startup" panel in preferences and set that specific theme under the "On startup, open New window with settings" preference. Whether I've set something else as default has no effect on that.
 
Last edited:
Does the modification date of ~/Library/Preferences/com.apple.terminal.plist change after you make settings changes in Terminal and quit? That file is where all the settings are saved. If not, I'd suspect incorrect permissions on it or your home folder in general, or a corrupt plist. Try just deleting that preference file if you haven't already to see if it makes a difference.
In 10.9 Terminal, for a theme to apply in windows on startup, it's necessary to go to the "Startup" panel in preferences and set that given them under the "On startup, open New window with settings" preference. Whether I've set something else as default has no effect on that.

I added System and System Users groups to the Admins group, which is set for r/w access on all plist files. That is the easiste way that I know to repair a wheel permissions problem :)

I had previously set this a number of times, and went through plists with a manual editor, finally resorting to manually adding files to the Terminal.app package. As none of this worked, I expected this to be a permissions fault, however I wasn;t certain on this until I re-excamined the files, and saw that _system and _wheel where both absent.

I'm running OSX Server, so a a small side-step to Workgroup manager, adding System (sys) and System Users (wheel), to the Admins group, and the SysOp group--both custom defined--that are set on most files as r/w, fixed the problem.

Note that my Admins group, differs from the stanndard 'Adminisrators' group. I have seven levels of user access: SysOp, Admins, Moderators, Members, Users, Operators, and Public.

Each group above Public has a specific number of users, with smaller numbers, as the hierarchy evolves, through to SysOp, which other than sys, and wheel, has exactly two users, of which, I am one.

Admins is specific to members capable of server maintenance, differing from the Administrators group; Moderators have limited r/w access to User directories, but not to Admin and above directories, whereas Members is for the accounts that are able to access specific, r/w, shared paths. Users, and Public, should I believe be self-explanatory.

What I believe happened, is that I had cloned my user account to another volume in the past, and when i restored it recently, I had to repair the user account, by renaming the old account, and this retaining that account index number, and make a new account with the correct username, but with a new user index number. As all of the permissions were tied to an index number, I propagated the permissions for my user, a SysOp, directly, which somehow overwrote the normal wheel user on those files under my account's root path.

As SysOp is already flagged on essentially everything, adding wheel and sys to SyOp should repair this, and any other faults.

My terminal plist now works as it should, and it retains changes. (The .bash_profile does not handle this level, or type, of application-specific settings and preferences.)

P.S. Before anyone states this as a bad isea, or a security risk: Adding wheel to another group, is not the same as adding a user to the wheel group. The latter can be a very bad idea, and is only applicable to OSX 10.0 through 10.2, or 'Mac OS X Server' (Rhapsody) v1 through v3, where an administrator may be, or will be, part of the wheel group, and updates done from those versions of MacOS.
 
Last edited:
I added System and System Users groups to the Admins group, which is set for r/w access on all plist files.

That file, and anything else in ~/Library/Preferences, really only needs the owner to have r/w permissions. Group permissions are irrelevant if the owner is set correctly.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.