Merge branch 'nix-community:master' into todoman

This commit is contained in:
Kilian Mio 2024-06-01 20:35:36 +02:00 committed by GitHub
commit bc59405ada
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
44 changed files with 267 additions and 154 deletions

View file

@ -9,6 +9,7 @@ environment:
NIX_CONFIG: "experimental-features = nix-command flakes"
packages:
- nixos.cachix
- nixos.jq
tasks:
- setup: |
cachix use rycee
@ -26,7 +27,7 @@ tasks:
if [[ $gitBranch == master ]]; then
dirName="unstable"
else
dirName="$(cat .release)"
dirName="$(jq -r .release < release.json)"
fi
rsync --delete -r --info=stats \

View file

@ -14,7 +14,7 @@ jobs:
- uses: cachix/install-nix-action@v23
with:
nix_path: nixpkgs=channel:nixos-unstable
- uses: cachix/cachix-action@v13
- uses: cachix/cachix-action@v15
with:
name: nix-community
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'

View file

@ -28,7 +28,7 @@ Releases
Home Manager is developed against `nixpkgs-unstable` branch, which often causes
it to contain tweaks for changes/packages not yet released in stable [NixOS][].
To avoid breaking users' configurations, Home Manager is released in branches
corresponding to NixOS releases (e.g. `release-23.11`). These branches get
corresponding to NixOS releases (e.g. `release-24.05`). These branches get
fixes, but usually not new modules. If you need a module to be backported, then
feel free to open an issue.
@ -49,7 +49,7 @@ dconf store and cannot tell whether a configuration that it is about to be
overwritten was from a previous Home Manager generation or from manual
configuration.
Home Manager targets [NixOS][] unstable and NixOS version 23.11 (the current
Home Manager targets [NixOS][] unstable and NixOS version 24.05 (the current
stable version), it may or may not work on other Linux distributions and NixOS
versions.

View file

@ -15,10 +15,10 @@ $ nix-channel --add https://github.com/nix-community/home-manager/archive/master
$ nix-channel --update
```
and if you follow a Nixpkgs version 23.11 channel, you can run
and if you follow a Nixpkgs version 24.05 channel, you can run
``` shell
$ nix-channel --add https://github.com/nix-community/home-manager/archive/release-23.11.tar.gz home-manager
$ nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.05.tar.gz home-manager
$ nix-channel --update
```
@ -45,7 +45,7 @@ home-manager.users.eve = { pkgs, ... }: {
# The state version is required and should stay at the version you
# originally installed.
home.stateVersion = "23.11";
home.stateVersion = "24.05";
};
```

View file

@ -17,10 +17,10 @@ $ sudo nix-channel --add https://github.com/nix-community/home-manager/archive/m
$ sudo nix-channel --update
```
and if you follow a Nixpkgs version 23.11 channel, you can run
and if you follow a Nixpkgs version 24.05 channel, you can run
``` shell
$ sudo nix-channel --add https://github.com/nix-community/home-manager/archive/release-23.11.tar.gz home-manager
$ sudo nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.05.tar.gz home-manager
$ sudo nix-channel --update
```
@ -44,7 +44,7 @@ home-manager.users.eve = { pkgs, ... }: {
# The state version is required and should stay at the version you
# originally installed.
home.stateVersion = "23.11";
home.stateVersion = "24.05";
};
```

View file

@ -19,10 +19,10 @@
$ nix-channel --update
```
and if you follow a Nixpkgs version 23.11 channel you can run
and if you follow a Nixpkgs version 24.05 channel you can run
``` shell
$ nix-channel --add https://github.com/nix-community/home-manager/archive/release-23.11.tar.gz home-manager
$ nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.05.tar.gz home-manager
$ nix-channel --update
```

View file

@ -11,10 +11,10 @@ then to generate and activate a basic configuration run the command
$ nix run home-manager/master -- init --switch
```
For Nixpkgs or NixOS version 23.11 run
For Nixpkgs or NixOS version 24.05 run
``` shell
$ nix run home-manager/release-23.11 -- init --switch
$ nix run home-manager/release-24.05 -- init --switch
```
This will generate a `flake.nix` and a `home.nix` file in
@ -30,7 +30,7 @@ $ # Edit files in ~/.config/home-manager
$ nix run home-manager/$branch -- init --switch
```
Where `$branch` is one of `master` or `release-23.11`.
Where `$branch` is one of `master` or `release-24.05`.
After the initial activation has completed successfully then building
and activating your flake-based configuration is as simple as

View file

@ -20,7 +20,7 @@ A fresh install of Home Manager will generate a minimal
# You can update Home Manager without changing this value. See
# the Home Manager release notes for a list of state version
# changes in each release.
home.stateVersion = "23.11";
home.stateVersion = "24.05";
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
@ -65,7 +65,7 @@ follows:
# You can update Home Manager without changing this value. See
# the Home Manager release notes for a list of state version
# changes in each release.
home.stateVersion = "23.11";
home.stateVersion = "24.05";
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;

View file

@ -4,6 +4,7 @@ This section lists the release notes for stable versions of Home Manager
and the current unstable version.
```{=include=} chapters
rl-2411.md
rl-2405.md
rl-2311.md
rl-2305.md

View file

@ -1,7 +1,6 @@
# Release 24.05 {#sec-release-24.05}
This is the current unstable branch and the information in this section
is therefore not final.
The 24.05 release branch became stable in May, 2024.
## Highlights {#sec-release-24.05-highlights}
@ -89,4 +88,4 @@ The state version in this release includes the changes below. These
changes are only active if the `home.stateVersion` option is set to
\"24.05\" or later.
- Nothing, yet.
- There was no state version change in this release.

View file

@ -0,0 +1,18 @@
# Release 24.11 {#sec-release-24.11}
This is the current unstable branch and the information in this section
is therefore not final.
## Highlights {#sec-release-24.11-highlights}
This release has the following notable changes:
- No changes.
## State Version Changes {#sec-release-24.11-state-version-changes}
The state version in this release includes the changes below. These
changes are only active if the `home.stateVersion` option is set to
\"24.11\" or later.
- No changes.

View file

@ -2,11 +2,11 @@
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1715266358,
"narHash": "sha256-doPgfj+7FFe9rfzWo1siAV2mVCasW+Bh8I1cToAXEE4=",
"lastModified": 1716509168,
"narHash": "sha256-4zSIhSRRIoEBwjbPm3YiGtbd8HDWzFxJjw5DYSDy1n8=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "f1010e0469db743d14519a1efd37e23f8513d714",
"rev": "bfb7a882678e518398ce9a31a881538679f6f092",
"type": "github"
},
"original": {

View file

@ -198,9 +198,9 @@ function setFlakeAttribute() {
;;
*)
local name="$USER"
# Check both long and short hostnames; long first to preserve
# Check FQDN, long, and short hostnames; long first to preserve
# pre-existing behaviour in case both happen to be defined.
for n in "$USER@$(hostname)" "$USER@$(hostname -s)"; do
for n in "$USER@$(hostname -f)" "$USER@$(hostname)" "$USER@$(hostname -s)"; do
if [[ "$(nix eval "$flake#homeConfigurations" --apply "x: x ? \"$n\"")" == "true" ]]; then
name="$n"
if [[ -v VERBOSE ]]; then
@ -359,7 +359,7 @@ $xdgVars
# You should not change this value, even if you update Home Manager. If you do
# want to update the value, then make sure to first check the Home Manager
# release notes.
home.stateVersion = "23.11"; # Please read the comment before changing.
home.stateVersion = "24.05"; # Please read the comment before changing.
# The home.packages option allows you to install Nix packages into your
# environment.
@ -857,7 +857,7 @@ function doUninstall() {
uninstall = true;
home.username = "$USER";
home.homeDirectory = "$HOME";
home.stateVersion = "23.11";
home.stateVersion = "24.05";
}
EOF
# shellcheck disable=2064
@ -1044,7 +1044,7 @@ while [[ $# -gt 0 ]]; do
export VERBOSE=1
;;
--version)
echo 24.05-pre
echo 24.11-pre
exit 0
;;
*)

View file

@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2024-04-17 23:19+0200\n"
"PO-Revision-Date: 2024-02-16 22:01+0000\n"
"Last-Translator: Robert Helgesson <robert@rycee.net>\n"
"PO-Revision-Date: 2024-05-25 11:09+0000\n"
"Last-Translator: DeeKahy <Lennart.Diego.Kahn@gmail.com>\n"
"Language-Team: Danish <https://hosted.weblate.org/projects/home-manager/cli/"
"da/>\n"
"Language: da\n"
@ -17,12 +17,12 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.4\n"
"X-Generator: Weblate 5.6-dev\n"
#. translators: For example: "home-manager: missing argument for --cores"
#: home-manager/home-manager:16
msgid "%s: missing argument for %s"
msgstr ""
msgstr "%s: manglende argument for %s"
#: home-manager/home-manager:64
msgid "No configuration file found at %s"
@ -36,8 +36,8 @@ msgid ""
"Keeping your Home Manager %s in %s is deprecated,\n"
"please move it to %s"
msgstr ""
"At have din Home Manager %s i %s er forældet,\n"
"flyt den venligst til %s"
"Det er forældet at holde Home Manager %s i %s,\n"
"ryk den venligst til %s"
#: home-manager/home-manager:92
msgid "No configuration file found. Please create one at %s"
@ -45,7 +45,7 @@ msgstr "Ingen konfigurationsfiler fundet. Venligst lav en ved %s"
#: home-manager/home-manager:107
msgid "Home Manager not found at %s."
msgstr "Home Manager kan ikke findes under %s."
msgstr "Home Manager blev ikke fundet ved %s."
#. translators: This message will be seen by very few users that likely are familiar with English. So feel free to leave this untranslated.
#: home-manager/home-manager:115
@ -53,8 +53,8 @@ msgid ""
"The fallback Home Manager path %s has been deprecated and a file/directory "
"was found there."
msgstr ""
"Fallback-stien til Home Manager %s er blevet forældet, og en fil/mappe blev "
"fundet der."
"Det er forældet at bruge fallback Home Manager path %s og der blev fundet en "
"fil/mappe der."
#. translators: This message will be seen by very few users that likely are familiar with English. So feel free to leave this untranslated.
#: home-manager/home-manager:118
@ -120,7 +120,7 @@ msgstr "Kør '%s --help' for brugsvejledning"
#: home-manager/home-manager:327 home-manager/home-manager:431
msgid "The file %s already exists, leaving it unchanged..."
msgstr "Filen %s findes allerede, lader den være uændret..."
msgstr "Filen %s eksisterer allerede, efterlader den uændret…"
#: home-manager/home-manager:329 home-manager/home-manager:433
msgid "Creating %s..."
@ -189,7 +189,7 @@ msgstr "Ubekændt \"news.display\" indstilling \"%s\"."
#: home-manager/home-manager:594
#, sh-format
msgid "Please set the $EDITOR or $VISUAL environment variable"
msgstr ""
msgstr "Indstil venligst miljøvariablen $EDITOR eller $VISUAL"
#: home-manager/home-manager:612
msgid "Cannot run build in read-only directory"

View file

@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2024-04-17 23:19+0200\n"
"PO-Revision-Date: 2024-03-04 18:50+0000\n"
"Last-Translator: Robert Helgesson <robert@rycee.net>\n"
"PO-Revision-Date: 2024-05-21 18:02+0000\n"
"Last-Translator: halbGefressen <chzi@pm.me>\n"
"Language-Team: German <https://hosted.weblate.org/projects/home-manager/cli/"
"de/>\n"
"Language: de\n"
@ -17,12 +17,12 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.5-dev\n"
"X-Generator: Weblate 5.6-dev\n"
#. translators: For example: "home-manager: missing argument for --cores"
#: home-manager/home-manager:16
msgid "%s: missing argument for %s"
msgstr ""
msgstr "%s: Fehlendes Argument für %s"
#: home-manager/home-manager:64
msgid "No configuration file found at %s"

View file

@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2024-04-17 23:19+0200\n"
"PO-Revision-Date: 2024-04-29 18:07+0000\n"
"Last-Translator: Kento Okamoto <kentokamoto@protonmail.com>\n"
"PO-Revision-Date: 2024-05-25 11:09+0000\n"
"Last-Translator: TANIGUCHI Kohei <a.d.xvii.kal.mai@gmail.com>\n"
"Language-Team: Japanese <https://hosted.weblate.org/projects/home-manager/"
"cli/ja/>\n"
"Language: ja\n"
@ -17,7 +17,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Weblate 5.5.2\n"
"X-Generator: Weblate 5.6-dev\n"
#. translators: For example: "home-manager: missing argument for --cores"
#: home-manager/home-manager:16
@ -45,14 +45,15 @@ msgstr "設定ファイルがありません。ファイルを %s に作って
#: home-manager/home-manager:107
msgid "Home Manager not found at %s."
msgstr ""
msgstr "%s にHome Managerが見つかりません。"
#. translators: This message will be seen by very few users that likely are familiar with English. So feel free to leave this untranslated.
#: home-manager/home-manager:115
msgid ""
"The fallback Home Manager path %s has been deprecated and a file/directory "
"was found there."
msgstr ""
msgstr "フォールバックの Home Manager のパス %s "
"は非推奨ですが、そこにファイルまたはディレクトリがあります。"
#. translators: This message will be seen by very few users that likely are familiar with English. So feel free to leave this untranslated.
#: home-manager/home-manager:118
@ -75,6 +76,24 @@ msgid ""
"\n"
" $ rm -r \"%s\""
msgstr ""
"この警告が表示されないようにするには、以下のどれかを行ってください。\n"
"\n"
"1. Home Manager にそのパスを使うよう伝えます。例えば\n"
"\n"
" { programs.home-manager.path = \"%s\"; }\n"
"\n"
" を設定に追加します。\n"
"\n"
" もし Home Manager を直接インポートしているのであれば、 Home Manager "
"パッケージを呼び出すときに `path` パラメーターを使って\n"
"\n"
" pkgs.callPackage /path/to/home-manager-package { path = \"%s\"; }\n"
"\n"
" のようにできます。\n"
"\n"
"2. 非推奨のパスにあるものを削除します。\n"
"\n"
" $ rm -r \"%s\""
#: home-manager/home-manager:146
msgid "Sanity checking Nix"
@ -168,7 +187,7 @@ msgstr "\"news.display\"に\"%s\"という設定は存在しません。"
#: home-manager/home-manager:594
#, sh-format
msgid "Please set the $EDITOR or $VISUAL environment variable"
msgstr ""
msgstr "環境変数 $EDITOR または $VISUAL を設定してください"
#: home-manager/home-manager:612
msgid "Cannot run build in read-only directory"

View file

@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2024-04-17 23:19+0200\n"
"PO-Revision-Date: 2024-03-19 04:01+0000\n"
"Last-Translator: honnip <me@honnip.page>\n"
"PO-Revision-Date: 2024-05-30 06:09+0000\n"
"Last-Translator: lentil32 <lentil32@icloud.com>\n"
"Language-Team: Korean <https://hosted.weblate.org/projects/home-manager/cli/"
"ko/>\n"
"Language: ko\n"
@ -17,12 +17,12 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Weblate 5.5-dev\n"
"X-Generator: Weblate 5.6-dev\n"
#. translators: For example: "home-manager: missing argument for --cores"
#: home-manager/home-manager:16
msgid "%s: missing argument for %s"
msgstr ""
msgstr "%s: %s에 대한 인자 누락"
#: home-manager/home-manager:64
msgid "No configuration file found at %s"

View file

@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2024-04-17 23:19+0200\n"
"PO-Revision-Date: 2024-03-03 06:24+0000\n"
"Last-Translator: immwind <i@immwind.com>\n"
"PO-Revision-Date: 2024-05-13 10:00+0000\n"
"Last-Translator: Zexin Yuan <yuan.zx@outlook.com>\n"
"Language-Team: Chinese (Simplified) <https://hosted.weblate.org/projects/"
"home-manager/cli/zh_Hans/>\n"
"Language: zh_Hans\n"
@ -17,12 +17,12 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Weblate 5.5-dev\n"
"X-Generator: Weblate 5.5.5-dev\n"
#. translators: For example: "home-manager: missing argument for --cores"
#: home-manager/home-manager:16
msgid "%s: missing argument for %s"
msgstr ""
msgstr "%s缺少参数 %s"
#: home-manager/home-manager:64
msgid "No configuration file found at %s"

View file

@ -21,7 +21,7 @@ in {
config = mkIf config.uninstall {
home.packages = lib.mkForce [ ];
home.file = lib.mkForce { };
home.stateVersion = lib.mkForce "23.11";
home.stateVersion = lib.mkForce "24.05";
home.enableNixpkgsReleaseCheck = lib.mkForce false;
manual.manpages.enable = lib.mkForce false;
news.display = lib.mkForce "silent";

View file

@ -67,8 +67,8 @@ in {
};
historyControl = mkOption {
type =
types.listOf (types.enum [ "erasedups" "ignoredups" "ignorespace" ]);
type = types.listOf
(types.enum [ "erasedups" "ignoredups" "ignorespace" "ignoreboth" ]);
default = [ ];
description = "Controlling how commands are saved on the history list.";
};

View file

@ -73,7 +73,7 @@ with lib;
args = escapeShellArgs (optional cfg.icons "--icons"
++ optional cfg.git "--git" ++ cfg.extraOptions);
optionsAlias = { eza = "eza ${args}"; };
optionsAlias = optionalAttrs (args != "") { eza = "eza ${args}"; };
aliases = builtins.mapAttrs (_name: value: lib.mkDefault value) {
ls = "eza";

View file

@ -38,7 +38,7 @@ with lib; {
args = escapeShellArgs (optional cfg.hidden "--hidden" ++ cfg.extraOptions);
optionsAlias = { fd = "fd ${args}"; };
optionsAlias = optionalAttrs (args != "") { fd = "fd ${args}"; };
in mkIf cfg.enable {
home.packages = [ cfg.package ];

View file

@ -168,6 +168,8 @@ in {
options.programs.khal = {
enable = mkEnableOption "khal, a CLI calendar application";
package = mkPackageOption pkgs "khal" { };
locale = mkOption {
type = lib.types.submodule { options = localeOptions; };
description = ''
@ -197,7 +199,7 @@ in {
};
config = mkIf cfg.enable {
home.packages = [ pkgs.khal ];
home.packages = [ cfg.package ];
xdg.configFile."khal/config".text = concatStringsSep "\n" ([ "[calendars]" ]
++ mapAttrsToList genCalendarStr khalAccounts ++ [

View file

@ -28,13 +28,15 @@ in {
defaultText = literalExpression "{ }";
example = literalExpression ''
{
assume_yes = true;
disable = [
"flutter"
"node"
];
set_title = false;
cleanup = true;
misc = {
assume_yes = true;
disable = [
"flutter"
"node"
];
set_title = false;
cleanup = true;
};
commands = {
"Run garbage collection on Nix store" = "nix-collect-garbage";
};

View file

@ -11,7 +11,7 @@ let
local tmp="$(mktemp -t "yazi-cwd.XXXXX")"
yazi "$@" --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
cd -- "$cwd"
builtin cd -- "$cwd"
fi
rm -f -- "$tmp"
}
@ -22,7 +22,7 @@ let
set tmp (mktemp -t "yazi-cwd.XXXXX")
yazi $argv --cwd-file="$tmp"
if set cwd (cat -- "$tmp"); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
cd -- "$cwd"
builtin cd -- "$cwd"
end
rm -f -- "$tmp"
end
@ -40,17 +40,12 @@ let
}
'';
in {
meta.maintainers = [ maintainers.xyenon ];
meta.maintainers = with maintainers; [ xyenon ];
options.programs.yazi = {
enable = mkEnableOption "yazi";
package = mkOption {
type = types.package;
default = pkgs.yazi;
defaultText = literalExpression "pkgs.yazi";
description = "Yazi package to install.";
};
package = mkPackageOption pkgs "yazi" { };
enableBashIntegration = mkEnableOption "Bash integration";
@ -135,6 +130,48 @@ in {
for the full list of options
'';
};
initLua = mkOption {
type = with types; nullOr path;
default = null;
description = ''
The init.lua for Yazi itself.
'';
example = literalExpression "./init.lua";
};
plugins = mkOption {
type = with types; attrsOf (oneOf [ path package ]);
default = { };
description = ''
Lua plugins.
See https://yazi-rs.github.io/docs/plugins/overview/ for documentation.
'';
example = literalExpression ''
{
foo = ./foo;
bar = pkgs.bar;
}
'';
};
flavors = mkOption {
type = with types; attrsOf (oneOf [ path package ]);
default = { };
description = ''
Pre-made themes.
See https://yazi-rs.github.io/docs/flavors/overview/ for documentation.
'';
example = literalExpression ''
{
foo = ./foo;
bar = pkgs.bar;
}
'';
};
};
config = mkIf cfg.enable {
@ -160,6 +197,11 @@ in {
"yazi/theme.toml" = mkIf (cfg.theme != { }) {
source = tomlFormat.generate "yazi-theme" cfg.theme;
};
};
"yazi/init.lua" = mkIf (cfg.initLua != null) { source = cfg.initLua; };
} // (mapAttrs'
(name: value: nameValuePair "yazi/plugins/${name}" { source = value; })
cfg.plugins) // (mapAttrs'
(name: value: nameValuePair "yazi/flavors/${name}" { source = value; })
cfg.flavors);
};
}

View file

@ -48,9 +48,8 @@ let
hexStringToBase32 = let
mod = a: b: a - a / b * b;
pow2 = elemAt [ 1 2 4 8 16 32 64 128 256 ];
splitChars = s: init (tail (splitString "" s));
base32Alphabet = splitChars "ybndrfg8ejkmcpqxot1uwisza345h769";
base32Alphabet = stringToCharacters "ybndrfg8ejkmcpqxot1uwisza345h769";
hexToIntTable = listToAttrs (genList (x: {
name = toLower (toHexString x);
value = x;
@ -76,7 +75,7 @@ let
buf = buf';
bufBits = bufBits';
};
in hexString: (foldl' go initState (splitChars hexString)).ret;
in hexString: (foldl' go initState (stringToCharacters hexString)).ret;
in {
meta.maintainers = [ maintainers.rycee ];

View file

@ -209,24 +209,26 @@ in {
Attribute set of profiles.
'';
example = literalExpression ''
undocked = {
outputs = [
{
criteria = "eDP-1";
}
];
};
docked = {
outputs = [
{
criteria = "eDP-1";
}
{
criteria = "Some Company ASDF 4242";
transform = "90";
}
];
};
{
undocked = {
outputs = [
{
criteria = "eDP-1";
}
];
};
docked = {
outputs = [
{
criteria = "eDP-1";
}
{
criteria = "Some Company ASDF 4242";
transform = "90";
}
];
};
}
'';
};
@ -247,28 +249,30 @@ in {
See kanshi(5) for informations.
'';
example = literalExpression ''
{ include = "path/to/included/files"; }
{ output.criteria = "eDP-1";
output.scale = 2;
}
{ profile.name = "undocked";
profile.outputs = [
{
criteria = "eDP-1";
}
];
}
{ profile.name = "docked";
profile.outputs = [
{
criteria = "eDP-1";
}
{
criteria = "Some Company ASDF 4242";
transform = "90";
}
];
}
[
{ include = "path/to/included/files"; }
{ output.criteria = "eDP-1";
output.scale = 2;
}
{ profile.name = "undocked";
profile.outputs = [
{
criteria = "eDP-1";
}
];
}
{ profile.name = "docked";
profile.outputs = [
{
criteria = "eDP-1";
}
{
criteria = "Some Company ASDF 4242";
transform = "90";
}
];
}
]
'';
};

View file

@ -48,7 +48,12 @@ in {
Service = {
Environment = "PATH=${config.home.profileDirectory}/bin";
ExecStart = "${cfg.package}/libexec/kdeconnectd";
ExecStart =
if strings.versionAtLeast (versions.majorMinor cfg.package.version)
"24.05" then
"${cfg.package}/bin/kdeconnectd"
else
"${cfg.package}/libexec/kdeconnectd";
Restart = "on-abort";
};
};

View file

@ -24,7 +24,7 @@ in {
Configuration for listenbrainz-mpd written to
{file}`$XDG_CONFIG_HOME/listenbrainz-mpd/config.toml`.
'';
example = { submission.tokenFile = "/run/secrets/listenbrainz-mpd"; };
example = { submission.token_file = "/run/secrets/listenbrainz-mpd"; };
};
};

View file

@ -236,8 +236,9 @@ in {
}) + lib.optionalString (cfg.extraConfig != "") cfg.extraConfig;
onChange = lib.mkIf (cfg.package != null) ''
( # Execute in subshell so we don't poision environment with vars
if [[ -d "/tmp/hypr" ]]; then
(
XDG_RUNTIME_DIR=''${XDG_RUNTIME_DIR:-/run/user/$(id -u)}
if [[ -d "/tmp/hypr" || -d "$XDG_RUNTIME_DIR/hypr" ]]; then
for i in $(${cfg.finalPackage}/bin/hyprctl instances -j | jq ".[].instance" -r); do
${cfg.finalPackage}/bin/hyprctl -i "$i" reload config-only
done

View file

@ -1,4 +1,4 @@
{
"release": "24.05",
"release": "24.11",
"isReleaseBranch": false
}

View file

@ -15,7 +15,7 @@
};
home-manager.users.alice = { ... }: {
home.stateVersion = "23.11";
home.stateVersion = "24.05";
home.file.test.text = "testfile";
# Enable a light-weight systemd service.
services.pueue.enable = true;

View file

@ -13,7 +13,7 @@
# You should not change this value, even if you update Home Manager. If you do
# want to update the value, then make sure to first check the Home Manager
# release notes.
home.stateVersion = "23.11"; # Please read the comment before changing.
home.stateVersion = "24.05"; # Please read the comment before changing.
# The home.packages option allows you to install Nix packages into your
# environment.

View file

@ -3,7 +3,7 @@
{
home.username = "alice";
home.homeDirectory = "/home/alice";
home.stateVersion = "23.11";
home.stateVersion = "24.05";
home.packages = [ pkgs.hello ];
home.file.test.text = "test";
home.sessionVariables.EDITOR = "emacs";

View file

@ -1,14 +1,20 @@
{ pkgs, ... }:
{
nixpkgs.overlays = [
(self: super: {
mpvScript = pkgs.runCommandLocal "mpvScript" { scriptName = "something"; }
(final: prev: {
mpvScript = prev.runCommandLocal "mpvScript" { scriptName = "something"; }
"mkdir $out";
mpv-unwrapped = super.mpv-unwrapped.overrideAttrs {
builder = pkgs.writeShellScript "dummy" ''
PATH=${pkgs.coreutils}/bin
mpv-unwrapped = let
lua = prev.emptyDirectory.overrideAttrs {
luaversion = "0";
passthru.withPackages = pkgsFn: prev.emptyDirectory;
};
mpv-unwrapped' = prev.mpv-unwrapped.override { inherit lua; };
in mpv-unwrapped'.overrideAttrs {
buildInputs = [ ];
nativeBuildInputs = [ ];
builder = prev.writeShellScript "dummy" ''
PATH=${final.coreutils}/bin
mkdir -p $dev $doc $man $out/bin $out/Applications/mpv.app/Contents/MacOS
touch $out/bin/{mpv,umpv} \
$out/Applications/mpv.app/Contents/MacOS/{mpv,mpv-bundle}
@ -16,11 +22,6 @@
$out/Applications/mpv.app/Contents/MacOS/{mpv,mpv-bundle}
'';
};
lua = pkgs.emptyDirectory.overrideAttrs {
luaversion = "0";
withPackages = ps: pkgs.emptyDirectory;
};
})
];

View file

@ -1,8 +1,9 @@
[commands]
"Purge unused APT packages" = "sudo apt autoremove"
[misc]
cleanup = true
disable = ["sdkman", "flutter", "node", "nix", "home_manager"]
remote_topgrade_path = "bin/topgrade"
remote_topgrades = ["backup", "ci"]
set_title = false
[commands]
"Purge unused APT packages" = "sudo apt autoremove"

View file

@ -6,17 +6,21 @@
settings = lib.mkMerge [
{
disable = [ "sdkman" "flutter" "node" "nix" "home_manager" ];
misc = {
disable = [ "sdkman" "flutter" "node" "nix" "home_manager" ];
remote_topgrades = [ "backup" "ci" ];
remote_topgrades = [ "backup" "ci" ];
remote_topgrade_path = "bin/topgrade";
remote_topgrade_path = "bin/topgrade";
};
}
{
set_title = false;
cleanup = true;
misc = {
set_title = false;
cleanup = true;
};
commands = { "Purge unused APT packages" = "sudo apt autoremove"; };
}
];

View file

@ -6,7 +6,7 @@ let
local tmp="$(mktemp -t "yazi-cwd.XXXXX")"
yazi "$@" --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
cd -- "$cwd"
builtin cd -- "$cwd"
fi
rm -f -- "$tmp"
}

View file

@ -6,7 +6,7 @@ let
set tmp (mktemp -t "yazi-cwd.XXXXX")
yazi $argv --cwd-file="$tmp"
if set cwd (cat -- "$tmp"); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
cd -- "$cwd"
builtin cd -- "$cwd"
end
rm -f -- "$tmp"
end

View file

@ -0,0 +1 @@
-- This is a flavor.

View file

@ -0,0 +1,3 @@
require("zoxide"):setup {
update_db = true,
}

View file

@ -0,0 +1 @@
-- This is a plugin.

View file

@ -69,6 +69,9 @@
];
};
};
initLua = ./init.lua;
plugins = { "test.yazi" = ./plugin; };
flavors = { "test.yazi" = ./flavor; };
};
test.stubs.yazi = { };
@ -80,5 +83,11 @@
${./settings-expected.toml}
assertFileContent home-files/.config/yazi/theme.toml \
${./theme-expected.toml}
assertFileContent home-files/.config/yazi/init.lua \
${./init.lua}
assertFileContent home-files/.config/yazi/plugins/test.yazi/init.lua \
${./plugin/init.lua}
assertFileContent home-files/.config/yazi/flavors/test.yazi/init.lua \
${./flavor/init.lua}
'';
}

View file

@ -6,7 +6,7 @@ let
local tmp="$(mktemp -t "yazi-cwd.XXXXX")"
yazi "$@" --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
cd -- "$cwd"
builtin cd -- "$cwd"
fi
rm -f -- "$tmp"
}