Skip to content
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

feat(config): generate default template when config file is not found #3460

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

pluiedev
Copy link
Contributor

Closes #3203

@qwerasd205
Copy link
Collaborator

Notably, this PR automatically initializes the file on the first attempted load, rather than as a part of open_config (which is handled by open in ./src/config/edit.zig). I'm not sure how I feel about this.

@qwerasd205
Copy link
Collaborator

qwerasd205 commented Dec 27, 2024

As for the contents of the template- there are some changes to my suggested template that are definitely improvements, but some of the new wording is a little sloppy, the text jumps around between moods in a strange way, extraneous commentary is included which will reduce the chance of a user properly reading it (users could not care less about the philosophical basis of the configuration file, they just want to change their font and color scheme), and not leading with the docs link front and center is definitely worse.

@mitchellh
Copy link
Contributor

Notably, this PR automatically initializes the file on the first attempted load, rather than as a part of open_config (which is handled by open in ./src/config/edit.zig). I'm not sure how I feel about this.

I agree, I don't think we should be doing this in the load portion.

@pluiedev
Copy link
Contributor Author

pluiedev commented Dec 28, 2024

Notably, this PR automatically initializes the file on the first attempted load, rather than as a part of open_config (which is handled by open in ./src/config/edit.zig). I'm not sure how I feel about this.

I feel like I prefer this over only generating when open_config is run, since another common point of feedback is that some people didn't even know that you can open the config by pressing Ctrl/Cmd-,.

Plus, when they follow the docs and try to find the config file at ~/.config/ghostty/config (or its macOS equivalent) only to find that it doesn't exist, they get quite confused for one reason or another (some people mistake it for a directory, some people ask "wait, where's the ghostty directory in ~/.config?", etc.) Therefore I'd argue that only generating the file upon open_config only addresses half the problem. Always creating the template file when one couldn't be found would largely alleviate the volume of PEBKAC I've personally seen.

@pluiedev
Copy link
Contributor Author

pluiedev commented Dec 28, 2024

As for the contents of the template- there are some changes to my suggested template that are definitely improvements, but some of the new wording is a little sloppy, the text jumps around between moods in a strange way,

Proofreads & wording suggestions welcome, but an issue I had with the original version is that it feels too cold/robotic for an introductory document — I tried to rephrase it with a more welcoming tone but maybe now it seems a bit disjointed

extraneous commentary is included which will reduce the chance of a user properly reading it (users could not care less about the philosophical basis of the configuration file, they just want to change their font and color scheme),

Zero-config is a great selling point of Ghostty — heck, it's literally the first thing you see on the website's docs page. If people truly don't care about philosophical fluff then maybe we should deemphasize it there too.

I think it's a needed point of justification as to why we're not like, say, Kitty, where the default config is a full list of options. (Believe me, there are people who got confused by that as well, coming from Kitty)

and not leading with the docs link front and center is definitely worse.

That can definitely be moved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Default config file contents
3 participants