[BUG]: Files when custom config path is set #397

Closed
opened 2026-01-05 14:50:22 +01:00 by adam · 3 comments
Owner

Originally created by @IAmIlliest on GitHub (Jun 2, 2024).

Describe the bug
Very minor: When installing the quick start (komorebic quickstart) with a custom config path set via:
$Env:KOMOREBI_CONFIG_HOME = 'D:\XDG\config\komorebi', it reports:
Example ~/komorebi.json, ~/.config/whkdrc and latest ~/applications.yaml files downloaded

  1. whkdrc still lands in ~/.config/whkdrc, rather than being redirected to the dir set by $Env:KOMOREBI_CONFIG_HOME (the other two files land there are, as expected). I get there seperate apps, but just thinking about in the context of installing whkd with komorebi using a custom config dir.....
  2. applications.yaml lands in the correct path, but komorebi.json is still pointed at the default path, i.e.
    "app_specific_configuration_path": "$Env:USERPROFILE/applications.yaml"
    not the custom path:
    "app_specific_configuration_path": "D:\XDG\config\komorebi\applications.yaml"
  3. komorebic fetch-asc does it's thing correctly and reports the custom path correctly as defined by $Env:KOMOREBI_CONFIG_HOME

To Reproduce

  1. Run: komorebic quickstart
  2. Check config dirs and komorebi.json

Expected behavior

  1. Expected to see 'whkdrc' end up in either $Env:KOMOREBI_CONFIG_HOME/.config/whkdrc or just $Env:KOMOREBI_CONFIG_HOME/whkdrc
    I feel that would be neater than splitting them using the default ~/.config/ even when $Env:KOMOREBI_CONFIG_HOME has been set? (just so it all lands in one place)

  2. expected komorebi.json to default to automatically be configured to use:
    "app_specific_configuration_path": $Env:KOMOREBI_CONFIG_HOME/applications.yaml'
    rather than:
    "app_specific_configuration_path": "$Env:USERPROFILE/applications.yaml"
    (similarly, perhaps komorebic fetch-asc should report $Env:KOMOREBI_CONFIG_HOME/applications.yaml rather than the absolute path....or that might just confuse most users?)

Originally created by @IAmIlliest on GitHub (Jun 2, 2024). **Describe the bug** Very minor: When installing the quick start (komorebic quickstart) with a custom config path set via: `$Env:KOMOREBI_CONFIG_HOME = 'D:\XDG\config\komorebi'`, it reports: `Example ~/komorebi.json, ~/.config/whkdrc and latest ~/applications.yaml files downloaded` 1. whkdrc still lands in ~/.config/whkdrc, rather than being redirected to the dir set by $Env:KOMOREBI_CONFIG_HOME (the other two files land there are, as expected). I get there seperate apps, but just thinking about in the context of installing whkd with komorebi using a custom config dir..... 2. applications.yaml lands in the correct path, but komorebi.json is still pointed at the default path, i.e. `"app_specific_configuration_path": "$Env:USERPROFILE/applications.yaml"` not the custom path: `"app_specific_configuration_path": "D:\XDG\config\komorebi\applications.yaml"` 3. komorebic fetch-asc does it's thing correctly and reports the custom path correctly as defined by $Env:KOMOREBI_CONFIG_HOME **To Reproduce** 1. Run: komorebic quickstart 2. Check config dirs and komorebi.json **Expected behavior** 1. Expected to see 'whkdrc' end up in either `$Env:KOMOREBI_CONFIG_HOME/.config/whkdrc` or just `$Env:KOMOREBI_CONFIG_HOME/whkdrc` I feel that would be neater than splitting them using the default ~/.config/ even when $Env:KOMOREBI_CONFIG_HOME has been set? (just so it all lands in one place) 2. expected komorebi.json to default to automatically be configured to use: `"app_specific_configuration_path": $Env:KOMOREBI_CONFIG_HOME/applications.yaml`' rather than: "app_specific_configuration_path": "$Env:USERPROFILE/applications.yaml" (similarly, perhaps komorebic fetch-asc should report $Env:KOMOREBI_CONFIG_HOME/applications.yaml rather than the absolute path....or that might just confuse most users?)
adam added the bug label 2026-01-05 14:50:22 +01:00
adam closed this issue 2026-01-05 14:50:22 +01:00
Author
Owner

@LGUG2Z commented on GitHub (Jun 2, 2024):

There is separate WHKD_CONFIG_HOME for whkdrc which should be respected if it is set in the environment.

As for komorebi.json and the interaction with KOMOREBI_CONFIG_HOME, because having URL strings that point to GitHub would trigger various anti virus tools with false positives we started embedding the static file used in the docs into the komorebic binary.

For this I think we might be able to do a check to see if the env var is defined when the quickstart command is run and do a last minute string replacement 🤔

@LGUG2Z commented on GitHub (Jun 2, 2024): There is separate WHKD_CONFIG_HOME for whkdrc which should be respected if it is set in the environment. As for komorebi.json and the interaction with KOMOREBI_CONFIG_HOME, because having URL strings that point to GitHub would trigger various anti virus tools with false positives we started embedding the static file used in the docs into the komorebic binary. For this I think we might be able to do a check to see if the env var is defined when the quickstart command is run and do a last minute string replacement 🤔
Author
Owner

@IAmIlliest commented on GitHub (Jun 2, 2024):

Okay, opening a ticket for WHKD_CONFIG_HOME as it appears it isn't being respected? - https://github.com/LGUG2Z/whkd/issues/41

As for komorebi.json and the interaction with KOMOREBI_CONFIG_HOME, because having URL strings that point to GitHub would trigger various anti virus tools with false positives we started embedding the static file used in the docs into the komorebic binary.

Fair call on that, didn't think of the AV bit.

@IAmIlliest commented on GitHub (Jun 2, 2024): Okay, opening a ticket for WHKD_CONFIG_HOME as it appears it isn't being respected? - https://github.com/LGUG2Z/whkd/issues/41 > As for komorebi.json and the interaction with KOMOREBI_CONFIG_HOME, because having URL strings that point to GitHub would trigger various anti virus tools with false positives we started embedding the static file used in the docs into the komorebic binary. Fair call on that, didn't think of the AV bit.
Author
Owner

@LGUG2Z commented on GitHub (Jun 2, 2024):

Make some updates to the path resolution for the config command

  • If KOMOREBI_CONFIG_HOME is set, the Env:USERPROFILE string will be replaced with Env:KOMOREBI_CONFIG_HOME
  • If WHKD_CONFIG_HOME is set, the sample whkdrc file will be created there
@LGUG2Z commented on GitHub (Jun 2, 2024): Make some updates to the path resolution for the config command * If `KOMOREBI_CONFIG_HOME` is set, the `Env:USERPROFILE` string will be replaced with `Env:KOMOREBI_CONFIG_HOME` * If `WHKD_CONFIG_HOME` is set, the sample `whkdrc` file will be created there
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/komorebi#397