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

add a CLI flag for specifying config file location #2666

Merged
merged 1 commit into from
Aug 4, 2022

Conversation

the-mikedavis
Copy link
Member

Closes #1216

I don't think there shouldn't be follow-up flags for the theme/runtime/etc dirs: #2135 should cover those cases.

I want this mostly to make triage easier - trying out one-off keymaps - and to some extent as an alternative to #1814 (say I try features ahead of time, I'll want to alias hx='hx -c path/to/config/with/extra/config.toml' so cargo run doesn't reject my config when trying other PRs). In the Nix world this should also make it easier to use helix with something like home-manager and not keep config in ~/.config/helix.

@the-mikedavis
Copy link
Member Author

I'm not sure a once_cell is the right tool for this. It was the most straightforward way to not change the helix_loader::config_file() API but maybe I'm missing something more idiomatic? Or this shouldn't be done without shared memory at all?

@the-mikedavis the-mikedavis marked this pull request as draft June 22, 2022 02:17
@the-mikedavis the-mikedavis marked this pull request as ready for review June 22, 2022 03:00
@archseer archseer merged commit 5d33dba into helix-editor:master Aug 4, 2022
@the-mikedavis the-mikedavis deleted the md-config-file-flag branch August 4, 2022 09:51
thomasskk pushed a commit to thomasskk/helix that referenced this pull request Sep 9, 2022
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.

Add ability to use a specified config/theme
2 participants