Replies: 1 comment 6 replies
-
|
Your mental model is correct: hk evaluates the global and project Pkl files independently, then merges them internally. You do not need to With the two configs shown, the One nuance: when both configs define the same hook, hk merges the step maps, but it does not deeply merge all hook-level properties. The project hook owns properties such as The sporadic hk --version
hk check --all --plan
hk fix --all --planThe two plans should make it immediately apparent whether this is config merging, file selection, or a particular builtin behaving differently in check mode. This reply was generated by Codex. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm struggling with the PKL configuration resolution to set up a global "everyone has this ~/.config/hk/config.pkl" that has the hooks we want to have on everything all the time. And then adding a per-repo hk.pkl that adds more to it.
I don't think I need to do
amends ~/.config/hk/config.pklbecause that doesn't actually work, no shell expansion in the amends. And the documentation seems to mention that the ordered loading of things happens and merges them.https://hk.jdx.dev/configuration.html#hkrc Yes, hkrc is deprecated, and the "global user config" uses the mentioned config.pkl.
I have a
~/.config/hk/config.pkl:And then I want to have a repo config that adds more to it:
I'll get random sporatic errors where
hk fixwill work buthk checkdoes not work, there's gotta be something that I'm not getting in how the configuration is loaded and merged...Would that merge in ways I expect so that all the linters are run? Or what's the right way to establish this? Or can this even happen and I'm thinking about it the wrong way?
Beta Was this translation helpful? Give feedback.
All reactions