mirror of
https://github.com/nix-community/home-manager.git
synced 2025-11-08 19:46:05 +01:00
jujutsu: store configuration in $XDG_CONFIG_HOME for all platforms (#6994)
Following https://github.com/jj-vcs/jj/pull/6300, Jujutsu has deprecated support for configuration files in `~/Library/Application Support` for darwin. The XDG-standard configuration location can be used instead, for all platforms.
This commit is contained in:
parent
f2b5bf55aa
commit
e9bd9568db
3 changed files with 37 additions and 8 deletions
|
|
@ -9,9 +9,14 @@ let
|
|||
|
||||
cfg = config.programs.jujutsu;
|
||||
tomlFormat = pkgs.formats.toml { };
|
||||
packageVersion = lib.getVersion cfg.package;
|
||||
|
||||
configDir = if pkgs.stdenv.isDarwin then "Library/Application Support" else config.xdg.configHome;
|
||||
|
||||
# jj v0.29+ deprecated support for "~/Library/Application Support" on Darwin.
|
||||
configDir =
|
||||
if pkgs.stdenv.isDarwin && !(lib.versionAtLeast packageVersion "0.29.0") then
|
||||
"Library/Application Support"
|
||||
else
|
||||
config.xdg.configHome;
|
||||
in
|
||||
{
|
||||
meta.maintainers = [ lib.maintainers.shikanime ];
|
||||
|
|
|
|||
|
|
@ -1,7 +1,19 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
configDir = if pkgs.stdenv.isDarwin then "Library/Application Support" else ".config";
|
||||
cfg = config.programs.jujutsu;
|
||||
packageVersion = lib.getVersion cfg.package;
|
||||
|
||||
# jj v0.29+ deprecated support for "~/Library/Application Support" on Darwin.
|
||||
configDir =
|
||||
if pkgs.stdenv.isDarwin && !(lib.versionAtLeast packageVersion "0.29.0") then
|
||||
"Library/Application Support"
|
||||
else
|
||||
".config";
|
||||
in
|
||||
{
|
||||
programs.jujutsu.enable = true;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,19 @@
|
|||
{ pkgs, config, ... }:
|
||||
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
configDir = if pkgs.stdenv.isDarwin then "Library/Application Support" else ".config";
|
||||
cfg = config.programs.jujutsu;
|
||||
packageVersion = lib.getVersion cfg.package;
|
||||
|
||||
# jj v0.29+ deprecated support for "~/Library/Application Support" on Darwin.
|
||||
configDir =
|
||||
if pkgs.stdenv.isDarwin && !(lib.versionAtLeast packageVersion "0.29.0") then
|
||||
"Library/Application Support"
|
||||
else
|
||||
".config";
|
||||
in
|
||||
{
|
||||
programs.jujutsu = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue