This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-09-09
Channels
- # announcements (1)
- # aws-lambda (3)
- # babashka (6)
- # beginners (91)
- # bristol-clojurians (5)
- # calva (25)
- # chlorine-clover (8)
- # cider (6)
- # clj-kondo (13)
- # cljdoc (10)
- # cljsrn (1)
- # clojure (80)
- # clojure-berlin (6)
- # clojure-europe (29)
- # clojure-nl (4)
- # clojure-spec (18)
- # clojure-uk (51)
- # clojurescript (41)
- # conjure (55)
- # cursive (3)
- # datomic (58)
- # emacs (9)
- # events (1)
- # figwheel-main (2)
- # fulcro (29)
- # graphql (12)
- # helix (4)
- # jobs (4)
- # klipse (8)
- # london-clojurians (1)
- # malli (5)
- # off-topic (13)
- # portal (9)
- # re-frame (30)
- # shadow-cljs (44)
- # spacemacs (7)
- # specter (3)
- # sql (11)
- # tools-deps (71)
- # windows (1)
- # xtdb (10)
Any Windows users here?
If you specify config for a command line tool (like clj-kondo), where would you expect this on Windows?
Clj-kondo expects it to be in C:\Users\foobar\.config\clj-kondo
, in the next version.
But someone commented here that Windows has a specific API for this:
https://github.com/borkdude/clj-kondo/issues/992#issuecomment-689446189
Personally I'd rather look in .config\clj-kondo
then some weird AppData folder nested somewhere deeply with GUID-named dirs.
I would say 'idiomatic' Windows CLI would be either %USERPROFILE%\.config\clj-kondo
(matches git, scoop)`%USERPROFILE%\.clj-kondo\config` (matches AWS CLI, dotnet core cli tools) or possibly something like %LOCALAPPDATA%\clj-kondo
or in the case of that doc FOLDERID_LocalAppData
or FOLDERID_Profile
would be the base directory I'd start looking in if I wanted to find an applications config folder
I have a preference for %USERPROFILE%\.config\clj-kondo
since that also matches linux and macOS
I would probably build a list of candidate paths and walk through them in search for the config. Some people may prefer %APPDATA%/clj-kondo/config
$env:APPDATA
C:\Users\borkdude\AppData\Roaming
You can control that with XDG_CONFIG_HOME
set to APPDATA
if you want that.Exactly the same as scoop does: https://github.com/lukesampson/scoop/blob/master/lib/core.ps1#L967-L968
Some machines have different local and roaming profile, but I cannot tell what are the consequences of that.
well, not really. clj-kondo will not scan a list, it will check the default location unless you have overriden it with XDG_CONFIG_HOME. If people use roaming profiles, they should probably use that
if you're locating the base folder via APPDATA environment variable roaming/local profile should 'just work' , LOCALAPPDATA would not sync between machines if user had a roaming profile
So if I understand correctly people who want to use clj-kondo would be advised to set environment variable XDG_CONFIG_HOME properly based on their system?
clj-kondo will look in $XDG_CONFIG_HOME/clj-kondo
if the env var is set, else in $HOME/.config/clj-kondo
.
Same on all OSes.
@kardan This guide just came out today: https://docs.microsoft.com/en-us/windows/wsl/tutorials/wsl-containers