Replies: 9 comments 1 reply
-
Helix is really great, but I'm failing here too and can only get ahead with workarounds. Overwriting the default configuration for "text" also seems to be the best solution to me. Another possibility could be to use "" for file-types, to apply to all files that don't have a suffix.
As a workaround for dot-files the following is possible:
EDIT: Missing quote added |
Beta Was this translation helpful? Give feedback.
-
Cool! Thanks, I'll be using that. (sidenote you're missing a doublequote in |
Beta Was this translation helpful? Give feedback.
-
At best I'm paraphrasing here and at worst I'm completely wrong, but from my understanding the plan is to let this use-case be handled by the plugin system instead of putting more work into supporting changing the defaults. |
Beta Was this translation helpful? Give feedback.
-
Oh boy I can't wait to install the always-use-4-space-indentation plugin, I love installing random software instead of having a single knob to turn! |
Beta Was this translation helpful? Give feedback.
-
You won't have to install anything. The configuration will simply be more flexible and still declarative. See #10441 and relatedly #8853 |
Beta Was this translation helpful? Give feedback.
-
Oh okay, I misunderstood, my bad. The discussions you linked seem quite promising! |
Beta Was this translation helpful? Give feedback.
-
Make sense 'cause one would expect that we don't do clever filetype checking, thus fallback to 'text' as type. |
Beta Was this translation helpful? Give feedback.
-
[[language]]
name = "bash"
file-types = [{glob=".*"},"sh"] Unfortunately when using this files like |
Beta Was this translation helpful? Give feedback.
-
The ability to more easily configure fallback falls under 5he config system refactor #8853 (just liek the issue you linked for a workaround). |
Beta Was this translation helpful? Give feedback.
-
Motivation
I often edit files which dont have a file type nor shebang (like ~/.gdbinit) and for me they most often use
#
for comments. Programming languages which use//
in general have a file extension so are detected. Maybe#
should be the default?My solution
I want to make it so that
#
is used for comments by default when a specific language isn't detected.The problem
This isn't intuitive at all, and reading the docs doesn't help much. It seems the current solution is doing this: #9165 (comment) which seems way to hacky and verbose to overwrite a simple configuration option.
I would expect:
or something similar to Just Work.
Beta Was this translation helpful? Give feedback.
All reactions