-
Notifications
You must be signed in to change notification settings - Fork 8.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for "User Default" settings #3369
Conversation
These are settings that apply to _every_ profile, before user customizations. This can be placed in the globals under the "defaultSettings" key. It's a blob of profile settings that will be parsed just like a profile, and applied to profiles after default&dynamic profiles, but before user profiles.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love to figure out what the name of this setting should be, but I adore this change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks alright to me, but settings are just getting more and more confusing, IMO.
doc/cascadia/SettingsSchema.md
Outdated
@@ -8,6 +8,7 @@ Properties listed below affect the entire window, regardless of the profile sett | |||
| `alwaysShowTabs` | _Required_ | Boolean | `true` | When set to `true`, tabs are always displayed. When set to `false` and `showTabsInTitlebar` is set to `false`, tabs only appear after typing <kbd>Ctrl</kbd> + <kbd>T</kbd>. | | |||
| `copyOnSelect` | Optional | Boolean | `false` | When set to `true`, a selection is immediately copied to your clipboard upon creation. When set to `false`, the selection persists and awaits further action. | | |||
| `defaultProfile` | _Required_ | String | PowerShell guid | Sets the default profile. Opens by typing <kbd>Ctrl</kbd> + <kbd>T</kbd> or by clicking the '+' icon. The guid of the desired default profile is used as the value. | | |||
| `defaultSettings` | Optional | Object (Profile) | | Default settings to use with each profile. Settings in each profile in profiles will override these values. | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This description is clear as mud.
I think you mean "This set of settings is at the bottom of the layer cake, if defined, and those in the individual profiles will cover these up, if specified."
We're starting to need some sort of diagram to explain settings here. Perhaps a cake-based one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tagging @cinnamon-msft
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is beautifully straightforward and I love it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm blocking because we have three green checks but they're all conditional 👍
There's been quite the discussion on the team regarding this issue. There doesn't seem to be any sort of consensus on naming or how exactly this should work, so I'm closing this in favor of having a proper full spec review. Functionally, the code change is simple, as seen here. Naming, however, is a Hard problem. |
## Summary of the Pull Request _This is attempt 2 at this feature_. The original PR can be found at #3369. These are settings that apply to _every_ profile, before user customizations. If the user wants to add "default profile settings", they can make the `"profiles"` property an _object_, instead of a list, and add `"defaults"` key underneath that object. The users list of profiles should then be under the `list` property of the `profiles` object. ## References #2515, #2603, #3369, #3569 ## PR Checklist * [x] Closes #2325 * [x] I work here * [x] Tests added/passed * [x] schema, docs updated ## Detailed Description of the Pull Request / Additional comments ~~Discussion in #2325 itself serves as the "spec" for this task. I thought we'd need more discussion on the topic, but it ended up being pretty straightforward.~~ I should not have said that in the original PR. We've had a better spec review now that I think we're happier with. ## Validation Steps Performed _ran the tests_
Refer to the original issue: **Default Profile for Common Profile Settings** #2325 So this is my summary of everything we discussed regarding "default profile settings". The original PR was #3369, but we were _not_ in agreement on the UX, so this PR is for discussion about that. I put forth 4 proposals that were mentioned in the discussion. In the discussion that followed, we decided the 3rd proposal was the best. The doc reflects that choice.
Summary of the Pull Request
These are settings that apply to every profile, before user customizations. This can be placed in the globals under the "defaultSettings" key. It's a blob of profile settings that will be parsed just like a profile, and applied to profiles after default&dynamic profiles, but before user profiles.
"defaultSettings" is kinda a placeholder key ATM - @cinnamon-msft do we have concerns with this name? Does it make enough sense?
References
#2515, #2603
PR Checklist
Detailed Description of the Pull Request / Additional comments
Discussion in #2325 itself serves as the "spec" for this task. I thought we'd need more discussion on the topic, but it ended up being pretty straightforward.
Validation Steps Performed
ran the tests