Compare commits

..
Author SHA1 Message Date
Benedikt RitterandGitHub 652fda4ca6 helix: remove outdated comment
The change to languages.toml referred to by the comment was released
with helix 23.10 which is the version currently on nixpkgs 23.11. See

- https://helix-editor.com/news/release-23-10-highlights/#multiple-language-servers
- https://github.com/NixOS/nixpkgs/blob/nixos-23.11/pkgs/applications/editors/helix/default.nix#L5
2024-02-03 18:30:11 +01:00
Robert Helgesson 10cd9c5311 docs, tests: revert to fetchTarball for nmd and nmt
Turns out pulling nmt and nmd from Nixpkgs causes an IFD, even when
the packages are fixed-output derivations.

Thus, since Sourcehut is up and well, we can revert to simply fetching
nmd and nmt directly.

See discussion in <https://github.com/nix-community/home-manager/pull/4884>.

(cherry picked from commit d6185e83d8)
2024-01-19 11:19:02 +01:00
Robert Helgesson 85c3b600f6 flake.lock: Update 2024-01-17 08:36:04 +01:00
Robert Helgesson 25f822abd3 flake.lock: Update 2024-01-17 08:30:43 +01:00
Robert Helgesson 924d91e1e4 docs: use nmd from Nixpkgs
(cherry picked from commit 846200eb57)
2024-01-15 00:02:37 +01:00
Robert Helgesson 2f9728fb7e tests: use nmt from Nixpkgs
(cherry picked from commit 8ae3bfe2bf)
2024-01-15 00:02:32 +01:00
Robert Helgesson 5f0ab0eedc docs: use alternative source of nmd
(cherry picked from commit 93e804e7f8)
2024-01-11 14:47:55 +01:00
Guillaume GirolandRobert Helgesson 7e398b3d76 lorri: unbreak due to too tight sandboxing
lorri needs to be able to write to /run/user/uid for the socket, to its
own cache directory ~/.cache/lorri and to the directory for gc roots.

(cherry picked from commit f06edaf18b)
2024-01-01 10:00:19 +01:00
katelyn martinandRobert Helgesson d5824a76bc docs: fix typo in nix-flakes.md
(cherry picked from commit ebeeef94ab)
2023-12-23 22:36:26 +01:00
Richard DavisandRobert Helgesson 072662bd1b caffeine: remove ProtectHome service option
This option causes caffeine to be unable to start via the systemd
service.

(cherry picked from commit 093777ee4a)
2023-12-23 22:35:55 +01:00
Tobias H. PetersenandRobert Helgesson 0c2353d5d9 docs: fix broken home-manager options link
(cherry picked from commit 8f38f1a231)
2023-12-20 23:57:18 +01:00
Viktor KronvallandRobert Helgesson 1488651d02 docs: fix broken link text
(cherry picked from commit c22b41f006)
2023-12-17 13:04:38 +01:00
Viktor KronvallandRobert Helgesson b408085bcb docs: fix link texts in release notes
(cherry picked from commit 59c15ebe3d)
2023-12-17 13:04:27 +01:00
Viktor KronvallandRobert Helgesson 34ccacf798 docs: add considerate as maintainer
(cherry picked from commit 07754e935a)
2023-12-17 13:04:14 +01:00
Viktor KronvallandRobert Helgesson 478e1bd9bb docs: use .xhtml for appendices
(cherry picked from commit 6c82b1c9ce)
2023-12-17 13:04:03 +01:00
Viktor KronvallandRobert Helgesson 052d8a681f docs: add release-notes as appendix
The release notes used to be an appendix in the manual. After
converting to markdown that appendix got lost. This commit
reintroduces the release notes into the manual.

(cherry picked from commit 6fc71dc563)
2023-12-17 13:03:39 +01:00
Phil SimpsonandRobert Helgesson 241d2e6934 docs: fix nix-darwin module configuration example
The example is missing a `;` which causes this error when you attempt
a `darwin-rebuild switch`.

```
       error: syntax error, unexpected '=', expecting ';'

       at /Users/968713/.nixpkgs/darwin-configuration.nix:17:30:

           16|   }
           17|   home-manager.users.eve = { pkgs, ... }: {
             |                              ^
           18|     home.packages = [
```

(cherry picked from commit 0e7cd64674)
2023-12-17 13:00:56 +01:00
D3vil0p3randRobert Helgesson 8a2f655197 docs: fix broken links in README
(cherry picked from commit e6b7303bd1)
2023-12-17 13:00:40 +01:00
Robert Helgesson aa99c2f4e9 docs: migrate documentation
This resolves the long-standing deprecation warning by migrating the
documentation to using the nixos-render-docs tool. As part of this,
the documentation markup language is migrated to Markdown.

See #4712 for more. Note, this is a backport of PR #4673.
2023-12-15 22:47:29 +01:00
dependabot[bot]GitHubdependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
6761b8188b ci: bump cachix/cachix-action from 12 to 13
Bumps [cachix/cachix-action](https://github.com/cachix/cachix-action) from 12 to 13.
- [Release notes](https://github.com/cachix/cachix-action/releases)
- [Commits](https://github.com/cachix/cachix-action/compare/v12...v13)

---
updated-dependencies:
- dependency-name: cachix/cachix-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-12-10 09:08:29 +01:00
Robert HelgessonandViktor Kronvall 71d9bd6724 docs: use relative paths to static resources
Fixes #4753
2023-12-09 22:23:51 +09:00
Robert HelgessonandViktor Kronvall 890239846e docs: apply nixfmt 2023-12-09 22:23:46 +09:00
Viktor Kronvall 93e2536db2 docs: rename generated manual to index.xhtml
The `nixos-render-docs` tool outputs XHTML formatted content. In
order to convince browsers like `firefox` to treat the data as XHTML
the extension must be `.xhtml` and not `.html`.

Using the XHTML-formatted content as HTML is mainly an issue with
self-closing `<a />` tags.
2023-12-09 01:07:08 +09:00
Viktor Kronvall 0da5767319 docs: fix syntax highlighting
`document-highlighter` now outputs a `<code>` block inside the
pre-formatted `<pre>` tag. This changes the required CSS for
rendering code snippets. Moreover, this commit uses the highlightjs
as provided by the `document-highlighter` package instead of the
version packaged in `nmd`.
2023-12-09 01:07:08 +09:00
Viktor Kronvall ecc724dac9 docs: render DESCRIPTION and OPTIONS headings 2023-12-09 01:07:08 +09:00
Viktor Kronvall 9ebc8a51ed docs: replace console language with shell 2023-12-09 01:07:08 +09:00
Viktor Kronvall 0a10eae61d docs: update nmd version
This update fixes the custom CSS to make the `$` character
non-selectable in highlighted code blocks.
2023-12-09 01:07:08 +09:00
Viktor Kronvall a422807513 docs: extend home-configuration.nix header
The previous version had a longer header before the options,
including a DESCRIPTION section and an header for the OPTIONS.
2023-12-09 01:07:08 +09:00
Viktor Kronvall 7f725c12b1 docs: include 3rd-party part 2023-12-09 01:07:08 +09:00
Viktor Kronvall 5d63a01440 docs: this is the home-manager manual 2023-12-09 01:07:08 +09:00
Viktor Kronvall b16e97f9b2 docs: fix note blocks 2023-12-09 01:07:08 +09:00
Viktor Kronvall fc77ecf2ff docs: no justification in home-manager manpage
The `man home-configuration.nix` is configured to left
align the text similar to `man configuration.nix`. This
commit updates the `man home-manager` page to be consitent
with the two manpages mentioned above.
2023-12-09 01:07:08 +09:00
Viktor Kronvall cc48491bfc docs: use nixos-render-docs
This commit removes the `home-manager-render-docs` package in favor
of upstream `nixos-render-docs` where the manpage generator has been
updated to take a `--header` and a `--footer` flag specifying static
content around the content derived from the options.json file.
2023-12-09 01:07:00 +09:00
Viktor Kronvall 31c0c87ebf docs: update manual to refer to 23.11 2023-12-09 01:06:44 +09:00
Viktor Kronvall 7bd59cb10c docs: update paths to make manual tests pass 2023-12-09 01:06:44 +09:00
Viktor Kronvall 25fd5eb4ba docs: add htmlOpenTool to manual
This commit extracts the htmlOpenTool from `nmd` into a module
in the home-manager docs directory. This is done to provide feature
parity with the documentation generated using the docbook .xml files.
2023-12-09 01:06:44 +09:00
Viktor Kronvall 14f29065e1 docs: add home-manager manpage 2023-12-09 01:06:44 +09:00
Viktor Kronvall 69a96783b1 docs: render without deprecated optionsDocBook
The `optionsDocBook` function is deprecated in nixpkgs since
nixos-23.11. This commit updates the manual and manpages to
use commonmark formatted documentation instead of the deprecated
docbook format.
2023-12-09 01:06:44 +09:00
91 changed files with 219 additions and 2333 deletions
+1 -1
View File
@@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v23
with:
nix_path: nixpkgs=channel:nixos-unstable
nix_path: nixpkgs=channel:nixos-23.11
- uses: cachix/cachix-action@v13
with:
name: nix-community
+1
View File
@@ -0,0 +1 @@
23.11
+2 -3
View File
@@ -8,9 +8,8 @@
let
nmdSrc = fetchTarball {
url =
"https://git.sr.ht/~rycee/nmd/archive/f18defadcc25e69e95b04493ee02682005472255.tar.gz";
sha256 = "14fazjqbc6sfsxycwadfhcymi37xg5wmrlvg3jb8d4mpbcdwfwz4";
url = "https://git.sr.ht/~rycee/nmd/archive/v0.5.0.tar.gz";
sha256 = "0hnd86jd19zb5j3hmpwmdmdiasg65lgahqv7n8frl9p1vdqz6z67";
};
nmd = import nmdSrc {
+1 -1
View File
@@ -1,6 +1,6 @@
# Home Manager Manual {#home-manager-manual}
## Version 24.05 (unstable)
## Version 23.11
```{=include=} preface
-1
View File
@@ -4,7 +4,6 @@ This section lists the release notes for stable versions of Home Manager
and the current unstable version.
```{=include=} chapters
rl-2405.md
rl-2311.md
rl-2305.md
rl-2211.md
-19
View File
@@ -1,19 +0,0 @@
# Release 24.05 {#sec-release-24.05}
This is the current unstable branch and the information in this section
is therefore not final.
## Highlights {#sec-release-24.05-highlights}
This release has the following notable changes:
- The `.release` file in the Home Manager project root has been
removed. Please use the `release.json` file instead.
## State Version Changes {#sec-release-24.05-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.05\" or later.
- Nothing, yet.
Generated
+4 -4
View File
@@ -2,16 +2,16 @@
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1702312524,
"narHash": "sha256-gkZJRDBUCpTPBvQk25G0B7vfbpEYM5s5OZqghkjZsnE=",
"lastModified": 1705331948,
"narHash": "sha256-qjQXfvrAT1/RKDFAMdl8Hw3m4tLVvMCc8fMqzJv0pP4=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "a9bf124c46ef298113270b1f84a164865987a91c",
"rev": "b8dd8be3c790215716e7c12b247f45ca525867e2",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-unstable",
"ref": "nixos-23.11",
"repo": "nixpkgs",
"type": "github"
}
+2 -8
View File
@@ -1,7 +1,7 @@
{
description = "Home Manager for Nix";
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.11";
outputs = { self, nixpkgs, ... }:
{
@@ -106,18 +106,12 @@
packages = forAllSystems (system:
let
pkgs = nixpkgs.legacyPackages.${system};
lib = pkgs.lib;
releaseInfo = nixpkgs.lib.importJSON ./release.json;
docs = import ./docs {
inherit pkgs;
inherit (releaseInfo) release isReleaseBranch;
};
hmPkg = pkgs.callPackage ./home-manager { path = toString ./.; };
testPackages = let
tests = import ./tests { inherit pkgs; };
renameTestPkg = n: lib.nameValuePair "test-${n}";
in lib.mapAttrs' renameTestPkg tests.build;
in {
default = hmPkg;
home-manager = hmPkg;
@@ -125,7 +119,7 @@
docs-html = docs.manual.html;
docs-json = docs.options.json;
docs-manpages = docs.manPages;
} // testPackages);
});
defaultPackage = forAllSystems (system: self.packages.${system}.default);
});
+2 -8
View File
@@ -29,9 +29,7 @@ function removeByName() {
}
function setNixProfileCommands() {
if [[ -e $HOME/.nix-profile/manifest.json \
|| -e ${XDG_STATE_HOME:-$HOME/.local/state}/nix/profile/manifest.json ]] ; then
if [[ -e $HOME/.nix-profile/manifest.json ]] ; then
LIST_OUTPATH_CMD="nix profile list"
REMOVE_CMD="removeByName"
else
@@ -408,10 +406,6 @@ $xdgVars
#
# or
#
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
#
# or
#
# /etc/profiles/per-user/$USER/etc/profile.d/hm-session-vars.sh
#
home.sessionVariables = {
@@ -722,7 +716,7 @@ function doListPackages() {
local outPath
outPath="$($LIST_OUTPATH_CMD | grep -o '/.*home-manager-path$')"
if [[ -n "$outPath" ]] ; then
nix-store -q --references "$outPath" | sed 's/[^-]*-//' | sort --ignore-case
nix-store -q --references "$outPath" | sed 's/[^-]*-//'
else
_i 'No home-manager packages seem to be installed.' >&2
fi
+4 -26
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: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-10 15:58+0000\n"
"Last-Translator: Nara Díaz Viñolas <rdvdev2@gmail.com>\n"
"PO-Revision-Date: 2023-04-23 12:49+0000\n"
"Last-Translator: Leix b <abone9999@gmail.com>\n"
"Language-Team: Catalan <https://hosted.weblate.org/projects/home-manager/cli/"
"ca/>\n"
"Language: ca\n"
@@ -17,7 +17,7 @@ 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.3-dev\n"
"X-Generator: Weblate 4.18-dev\n"
#: home-manager/home-manager:81
msgid "No configuration file found at %s"
@@ -40,7 +40,7 @@ msgstr "No s'ha trobat cap fitxer de configuració. Si us plau, creeu un a %s"
#: home-manager/home-manager:124
msgid "Home Manager not found at %s."
msgstr "No s'ha trobat el Home Manager a %s."
msgstr ""
#. 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:132
@@ -48,8 +48,6 @@ msgid ""
"The fallback Home Manager path %s has been deprecated and a file/directory "
"was found there."
msgstr ""
"La ruta alternativa del Home Manager ha quedat obsoleta i s'ha trobat un "
"fitxer/directori allí."
#. 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:135
@@ -72,26 +70,6 @@ msgid ""
"\n"
" $ rm -r \"%s\""
msgstr ""
"Per a eliminar aquesta advertència, dugueu a terme una de les següents "
"opcions.\n"
"\n"
"1. Indiqueu explícitament al Home Manager que utilitzi la ruta, per exemple "
"afegint\n"
"\n"
" { programs.home-manager.path = \"%s\"; }\n"
"\n"
" a la vostra configuració.\n"
"\n"
" Si importeu el Home Manager directament, podeu utilitzar el paràmetre "
"`path`\n"
"\n"
" pkgs.callPackage /ruta/al/paquet-del-home-manager { path = \"%s\"; }\n"
"\n"
" quan invoqueu el paquet del Home Manager.\n"
"\n"
"2. Elimineu la ruta obsoleta.\n"
"\n"
" $ rm -r \"%s\""
#: home-manager/home-manager:174
msgid "Could not find suitable profile directory, tried %s and %s"
+4 -4
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: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-08 12:04+0000\n"
"Last-Translator: David Houdek <sarejnovec@gmail.com>\n"
"PO-Revision-Date: 2023-09-09 13:54+0000\n"
"Last-Translator: Karel Kremel <charles@alembiq.net>\n"
"Language-Team: Czech <https://hosted.weblate.org/projects/home-manager/cli/"
"cs/>\n"
"Language: cs\n"
@@ -17,7 +17,7 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
"X-Generator: Weblate 5.3-dev\n"
"X-Generator: Weblate 5.0.1-dev\n"
#: home-manager/home-manager:81
msgid "No configuration file found at %s"
@@ -93,7 +93,7 @@ msgstr ""
#: home-manager/home-manager:174
msgid "Could not find suitable profile directory, tried %s and %s"
msgstr "Nebyl nalezen vhodný adresář profilu, byly zkoušeny %s a %s"
msgstr "Nebyl nalezen adresář profilu, byly zkoušeny %s a %s"
#. translators: Here "flake" is a noun that refers to the Nix Flakes feature.
#: home-manager/home-manager:229
+18 -42
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: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-02 23:06+0000\n"
"Last-Translator: Lorenzo Brzek <lorenzoservizi@proton.me>\n"
"PO-Revision-Date: 2023-11-12 11:01+0000\n"
"Last-Translator: Frankie McEyes <mceyes@protonmail.com>\n"
"Language-Team: Italian <https://hosted.weblate.org/projects/home-manager/cli/"
"it/>\n"
"Language: it\n"
@@ -17,7 +17,7 @@ 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.3-dev\n"
"X-Generator: Weblate 5.2-dev\n"
#: home-manager/home-manager:81
msgid "No configuration file found at %s"
@@ -31,16 +31,14 @@ msgid ""
"Keeping your Home Manager %s in %s is deprecated,\n"
"please move it to %s"
msgstr ""
"Mantere il tuo Home Manger su %s su %s è obsoleto,\n"
"si raccomanda di spostarlo su %s"
#: home-manager/home-manager:109
msgid "No configuration file found. Please create one at %s"
msgstr "Nessun file di configurazione trovato. Per favore creane uno in %s"
msgstr "Nessun file di configurazione trovato. Per favore crearne uno in %s"
#: home-manager/home-manager:124
msgid "Home Manager not found at %s."
msgstr "Home Manager non è stato trovato in %s."
msgstr ""
#. 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:132
@@ -48,8 +46,6 @@ msgid ""
"The fallback Home Manager path %s has been deprecated and a file/directory "
"was found there."
msgstr ""
"Il percorso di riserva di Home Manager %s è stato deprecato e un file/"
"directory è stato trovato lì."
#. 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:135
@@ -72,26 +68,6 @@ msgid ""
"\n"
" $ rm -r \"%s\""
msgstr ""
"Per rimuovere questo avvertimento, esegui queste istruzioni.\n"
"\n"
"1.Di esplicitamente a Home Manager di usare il percorso, per esempio "
"aggiungendo\n"
"\n"
"· · · · · { programs.home-manager.path = \"%s\"; }\n"
"\n"
"nella tua configurazione.\n"
"\n"
"· · · Se hai importato Home Manager direttamente, puoi usare il parametro "
"`path`\n"
"\n"
"· · · · · pkgs.callPackage /percorso/di/home-manager-package { path = \"%s\""
";}\n"
"\n"
"· · · quando chiami il pacchetto Home Manager\n"
"\n"
"2. Rimuovi il percorso obsoleto\n"
"\n"
"· · · · · $ rm -r \"%s\""
#: home-manager/home-manager:174
msgid "Could not find suitable profile directory, tried %s and %s"
@@ -110,15 +86,15 @@ msgstr "%s: opzione sconosciuta '%s'"
#: home-manager/home-manager:296 home-manager/home-manager:1035
msgid "Run '%s --help' for usage help"
msgstr "Esegui '%s --help' per le informazioni d'uso"
msgstr "Esegui '%s --help' per ottenere aiuto"
#: home-manager/home-manager:322 home-manager/home-manager:421
msgid "The file %s already exists, leaving it unchanged..."
msgstr "Il file %s esiste già, non verrà modificato..."
msgstr "Il file %s è già esistente, non verrà modificato..."
#: home-manager/home-manager:324 home-manager/home-manager:423
msgid "Creating %s..."
msgstr "Creando %s..."
msgstr ""
#: home-manager/home-manager:465
msgid "Creating initial Home Manager generation..."
@@ -136,7 +112,7 @@ msgid ""
msgstr ""
"Tutto fatto! Home-manager dovrebbe essere installato e puoi modificare\n"
"\n"
"· · · · %s\n"
"%s\n"
"\n"
"per configurare Home Manager. Esegui 'man home-configurazion.nix' per\n"
"consultare tutte le opzioni disponibili."
@@ -150,10 +126,10 @@ msgid ""
"\n"
"if the error seems to be the fault of Home Manager."
msgstr ""
"Oh oh, l'installazione non è andata a buon fine! Per favore aprire un ticket "
"Oh no, l'installazione non è andata a buon fine! Per favore aprire un ticket "
"issue a\n"
"\n"
"· · · · %s\n"
"%s\n"
"\n"
"se l'errore sembra essere causato da Home Manager."
@@ -170,10 +146,10 @@ msgid_plural ""
"There are %d unread and relevant news items.\n"
"Read them by running the command \"%s news\"."
msgstr[0] ""
"C'è %d novità rilevante non letta.\n"
"C'è %d novità di elementi non letta.\n"
"Leggila con il comando \"%s news\"."
msgstr[1] ""
"Ci sono %d novità rilevanti non lette.\n"
"Ci sono %d novità di elementi non letti\n"
"Leggile con il comando \"%s news\"."
#: home-manager/home-manager:576
@@ -183,7 +159,7 @@ msgstr "Opzione \"news.display\" sconosciuta \"%s\"."
#: home-manager/home-manager:583
#, sh-format
msgid "Please set the $EDITOR environment variable"
msgstr "Per favore impostare la variabile d'ambiente $EDITOR"
msgstr "Per favore impostare la variabile d'ambient $EDITOR"
#: home-manager/home-manager:598
msgid "Cannot run build in read-only directory"
@@ -207,7 +183,7 @@ msgstr "Nessuna generazione in scadenza"
#: home-manager/home-manager:710
msgid "No home-manager packages seem to be installed."
msgstr "Sembrerebbe che nessun pacchetto home-manager sia installato."
msgstr "Nessun pacchetto home-manager sembra essere installato."
#: home-manager/home-manager:792
msgid "Unknown argument %s"
@@ -227,7 +203,7 @@ msgstr "Vuoi davvero disinstallare Home Manager?"
#: home-manager/home-manager:829
msgid "Switching to empty Home Manager configuration..."
msgstr "Passaando ad una configurazione Home Manager vuota..."
msgstr "Cambio ad una configurazione Home Manager vuota..."
#: home-manager/home-manager:857
msgid "Yay!"
@@ -235,7 +211,7 @@ msgstr "Urrà!"
#: home-manager/home-manager:862
msgid "Home Manager is uninstalled but your home.nix is left untouched."
msgstr "Home Manager è disinstallato ma la tua home.nix non è stata toccata."
msgstr "Home Manager è disinstallato ma la tua home.Nix non è stata toccata."
#: home-manager/home-manager:1074
msgid "expire-generations expects one argument, got %d."
@@ -248,7 +224,7 @@ msgstr "Comando sconosciuto: %s"
#: home-manager/install.nix:18
msgid "This derivation is not buildable, please run it using nix-shell."
msgstr ""
"Questa derivazione non è compilabile, prova ad eseguirla usando nix-shell."
"Questa derivazione non è compilabile, prova ad eseguila usando nix-shell."
#~ msgid "Creating initial Home Manager configuration..."
#~ msgstr "Creando la configurazione iniziale di Home Manager..."
+4 -4
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: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-02 23:06+0000\n"
"Last-Translator: Zurga <jim.lemmers@gmail.com>\n"
"PO-Revision-Date: 2023-04-10 11:48+0000\n"
"Last-Translator: Pablo Bollansee <pablo.bollansee@gmail.com>\n"
"Language-Team: Dutch <https://hosted.weblate.org/projects/home-manager/cli/"
"nl/>\n"
"Language: nl\n"
@@ -17,7 +17,7 @@ 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.3-dev\n"
"X-Generator: Weblate 4.17-dev\n"
#: home-manager/home-manager:81
msgid "No configuration file found at %s"
@@ -73,7 +73,7 @@ msgstr ""
#: home-manager/home-manager:174
msgid "Could not find suitable profile directory, tried %s and %s"
msgstr "Kan geen geschikte map vinden voor het profiel, %s en %s geprobeerd"
msgstr ""
#. translators: Here "flake" is a noun that refers to the Nix Flakes feature.
#: home-manager/home-manager:229
+5 -25
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: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-11 16:06+0000\n"
"Last-Translator: Lucas Eduardo <lucas59356@gmail.com>\n"
"PO-Revision-Date: 2023-10-19 04:00+0000\n"
"Last-Translator: SrGesus <gabriel.fcf04@gmail.com>\n"
"Language-Team: Portuguese <https://hosted.weblate.org/projects/home-manager/"
"cli/pt/>\n"
"Language: pt\n"
@@ -17,7 +17,7 @@ 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.3-dev\n"
"X-Generator: Weblate 5.1\n"
#: home-manager/home-manager:81
msgid "No configuration file found at %s"
@@ -48,8 +48,6 @@ msgid ""
"The fallback Home Manager path %s has been deprecated and a file/directory "
"was found there."
msgstr ""
"O caminho alternativo do Home Manager %s foi depreciado e um arquivo/"
"diretório foi encontrado lá."
#. 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:135
@@ -72,24 +70,6 @@ msgid ""
"\n"
" $ rm -r \"%s\""
msgstr ""
"Para remover este aviso, faça o seguinte.\n"
"\n"
"1. Instrua o Home Manager para usar o caminho, por exemplo, adicionando\n"
"\n"
" { programs.home-manager.path = \"%s\"; }\n"
"\n"
" em sua configuração.\n"
"\n"
" Se você importa o Home Manager diretamente, você pode usar o parâmetro "
"`path`\n"
"\n"
" pkgs.callPackage /path/to/home-manager-package { path = \"%s\"; }\n"
"\n"
" quando chamar o pacote do Home Manager.\n"
"\n"
"2. Remova o caminho depreciado.\n"
"\n"
" $ rm -r \"%s\""
#: home-manager/home-manager:174
msgid "Could not find suitable profile directory, tried %s and %s"
@@ -113,11 +93,11 @@ msgstr "Execute '%s --help' para instruções de uso"
#: home-manager/home-manager:322 home-manager/home-manager:421
msgid "The file %s already exists, leaving it unchanged..."
msgstr "O arquivo %s já existe, deixando do jeito que está..."
msgstr ""
#: home-manager/home-manager:324 home-manager/home-manager:423
msgid "Creating %s..."
msgstr "Criando %s..."
msgstr ""
#: home-manager/home-manager:465
msgid "Creating initial Home Manager generation..."
+7 -29
View File
@@ -8,16 +8,16 @@ msgstr ""
"Project-Id-Version: Home Manager\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-11-30 15:04+0000\n"
"Last-Translator: Gabriel Fontes <hi@m7.rs>\n"
"Language-Team: Portuguese (Brazil) <https://hosted.weblate.org/projects/"
"home-manager/cli/pt_BR/>\n"
"PO-Revision-Date: 2023-08-11 19:50+0000\n"
"Last-Translator: Gabriel Grysuk <gabrielgrysuk@gmail.com>\n"
"Language-Team: Portuguese (Brazil) <https://hosted.weblate.org/projects/home-"
"manager/cli/pt_BR/>\n"
"Language: pt_BR\n"
"MIME-Version: 1.0\n"
"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.3-dev\n"
"X-Generator: Weblate 5.0-dev\n"
#: home-manager/home-manager:81
msgid "No configuration file found at %s"
@@ -48,8 +48,6 @@ msgid ""
"The fallback Home Manager path %s has been deprecated and a file/directory "
"was found there."
msgstr ""
"O caminho alternativo do Home Manager, %s, foi descontinuado, mas existe "
"algum arquivo/diretório nele."
#. 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:135
@@ -72,30 +70,10 @@ msgid ""
"\n"
" $ rm -r \"%s\""
msgstr ""
"Para remover esse aviso, faça um dos seguintes.\n"
"\n"
"1. Explicitamente diga para o Home Manager usar esse caminho, por exemplo, "
"adicionando\n"
"\n"
" { programs.home-manager.path = \"%s\"; }\n"
"\n"
" à sua configuração.\n"
"\n"
" Se você importa o Home Manager diretamente, você pode usar o parâmetro "
"`path`\n"
"\n"
" pkgs.callPackage /caminho/do/pacote-home-manager { path = \"%s\"; }\n"
"\n"
" ao chamar o pacote do Home Manager.\n"
"\n"
"2. Apague o caminho descontinuado.\n"
"\n"
" $ rm -r \"%s\""
#: home-manager/home-manager:174
msgid "Could not find suitable profile directory, tried %s and %s"
msgstr ""
"Não foi possível encontrar um diretório de perfil apropriado, tentei %s e %s"
#. translators: Here "flake" is a noun that refers to the Nix Flakes feature.
#: home-manager/home-manager:229
@@ -113,11 +91,11 @@ msgstr "Execute '%s --help' para instruções de uso"
#: home-manager/home-manager:322 home-manager/home-manager:421
msgid "The file %s already exists, leaving it unchanged..."
msgstr "O arquivo %s já existe, mantendo ele sem modificações..."
msgstr ""
#: home-manager/home-manager:324 home-manager/home-manager:423
msgid "Creating %s..."
msgstr "Criando %s..."
msgstr ""
#: home-manager/home-manager:465
msgid "Creating initial Home Manager generation..."
+8 -30
View File
@@ -8,17 +8,17 @@ msgstr ""
"Project-Id-Version: Home Manager\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-10 16:00+0000\n"
"Last-Translator: Blezz Rot <markus.jenya04@yandex.ru>\n"
"PO-Revision-Date: 2023-06-07 12:51+0000\n"
"Last-Translator: Nikolay Mokrinsky <me@mokrinsky.ru>\n"
"Language-Team: Russian <https://hosted.weblate.org/projects/home-manager/cli/"
"ru/>\n"
"Language: ru\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
"X-Generator: Weblate 5.3-dev\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
"X-Generator: Weblate 4.18-dev\n"
#: home-manager/home-manager:81
msgid "No configuration file found at %s"
@@ -32,8 +32,6 @@ msgid ""
"Keeping your Home Manager %s in %s is deprecated,\n"
"please move it to %s"
msgstr ""
"Файл %s вашего Home Manager находится в устаревшем месте %s\n"
"пожалуйста, переместите его в %s"
#: home-manager/home-manager:109
msgid "No configuration file found. Please create one at %s"
@@ -41,7 +39,7 @@ msgstr "Не найден файл конфигурации. Пожалуйст
#: home-manager/home-manager:124
msgid "Home Manager not found at %s."
msgstr "Home Manager не был найден в %s."
msgstr ""
#. 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:132
@@ -49,8 +47,6 @@ msgid ""
"The fallback Home Manager path %s has been deprecated and a file/directory "
"was found there."
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:135
@@ -73,24 +69,6 @@ msgid ""
"\n"
" $ rm -r \"%s\""
msgstr ""
"Чтобы убрать это предупреждение, совершите один из шагов, приведённых ниже.\n"
"\n"
"1. Явно заставьте Home Manager использовать путь, например добавив\n"
"\n"
" { programs.home-manager.path = \"%s\"; }\n"
"\n"
" в ваш файл конфигурации.\n"
"\n"
" Если вы импортируете Home Manager напрямую, то вы можете использовать "
"параметр `path`\n"
"\n"
" pkgs.callPackage /path/to/home-manager-package { path = \"%s\"; }\n"
"\n"
" когда вызываете пакет Home Manager\n"
"\n"
"2. Удалите устаревший путь.\n"
"\n"
" $ rm -r \"%s\""
#: home-manager/home-manager:174
msgid "Could not find suitable profile directory, tried %s and %s"
@@ -112,11 +90,11 @@ msgstr "Выполните '%s --help', чтобы получить справк
#: home-manager/home-manager:322 home-manager/home-manager:421
msgid "The file %s already exists, leaving it unchanged..."
msgstr "Файл %s уже существует и не будет изменен..."
msgstr ""
#: home-manager/home-manager:324 home-manager/home-manager:423
msgid "Creating %s..."
msgstr "Создание %s..."
msgstr ""
#: home-manager/home-manager:465
msgid "Creating initial Home Manager generation..."
+3 -3
View File
@@ -175,7 +175,7 @@ in
done automatically if the shell configuration is managed by Home
Manager. If not, then you must source the
${cfg.profileDirectory}/etc/profile.d/hm-session-vars.sh
~/.nix-profile/etc/profile.d/hm-session-vars.sh
file yourself.
'')
@@ -585,7 +585,7 @@ in
if config.submoduleSupport.externalPackageInstall
then
''
if [[ -e ${cfg.profileDirectory}/manifest.json ]] ; then
if [[ -e $HOME/.nix-profile/manifest.json ]] ; then
nix profile list \
| { grep 'home-manager-path$' || test $? = 1; } \
| cut -d ' ' -f 4 \
@@ -623,7 +623,7 @@ in
$DRY_RUN_CMD $oldNix profile install $1
}
if [[ -e ${cfg.profileDirectory}/manifest.json ]] ; then
if [[ -e $HOME/.nix-profile/manifest.json ]] ; then
INSTALL_CMD="nix profile install"
INSTALL_CMD_ACTUAL="nixReplaceProfile"
LIST_CMD="nix profile list"
+2 -12
View File
@@ -35,8 +35,6 @@ let
Package providing the theme. This package will be installed
to your profile. If `null` then the theme
is assumed to already be available in your profile.
For the theme to apply to GTK 4, this option is mandatory.
'';
};
@@ -235,15 +233,6 @@ in {
gtk-cursor-theme-size = cfg.cursorTheme.size;
};
gtk4Css =
lib.optionalString (cfg.theme != null && cfg.theme.package != null) ''
/**
* GTK 4 reads the theme configured by gtk-theme-name, but ignores it.
* It does however respect user CSS, so import the theme from here.
**/
@import url("file://${cfg.theme.package}/share/themes/${cfg.theme.name}/gtk-4.0/gtk.css");
'' + cfg4.extraCss;
dconfIni = optionalAttrs (cfg.font != null) {
font-name = let
fontSize =
@@ -288,7 +277,8 @@ in {
xdg.configFile."gtk-4.0/settings.ini".text =
toGtk3Ini { Settings = gtkIni // cfg4.extraConfig; };
xdg.configFile."gtk-4.0/gtk.css" = mkIf (gtk4Css != "") { text = gtk4Css; };
xdg.configFile."gtk-4.0/gtk.css" =
mkIf (cfg4.extraCss != "") { text = cfg4.extraCss; };
dconf.settings."org/gnome/desktop/interface" = dconfIni;
});
-49
View File
@@ -1309,55 +1309,6 @@ in
A new module is available: 'programs.ruff'.
'';
}
{
time = "2023-11-26T23:18:01+00:00";
condition = hostPlatform.isLinux;
message = ''
A new module is available: 'services.signaturepdf'.
'';
}
{
time = "2023-12-10T08:43:02+00:00";
condition = config.wayland.windowManager.hyprland.settings ? source;
message = ''
Entries in
wayland.windowManager.hyprland.settings.source
are now placed at the start of the configuration file. If you relied
on the previous placement of the 'source' entries, please set
wayland.windowManager.hyprland.sourceFirst = false
to keep the previous behaviour.
'';
}
{
time = "2023-12-19T22:57:52+00:00";
message = ''
A new module is available: 'programs.sapling'.
'';
}
{
time = "2023-12-20T11:41:10+00:00";
message = ''
A new module is available: 'programs.gradle'.
'';
}
{
time = "2023-12-23T08:45:52+00:00";
message = ''
Three new modules are available:
'virtualisation.containers',
'virtualisation.oci-containers',
'virtualisation.podman'.
'';
}
];
};
}
-1
View File
@@ -20,7 +20,6 @@ in {
"22.11"
"23.05"
"23.11"
"24.05"
];
description = ''
It is occasionally necessary for Home Manager to change
-6
View File
@@ -99,7 +99,6 @@ let
./programs/gnome-terminal.nix
./programs/go.nix
./programs/gpg.nix
./programs/gradle.nix
./programs/granted.nix
./programs/havoc.nix
./programs/helix.nix
@@ -193,7 +192,6 @@ let
./programs/rtx.nix
./programs/ruff.nix
./programs/sagemath.nix
./programs/sapling.nix
./programs/sbt.nix
./programs/scmpuff.nix
./programs/script-directory.nix
@@ -328,7 +326,6 @@ let
./services/safeeyes.nix
./services/screen-locker.nix
./services/sctd.nix
./services/signaturepdf.nix
./services/spotifyd.nix
./services/ssh-agent.nix
./services/stalonetray.nix
@@ -368,9 +365,6 @@ let
./systemd.nix
./targets/darwin
./targets/generic-linux.nix
./virtualisation/containers.nix
./virtualisation/oci-containers.nix
./virtualisation/podman/podman.nix
./xresources.nix
./xsession.nix
./misc/nix.nix
+5 -5
View File
@@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager Modules\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-10 15:58+0000\n"
"Last-Translator: Nara Díaz Viñolas <rdvdev2@gmail.com>\n"
"PO-Revision-Date: 2023-04-23 12:49+0000\n"
"Last-Translator: Leix b <abone9999@gmail.com>\n"
"Language-Team: Catalan <https://hosted.weblate.org/projects/home-manager/"
"modules/ca/>\n"
"Language: ca\n"
@@ -17,7 +17,7 @@ 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.3-dev\n"
"X-Generator: Weblate 4.18-dev\n"
#: modules/files.nix:234
msgid "Creating home file links in %s"
@@ -110,11 +110,11 @@ msgstr ""
#: modules/lib-bash/activation-init.sh:95
msgid "Error: USER is set to \"%s\" but we expect \"%s\""
msgstr "Error: USER està configurat a \"%s\", però s'esperava \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:104
msgid "Error: HOME is set to \"%s\" but we expect \"%s\""
msgstr "Error: HOME està configurat a \"%s\", però s'esperava \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:119
msgid "Starting Home Manager activation"
+19 -43
View File
@@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager Modules\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-08 12:04+0000\n"
"Last-Translator: David Houdek <sarejnovec@gmail.com>\n"
"PO-Revision-Date: 2023-09-08 12:55+0000\n"
"Last-Translator: Karel Kremel <charles@alembiq.net>\n"
"Language-Team: Czech <https://hosted.weblate.org/projects/home-manager/"
"modules/cs/>\n"
"Language: cs\n"
@@ -17,23 +17,23 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
"X-Generator: Weblate 5.3-dev\n"
"X-Generator: Weblate 5.0.1-dev\n"
#: modules/files.nix:234
msgid "Creating home file links in %s"
msgstr "Vytváření linků na domácí soubory v %s"
msgstr ""
#: modules/files.nix:247
msgid "Cleaning up orphan links from %s"
msgstr "Čištění osiřelých linků z %s"
msgstr ""
#: modules/files.nix:263
msgid "Creating profile generation %s"
msgstr "Vytvářím profil generace %s"
msgstr ""
#: modules/files.nix:280
msgid "No change so reusing latest profile generation %s"
msgstr "Žádná změna, takže bude použita profil poslední generace %s"
msgstr ""
#: modules/home-environment.nix:640
msgid ""
@@ -50,34 +50,22 @@ msgid ""
"\n"
"Then try activating your Home Manager configuration again."
msgstr ""
"Jejda, Nix se nepodařilo instalovat váš nový Home Manager profil!\n"
"\n"
"Možná je konflikt s balíčkem, který byl nainstalován pomocí\n"
"\"%s\"? Zkuste spustit\n"
"\n"
"\t%s\n"
"\n"
"a jestli existuje konfliktní balíček, můžete ho odstranit pomocí\n"
"\n"
"\t%s\n"
"\n"
"Poté zkuste znova aktivovat vaši Home Manager konfiguraci."
#: modules/home-environment.nix:673
msgid "Activating %s"
msgstr "Aktivuji %s"
msgstr ""
#: modules/lib-bash/activation-init.sh:22
msgid "Migrating profile from %s to %s"
msgstr "Migruji profil z %s do %s"
msgstr ""
#: modules/lib-bash/activation-init.sh:53
msgid "Could not find suitable profile directory, tried %s and %s"
msgstr "Nebyl nalezen vhodný adresář profilu, byly zkoušeny %s a %s"
msgstr "Nebyl nalezen adresář profilu, byly zkoušeny %s a %s"
#: modules/lib-bash/activation-init.sh:81
msgid "Sanity checking oldGenNum and oldGenPath"
msgstr "Kontrola správnosti oldGenNum a oldGenPath"
msgstr ""
#: modules/lib-bash/activation-init.sh:84
msgid ""
@@ -94,47 +82,35 @@ msgid ""
"\n"
"and trying home-manager switch again. Good luck!"
msgstr ""
"Poslední číslo a cesta generace jsou konfliktní! Ty\n"
"musí být oboje buď prázdné, nebo nastaveny, ale nyní jsou nastaveny na\n"
"\n"
"\t'%s' a '%s'\n"
"\n"
"Jestli vám nevadí ztráta předchozích generací profilu, potom\n"
"to nejjednodušší řešení bude nejspíš spustit\n"
"\n"
"\trm %s/home-manager*\n"
"\trm %s/current-home\n"
"\n"
"a zkusit přepínač homemanager znova. Hodně štěstí!"
#: modules/lib-bash/activation-init.sh:95
msgid "Error: USER is set to \"%s\" but we expect \"%s\""
msgstr "Chyba: USER je nastaven na \"%s\", ale očekáváme \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:104
msgid "Error: HOME is set to \"%s\" but we expect \"%s\""
msgstr "Chyba: HOME je nastaven na \"%s\", ale očekáváme \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:119
msgid "Starting Home Manager activation"
msgstr "Zapínám aktivaci Home Manager"
msgstr ""
#: modules/lib-bash/activation-init.sh:123
msgid "Sanity checking Nix"
msgstr "Kontrola správnosti Nix"
msgstr ""
#: modules/lib-bash/activation-init.sh:133
msgid "This is a dry run"
msgstr "Toto je zkušební běh"
msgstr ""
#: modules/lib-bash/activation-init.sh:137
msgid "This is a live run"
msgstr "Toto je běh na ostro"
msgstr ""
#: modules/lib-bash/activation-init.sh:143
msgid "Using Nix version: %s"
msgstr "Používám Nix verze: %s"
msgstr ""
#: modules/lib-bash/activation-init.sh:146
msgid "Activation variables:"
msgstr "Aktivační proměnné:"
msgstr ""
+9 -9
View File
@@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager Modules\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-02 23:06+0000\n"
"Last-Translator: Lorenzo Brzek <lorenzoservizi@proton.me>\n"
"PO-Revision-Date: 2023-11-12 11:01+0000\n"
"Last-Translator: Frankie McEyes <mceyes@protonmail.com>\n"
"Language-Team: Italian <https://hosted.weblate.org/projects/home-manager/"
"modules/it/>\n"
"Language: it\n"
@@ -17,7 +17,7 @@ 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.3-dev\n"
"X-Generator: Weblate 5.2-dev\n"
#: modules/files.nix:234
msgid "Creating home file links in %s"
@@ -51,19 +51,19 @@ msgid ""
"\n"
"Then try activating your Home Manager configuration again."
msgstr ""
"Ops, Nix non è riuscito ad installare il tuo nuovo profilo Home Manager!\n"
"Ops, Nix non è riuscito a installare il nuovo profilo di Home Manager!\n"
"\n"
"Potrebbe esserci un conflitto con un pacchetto che è stato installato "
"utilizzando\n"
"Forse c'è un conflitto con un pacchetto che è stato installato utilizzando "
"il file\n"
"\"%s\"? Provate ad eseguire\n"
"\n"
"· · · ·%s\n"
" %s\n"
"\n"
"e se ci fosse un pacchetto in conflitto, potete rimuoverlo con\n"
"\n"
"· · · · %s\n"
" %s\n"
"\n"
"Poi provate a riattivare la configurazione Home Manager."
"Quindi provare ad attivare nuovamente la configurazione di Home Manager."
#: modules/home-environment.nix:673
msgid "Activating %s"
+7 -7
View File
@@ -8,8 +8,8 @@ msgstr ""
"Project-Id-Version: Home Manager Modules\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-02 23:06+0000\n"
"Last-Translator: Zurga <jim.lemmers@gmail.com>\n"
"PO-Revision-Date: 2023-04-10 11:48+0000\n"
"Last-Translator: Pablo Bollansee <pablo.bollansee@gmail.com>\n"
"Language-Team: Dutch <https://hosted.weblate.org/projects/home-manager/"
"modules/nl/>\n"
"Language: nl\n"
@@ -17,7 +17,7 @@ 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.3-dev\n"
"X-Generator: Weblate 4.17-dev\n"
#: modules/files.nix:234
msgid "Creating home file links in %s"
@@ -71,11 +71,11 @@ msgstr "%s aan het activeren"
#: modules/lib-bash/activation-init.sh:22
msgid "Migrating profile from %s to %s"
msgstr "Profiel aan het migreren van %s naar %s"
msgstr ""
#: modules/lib-bash/activation-init.sh:53
msgid "Could not find suitable profile directory, tried %s and %s"
msgstr "Kan geen geschikte map vinden voor het profiel, %s en %s geprobeerd"
msgstr ""
#: modules/lib-bash/activation-init.sh:81
msgid "Sanity checking oldGenNum and oldGenPath"
@@ -111,11 +111,11 @@ msgstr ""
#: modules/lib-bash/activation-init.sh:95
msgid "Error: USER is set to \"%s\" but we expect \"%s\""
msgstr "Fout: USER heeft als waarde \"%s\" maar we verwachten \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:104
msgid "Error: HOME is set to \"%s\" but we expect \"%s\""
msgstr "Fout: HOME heeft als waarde \"%s\" maar we verwachten \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:119
msgid "Starting Home Manager activation"
+8 -9
View File
@@ -8,16 +8,16 @@ msgstr ""
"Project-Id-Version: Home Manager Modules\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-11-30 15:04+0000\n"
"Last-Translator: Gabriel Fontes <hi@m7.rs>\n"
"Language-Team: Portuguese (Brazil) <https://hosted.weblate.org/projects/"
"home-manager/modules/pt_BR/>\n"
"PO-Revision-Date: 2022-04-04 11:11+0000\n"
"Last-Translator: Alex Miranda <alexmirandamoraes@gmail.com>\n"
"Language-Team: Portuguese (Brazil) <https://hosted.weblate.org/projects/home-"
"manager/modules/pt_BR/>\n"
"Language: pt_BR\n"
"MIME-Version: 1.0\n"
"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.3-dev\n"
"X-Generator: Weblate 4.12-dev\n"
#: modules/files.nix:234
msgid "Creating home file links in %s"
@@ -69,12 +69,11 @@ msgstr "Ativando %s"
#: modules/lib-bash/activation-init.sh:22
msgid "Migrating profile from %s to %s"
msgstr "Migrando perfil de %s para %s"
msgstr ""
#: modules/lib-bash/activation-init.sh:53
msgid "Could not find suitable profile directory, tried %s and %s"
msgstr ""
"Não foi possível encontrar um diretório de perfil apropriado, tentei %s e %s"
#: modules/lib-bash/activation-init.sh:81
msgid "Sanity checking oldGenNum and oldGenPath"
@@ -110,11 +109,11 @@ msgstr ""
#: modules/lib-bash/activation-init.sh:95
msgid "Error: USER is set to \"%s\" but we expect \"%s\""
msgstr "Erro: USER está definido como \"%s\" mas o esperado é \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:104
msgid "Error: HOME is set to \"%s\" but we expect \"%s\""
msgstr "Erro: HOME está definido como \"%s\" mas o esperado é \"%s\""
msgstr ""
#: modules/lib-bash/activation-init.sh:119
msgid "Starting Home Manager activation"
+13 -14
View File
@@ -8,17 +8,17 @@ msgstr ""
"Project-Id-Version: Home Manager Modules\n"
"Report-Msgid-Bugs-To: https://github.com/nix-community/home-manager/issues\n"
"POT-Creation-Date: 2023-09-13 23:46+0200\n"
"PO-Revision-Date: 2023-12-11 16:06+0000\n"
"Last-Translator: Blezz Rot <markus.jenya04@yandex.ru>\n"
"PO-Revision-Date: 2023-06-07 12:51+0000\n"
"Last-Translator: Nikolay Mokrinsky <me@mokrinsky.ru>\n"
"Language-Team: Russian <https://hosted.weblate.org/projects/home-manager/"
"modules/ru/>\n"
"Language: ru\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && "
"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
"X-Generator: Weblate 5.3-dev\n"
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
"X-Generator: Weblate 4.18-dev\n"
#: modules/files.nix:234
msgid "Creating home file links in %s"
@@ -78,7 +78,7 @@ msgstr "Не найдена подходящая директория профи
#: modules/lib-bash/activation-init.sh:81
msgid "Sanity checking oldGenNum and oldGenPath"
msgstr "Проверка oldGenNum и oldGenPath"
msgstr "Сравниваю oldGenNum и oldGenPath на всякий"
#: modules/lib-bash/activation-init.sh:84
msgid ""
@@ -95,19 +95,18 @@ msgid ""
"\n"
"and trying home-manager switch again. Good luck!"
msgstr ""
"Обнаружен конфликт между номером и расположением предыдущего поколения!\n"
"Обе переменные должны иметь значения либо быть пустыми, но следующие "
"значения:\n"
"Номер и путь прошлого поколения конфликтуют! Они должны быть\n"
"одинаково пустыми или заполненными, но сейчас имеют значения\n"
"\n"
" '%s' and '%s'\n"
" '%s' и '%s'\n"
"\n"
"Если вы не возражаете потерять предыдущие поколения профиля,\n"
"наиболее простым решением будет выполнение\n"
"Если вы не против потерять предыдущие профили, тогда,\n"
"вероятно, простейшим решением будет запустить\n"
"\n"
" rm %s/home-manager*\n"
" rm %s/current-home\n"
"\n"
повторный запуск 'home-manager switch'. Удачи!"
выполнить home-manager switch ещё раз. Удачи!"
#: modules/lib-bash/activation-init.sh:95
msgid "Error: USER is set to \"%s\" but we expect \"%s\""
@@ -123,7 +122,7 @@ msgstr "Начинаю активацию Home Manager"
#: modules/lib-bash/activation-init.sh:123
msgid "Sanity checking Nix"
msgstr "Проверка работоспособности Nix"
msgstr "Проверяю Nix на всякий случай"
#: modules/lib-bash/activation-init.sh:133
msgid "This is a dry run"
+1 -9
View File
@@ -145,11 +145,6 @@ in {
"maildir://${config.accounts.email.maildirBasePath}/${cfg.maildir.path}";
};
maildirpp = cfg: {
source =
"maildirpp://${config.accounts.email.maildirBasePath}/${cfg.maildir.path}/Inbox";
};
imap = { userName, imap, passwordCommand, aerc, ... }@cfg:
let
loginMethod' =
@@ -212,10 +207,7 @@ in {
// (optAttr "aliases" account.aliases);
sourceCfg = account:
if account.mbsync.enable && account.mbsync.flatten == null
&& account.mbsync.subFolders == "Maildir++" then
mkConfig.maildirpp account
else if account.mbsync.enable || account.offlineimap.enable then
if account.mbsync.enable || account.offlineimap.enable then
mkConfig.maildir account
else if account.imap != null then
mkConfig.imap account
+5 -10
View File
@@ -57,16 +57,11 @@ in {
config = lib.mkIf cfg.enable {
home.packages = [ cfg.package ];
home.file."${config.home.homeDirectory}/.aws/config" =
lib.mkIf (cfg.settings != { }) {
source =
iniFormat.generate "aws-config-${config.home.username}" cfg.settings;
};
home.file."${config.home.homeDirectory}/.aws/config".source =
iniFormat.generate "aws-config-${config.home.username}" cfg.settings;
home.file."${config.home.homeDirectory}/.aws/credentials" =
lib.mkIf (cfg.credentials != { }) {
source = iniFormat.generate "aws-credentials-${config.home.username}"
cfg.credentials;
};
home.file."${config.home.homeDirectory}/.aws/credentials".source =
iniFormat.generate "aws-credentials-${config.home.username}"
cfg.credentials;
};
}
-11
View File
@@ -175,14 +175,6 @@ in {
'';
};
enableNushellIntegration = mkOption {
default = true;
type = types.bool;
description = ''
Whether to enable Nushell integration.
'';
};
package = mkOption {
type = types.package;
default = pkgs.broot;
@@ -234,8 +226,5 @@ in {
programs.zsh.initExtra = mkIf cfg.enableZshIntegration (shellInit "zsh");
programs.fish.shellInit = mkIf cfg.enableFishIntegration (shellInit "fish");
programs.nushell.extraConfig =
mkIf cfg.enableNushellIntegration (shellInit "nushell");
};
}
+13 -32
View File
@@ -114,53 +114,34 @@ in {
# Using mkAfter to make it more likely to appear after other
# manipulations of the prompt.
mkAfter ''
eval "$(${getExe cfg.package} hook bash)"
eval "$(${cfg.package}/bin/direnv hook bash)"
'');
programs.zsh.initExtra = mkIf cfg.enableZshIntegration ''
eval "$(${getExe cfg.package} hook zsh)"
eval "$(${cfg.package}/bin/direnv hook zsh)"
'';
programs.fish.interactiveShellInit = mkIf cfg.enableFishIntegration (
# Using mkAfter to make it more likely to appear after other
# manipulations of the prompt.
mkAfter ''
${getExe cfg.package} hook fish | source
${cfg.package}/bin/direnv hook fish | source
'');
programs.nushell.extraConfig = mkIf cfg.enableNushellIntegration (
# Using mkAfter to make it more likely to appear after other
# manipulations of the prompt.
mkAfter ''
$env.config = ($env.config? | default {})
$env.config.hooks = ($env.config.hooks? | default {})
$env.config.hooks.pre_prompt = (
$env.config.hooks.pre_prompt?
| default []
| append {||
let direnv = (${getExe cfg.package} export json
| from json
| default {})
if ($direnv | is-empty) {
return
}
$direnv
| items {|key, value|
{
key: $key
value: (do (
$env.ENV_CONVERSIONS?
| default {}
| get -i $key
| get -i from_string
| default {|x| $x}
) $value)
}
}
| transpose -ird
| load-env
}
)
$env.config = ($env | default {} config).config
$env.config = ($env.config | default {} hooks)
$env.config = ($env.config | update hooks ($env.config.hooks | default [] pre_prompt))
$env.config = ($env.config | update hooks.pre_prompt ($env.config.hooks.pre_prompt | append {
code: "
let direnv = (${cfg.package}/bin/direnv export json | from json)
let direnv = if not ($direnv | is-empty) { $direnv } else { {} }
$direnv | load-env
"
}))
'');
};
}
+5 -10
View File
@@ -97,14 +97,13 @@ let
directoryToHTML = indentLevel: directory: ''
${indent indentLevel}<DT>${
if directory.toolbar then
''
<H3 ADD_DATE="1" LAST_MODIFIED="1" PERSONAL_TOOLBAR_FOLDER="true">Bookmarks Toolbar''
''<H3 PERSONAL_TOOLBAR_FOLDER="true">Bookmarks Toolbar''
else
''<H3 ADD_DATE="1" LAST_MODIFIED="1">${escapeXML directory.name}''
"<H3>${escapeXML directory.name}"
}</H3>
${indent indentLevel}<DL><p>
${allItemsToHTML (indentLevel + 1) directory.bookmarks}
${indent indentLevel}</DL><p>'';
${indent indentLevel}</p></DL>'';
itemToHTMLOrRecurse = indentLevel: item:
if item ? "url" then
@@ -127,7 +126,7 @@ let
<H1>Bookmarks Menu</H1>
<DL><p>
${bookmarkEntries}
</DL>
</p></DL>
'';
mkNoDuplicateAssertion = entities: entityKind:
@@ -378,11 +377,7 @@ in {
toolbar = mkOption {
type = types.bool;
default = false;
description = ''
Make this the toolbar directory. Note, this does _not_
mean that this directory will be added to the toolbar,
this directory _is_ the toolbar.
'';
description = "If directory should be shown in toolbar.";
};
};
}) // {
+10 -86
View File
@@ -138,77 +138,9 @@ let
};
};
abbrModule = types.submodule {
options = {
expansion = mkOption {
type = with types; nullOr str;
default = null;
description = ''
The command expanded by an abbreviation.
'';
};
position = mkOption {
type = with types; nullOr str;
default = null;
example = "anywhere";
description = ''
If the position is "command", the abbreviation expands only if
the position is a command. If it is "anywhere", the abbreviation
expands anywhere.
'';
};
regex = mkOption {
type = with types; nullOr str;
default = null;
description = ''
The regular expression pattern matched instead of the literal name.
'';
};
setCursor = mkOption {
type = with types; (either bool str);
default = false;
description = ''
The marker indicates the position of the cursor when the abbreviation
is expanded. When setCursor is true, the marker is set with a default
value of "%".
'';
};
function = mkOption {
type = with types; nullOr str;
default = null;
description = ''
The fish function expanded instead of a literal string.
'';
};
};
};
abbrsStr = concatStringsSep "\n" (mapAttrsToList (name: def:
let
mods = with def;
cli.toGNUCommandLineShell {
mkOption = k: v:
if v == null then
[ ]
else if k == "set-cursor" then
[ "--${k}=${lib.generators.mkValueStringDefault { } v}" ]
else [
"--${k}"
(lib.generators.mkValueStringDefault { } v)
];
} {
inherit position regex function;
set-cursor = setCursor;
};
modifiers = if isAttrs def then mods else "";
expansion = if isAttrs def then def.expansion else def;
in "abbr --add ${modifiers} -- ${name}"
+ optionalString (expansion != null) " ${escapeShellArg expansion}")
cfg.shellAbbrs);
abbrsStr = concatStringsSep "\n"
(mapAttrsToList (k: v: "abbr --add --global -- ${k} ${escapeShellArg v}")
cfg.shellAbbrs);
aliasesStr = concatStringsSep "\n"
(mapAttrsToList (k: v: "alias ${k} ${escapeShellArg v}") cfg.shellAliases);
@@ -222,11 +154,9 @@ let
translatedSessionVariables =
pkgs.runCommandLocal "hm-session-vars.fish" { } ''
(echo "function setup_hm_session_vars;"
${pkgs.buildPackages.babelfish}/bin/babelfish \
<${config.home.sessionVariablesPackage}/etc/profile.d/hm-session-vars.sh
echo "end"
echo "setup_hm_session_vars") > $out
<${config.home.sessionVariablesPackage}/etc/profile.d/hm-session-vars.sh \
>$out
'';
in {
@@ -269,18 +199,12 @@ in {
};
shellAbbrs = mkOption {
type = with types; attrsOf (either str abbrModule);
type = with types; attrsOf str;
default = { };
example = literalExpression ''
{
l = "less";
gco = "git checkout";
"-C" = {
position = "anywhere";
expansion = "--color";
};
}
'';
example = {
l = "less";
gco = "git checkout";
};
description = ''
An attribute set that maps aliases (the top level attribute names
in this option) to abbreviations. Abbreviations are expanded with
-116
View File
@@ -1,116 +0,0 @@
{ config, pkgs, lib, ... }:
with lib;
let
cfg = config.programs.gradle;
defaultHomeDirectory = ".gradle";
settingsFormat = pkgs.formats.javaProperties { };
initScript = types.submodule ({ name, config, ... }: {
options = {
text = mkOption {
type = types.nullOr types.lines;
default = null;
description = ''
Text of the init script file. if this option is null
then `source` must be set.
'';
};
source = mkOption {
type = types.path;
description = ''
Path of the init script file. If
`text` is non-null then this option will automatically point
to a file containing that text.
'';
};
};
config.source = mkIf (config.text != null) (mkDefault (pkgs.writeTextFile {
inherit (config) text;
name = hm.strings.storeFileName name;
}));
});
in {
meta.maintainers = [
# maintainers.britter
];
options.programs.gradle = {
enable = mkEnableOption "Gradle Build Tool";
home = mkOption {
type = types.str;
default = defaultHomeDirectory;
description = ''
The Gradle home directory, relative to [](#opt-home.homeDirectory).
If set, the {env}`GRADLE_USER_HOME` environment variable will be
set accordingly. Defaults to {file}`.gradle`.
'';
};
package = mkPackageOption pkgs "gradle" { example = "pkgs.gradle_7"; };
settings = mkOption {
type = types.submodule { freeformType = settingsFormat.type; };
default = { };
example = literalExpression ''
{
"org.gradle.caching" = true;
"org.gradle.parallel" = true;
"org.gradle.jvmargs" = "-XX:MaxMetaspaceSize=384m";
"org.gradle.home" = pkgs.jdk17;
};
'';
description = ''
Key value pairs to write to {file}`gradle.properties` in the Gradle
home directory.
'';
};
initScripts = mkOption {
type = with types; attrsOf initScript;
default = { };
example = literalExpression ''
{
"maven-local.gradle".text = '''
allProject {
repositories {
mavenLocal()
}
}
''';
"another.init.gradle.kts".source = ./another.init.gradle.kts;
}
'';
description = ''
Definition of init scripts to link into the Gradle home directory.
For more information about init scripts, including naming conventions
see https://docs.gradle.org/current/userguide/init_scripts.html.
'';
};
};
config = let gradleHome = "${config.home.homeDirectory}/${cfg.home}";
in mkIf cfg.enable {
home.packages = [ cfg.package ];
home.file = mkMerge ([{
"${cfg.home}/gradle.properties" = mkIf (cfg.settings != { }) {
source = settingsFormat.generate "gradle.properties" cfg.settings;
};
}]
++ mapAttrsToList (k: v: { "${cfg.home}/init.d/${k}".source = v.source; })
cfg.initScripts);
home.sessionVariables = mkIf (cfg.home != defaultHomeDirectory) {
GRADLE_USER_HOME = gradleHome;
};
programs.java.enable = true;
};
}
-1
View File
@@ -75,7 +75,6 @@ in {
default = { };
example = literalExpression ''
{
# the language-server option currently requires helix from the master branch at https://github.com/helix-editor/helix/
language-server.typescript-language-server = with pkgs.nodePackages; {
command = "''${typescript-language-server}/bin/typescript-language-server";
args = [ "--stdio" "--tsserver-path=''${typescript}/lib/node_modules/typescript/lib" ];
+1 -8
View File
@@ -51,13 +51,6 @@ in {
programs.msmtp = {
enable = mkEnableOption "msmtp";
package = mkOption {
type = types.package;
default = pkgs.msmtp;
defaultText = literalExpression "pkgs.msmtp";
description = "The msmtp package to use.";
};
extraConfig = mkOption {
type = types.lines;
default = "";
@@ -88,7 +81,7 @@ in {
};
config = mkIf cfg.enable {
home.packages = [ cfg.package ];
home.packages = [ pkgs.msmtp ];
xdg.configFile."msmtp/config".text = configFile msmtpAccounts;
+1 -1
View File
@@ -48,7 +48,7 @@ in {
'';
# See https://github.com/bennofs/nix-index/issues/126
programs.fish.interactiveShellInit = let
programs.fish.shellInit = let
wrapper = pkgs.writeScript "command-not-found" ''
#!${pkgs.bash}/bin/bash
source ${cfg.package}/etc/profile.d/command-not-found.sh
-83
View File
@@ -1,83 +0,0 @@
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.programs.sapling;
iniFormat = pkgs.formats.ini { };
in {
meta.maintainers = [ maintainers.pbar ];
options = {
programs.sapling = {
enable = mkEnableOption "Sapling";
package = mkPackageOption pkgs "sapling" { };
userName = mkOption {
type = types.str;
description = "Default user name to use.";
};
userEmail = mkOption {
type = types.str;
description = "Default user email to use.";
};
aliases = mkOption {
type = types.attrsOf types.str;
default = { };
description = "Sapling aliases to define.";
};
extraConfig = mkOption {
type = types.attrsOf types.anything;
default = { };
description = "Additional configuration to add.";
};
iniContent = mkOption {
type = iniFormat.type;
internal = true;
};
};
};
config = mkIf cfg.enable (mkMerge [
{
home.packages = [ cfg.package ];
programs.sapling.iniContent.ui = {
username = cfg.userName + " <" + cfg.userEmail + ">";
};
}
(mkIf (!pkgs.stdenv.isDarwin) {
xdg.configFile."sapling/sapling.conf".source =
iniFormat.generate "sapling.conf" cfg.iniContent;
})
(mkIf (pkgs.stdenv.isDarwin) {
home.file."Library/Preferences/sapling/sapling.conf".source =
iniFormat.generate "sapling.conf" cfg.iniContent;
})
(mkIf (cfg.aliases != { }) {
programs.sapling.iniContent.alias = cfg.aliases;
})
(mkIf (lib.isAttrs cfg.extraConfig) {
programs.sapling.iniContent = cfg.extraConfig;
})
(mkIf (lib.isString cfg.extraConfig && !pkgs.stdenv.isDarwin) {
xdg.configFile."sapling/sapling.conf".text = cfg.extraConfig;
})
(mkIf (lib.isString cfg.extraConfig && pkgs.stdenv.isDarwin) {
home.file."Library/Preferences/sapling/sapling.conf".text =
cfg.extraConfig;
})
]);
}
-12
View File
@@ -361,17 +361,6 @@ in
'';
};
addKeysToAgent = mkOption {
type = types.str;
default = "no";
description = ''
When enabled, a private key that is used during authentication will be
added to ssh-agent if it is running (with confirmation enabled if
set to 'confirm'). The argument must be 'no' (the default), 'yes', 'confirm'
(optionally followed by a time interval), 'ask' or a time interval (e.g. '1h').
'';
};
compression = mkOption {
default = false;
type = types.bool;
@@ -539,7 +528,6 @@ in
Host *
ForwardAgent ${lib.hm.booleans.yesNo cfg.forwardAgent}
AddKeysToAgent ${cfg.addKeysToAgent}
Compression ${lib.hm.booleans.yesNo cfg.compression}
ServerAliveInterval ${toString cfg.serverAliveInterval}
ServerAliveCountMax ${toString cfg.serverAliveCountMax}
+10 -10
View File
@@ -9,7 +9,7 @@ let
bashIntegration = ''
function ya() {
tmp="$(mktemp -t "yazi-cwd.XXXXX")"
yazi "$@" --cwd-file="$tmp"
yazi --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
cd -- "$cwd"
fi
@@ -20,8 +20,8 @@ let
fishIntegration = ''
function ya
set tmp (mktemp -t "yazi-cwd.XXXXX")
yazi $argv --cwd-file="$tmp"
if set cwd (cat -- "$tmp"); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
yazi --cwd-file="$tmp"
if set cwd (cat -- "$tmp") && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]
cd -- "$cwd"
end
rm -f -- "$tmp"
@@ -29,10 +29,10 @@ let
'';
nushellIntegration = ''
def --env ya [args?] {
let tmp = $"($env.TEMP)(char path_sep)yazi-cwd." + (random chars -l 5)
yazi $args --cwd-file $tmp
let cwd = (open $tmp)
def-env ya [] {
let tmp = (mktemp -t "yazi-cwd.XXXXX")
yazi --cwd-file $tmp
let cwd = (cat -- $tmp)
if $cwd != "" and $cwd != $env.PWD {
cd $cwd
}
@@ -82,7 +82,7 @@ in {
Configuration written to
{file}`$XDG_CONFIG_HOME/yazi/keymap.toml`.
See <https://yazi-rs.github.io/docs/configuration/keymap>
See <https://github.com/sxyazi/yazi/blob/main/config/docs/keymap.md>
for the full list of options.
'';
};
@@ -107,7 +107,7 @@ in {
Configuration written to
{file}`$XDG_CONFIG_HOME/yazi/yazi.toml`.
See <https://yazi-rs.github.io/docs/configuration/yazi>
See <https://github.com/sxyazi/yazi/blob/main/config/docs/yazi.md>
for the full list of options.
'';
};
@@ -131,7 +131,7 @@ in {
Configuration written to
{file}`$XDG_CONFIG_HOME/yazi/theme.toml`.
See <https://yazi-rs.github.io/docs/configuration/theme>
See <https://github.com/sxyazi/yazi/blob/main/config/docs/theme.md>
for the full list of options
'';
};
+1 -1
View File
@@ -76,7 +76,7 @@ in {
eval "$(${cfg.package}/bin/zoxide init zsh ${cfgOptions})"
'';
programs.fish.interactiveShellInit = mkIf cfg.enableFishIntegration ''
programs.fish.shellInit = mkIf cfg.enableFishIntegration ''
${cfg.package}/bin/zoxide init fish ${cfgOptions} | source
'';
+6
View File
@@ -52,6 +52,12 @@ in {
PrivateTmp = true;
ProtectSystem = "strict";
ProtectHome = "read-only";
ReadWritePaths = [
# /run/user/1000 for the socket
"%t"
"/nix/var/nix/gcroots/per-user/%u"
];
CacheDirectory = [ "lorri" ];
Restart = "on-failure";
Environment = let
path = with pkgs;
-70
View File
@@ -1,70 +0,0 @@
{ config, lib, pkgs, ... }:
let
cfg = config.services.signaturepdf;
extraConfigToArgs = extraConfig:
lib.flatten
(lib.mapAttrsToList (name: value: [ "-d" "${name}=${value}" ]) extraConfig);
in {
meta.maintainers = [ lib.maintainers.DamienCassou ];
options.services.signaturepdf = with lib; {
enable = mkEnableOption
"signaturepdf; signing, organizing, editing metadatas or compressing PDFs";
package = mkOption {
type = types.package;
default = pkgs.signaturepdf;
defaultText = "pkgs.signaturepdf";
description = "signaturepdf derivation to use.";
};
port = mkOption {
type = types.port;
default = 8080;
example = 8081;
description = "The port on which the application runs";
};
extraConfig = mkOption {
default = { };
type = with types;
let primitive = oneOf [ str int bool float ];
in attrsOf primitive;
example = {
upload_max_filesize = "24M";
post_max_size = "24M";
max_file_uploads = "201";
};
description = "Additional configuration optional.";
};
};
config = lib.mkIf cfg.enable {
xdg.desktopEntries = {
signaturepdf = {
name = "SignaturePDF";
exec = "${pkgs.xdg-utils}/bin/xdg-open http://localhost:${
toString cfg.port
}";
terminal = false;
icon = "${cfg.package}/share/signaturepdf/public/favicon.ico";
};
};
systemd.user.services.signaturepdf = {
Unit = {
Description =
"signaturepdf; signing, organizing, editing metadatas or compressing PDFs";
};
Service = {
ExecStart = "${cfg.package}/bin/signaturepdf ${toString cfg.port} ${
lib.escapeShellArgs (extraConfigToArgs cfg.extraConfig)
}";
};
Install = { WantedBy = [ "default.target" ]; };
};
};
}
+1 -2
View File
@@ -74,7 +74,6 @@ in {
example = literalExpression ''
[
{ timeout = 60; command = "${pkgs.swaylock}/bin/swaylock -fF"; }
{ timeout = 90; command = "${pkgs.systemd}/bin/systemctl suspend"; }
]
'';
description = "List of commands to run after idle timeout.";
@@ -85,7 +84,7 @@ in {
default = [ ];
example = literalExpression ''
[
{ event = "before-sleep"; command = "${pkgs.swaylock}/bin/swaylock -fF"; }
{ event = "before-sleep"; command = "${pkgs.swaylock}/bin/swaylock"; }
{ event = "lock"; command = "lock"; }
]
'';
+8 -14
View File
@@ -175,12 +175,6 @@ in {
Extra configuration lines to add to `~/.config/hypr/hyprland.conf`.
'';
};
sourceFirst = lib.mkEnableOption ''
putting source entries at the top of the configuration
'' // {
default = true;
};
};
config = lib.mkIf cfg.enable {
@@ -228,9 +222,9 @@ in {
inherit indent;
};
allFields = filterAttrs (n: v: !(isAttrs v)) attrs;
importantFields = filterAttrs (n: _:
(hasPrefix "$" n) || (hasPrefix "bezier" n) || (n == "plugin")
|| (cfg.sourceFirst && (hasPrefix "source" n))) allFields;
importantFields =
filterAttrs (n: _: (hasPrefix "$" n) || (hasPrefix "bezier" n))
allFields;
fields = builtins.removeAttrs allFields
(mapAttrsToList (n: _: n) importantFields);
in mkFields importantFields
@@ -243,11 +237,11 @@ in {
+ lib.optionalString (cfg.extraConfig != "") cfg.extraConfig;
onChange = lib.mkIf (cfg.package != null) ''
( # Execute in subshell so we don't poision environment with vars
# This var must be set for hyprctl to function, but the value doesn't matter.
export HYPRLAND_INSTANCE_SIGNATURE="bogus"
for i in $(${cfg.finalPackage}/bin/hyprctl instances -j | jq ".[].instance" -r); do
HYPRLAND_INSTANCE_SIGNATURE=$i ${cfg.finalPackage}/bin/hyprctl reload config-only
( # execute in subshell so that `shopt` won't affect other scripts
shopt -s nullglob # so that nothing is done if /tmp/hypr/ does not exist or is empty
for instance in /tmp/hypr/*; do
HYPRLAND_INSTANCE_SIGNATURE=''${instance##*/} ${cfg.finalPackage}/bin/hyprctl reload config-only \
|| true # ignore dead instance(s)
done
)
'';
-76
View File
@@ -1,76 +0,0 @@
{ config, lib, pkgs, ... }:
let
cfg = config.virtualisation.containers;
inherit (lib) mkOption types;
toml = pkgs.formats.toml { };
in {
meta.maintainers = [ lib.maintainers.michaelCTS ];
options.virtualisation.containers = {
enable = lib.mkEnableOption "the common containers configuration module";
ociSeccompBpfHook.enable = lib.mkEnableOption "the OCI seccomp BPF hook";
registries = {
search = mkOption {
type = types.listOf types.str;
default = [ "docker.io" "quay.io" ];
description = ''
List of repositories to search.
'';
};
insecure = mkOption {
type = types.listOf types.str;
default = [ ];
description = ''
List of insecure repositories.
'';
};
block = mkOption {
type = types.listOf types.str;
default = [ ];
description = ''
List of blocked repositories.
'';
};
};
policy = mkOption {
type = types.attrs;
default = { };
example = lib.literalExpression ''
{
default = [ { type = "insecureAcceptAnything"; } ];
transports = {
docker-daemon = {
"" = [ { type = "insecureAcceptAnything"; } ];
};
};
}
'';
description = ''
Signature verification policy file.
If this option is empty the default policy file from
`skopeo` will be used.
'';
};
};
config = lib.mkIf cfg.enable {
xdg.configFile."containers/registries.conf".source =
toml.generate "registries.conf" {
registries = lib.mapAttrs (n: v: { registries = v; }) cfg.registries;
};
xdg.configFile."containers/policy.json".source = if cfg.policy != { } then
pkgs.writeText "policy.json" (builtins.toJSON cfg.policy)
else
"${pkgs.skopeo.src}/default-policy.json";
};
}
-28
View File
@@ -1,28 +0,0 @@
# Equivalent of
# https://github.com/NixOS/nixpkgs/blob/nixos-unstable/nixos/modules/virtualisation/oci-containers.nix
{ config, lib, pkgs, ... }:
let
cfg = config.virtualisation.oci-containers;
inherit (lib) mkDefault mkIf mkMerge mkOption types;
defaultBackend = "podman";
in {
meta.maintainers = [ pkgs.lib.maintainers.michaelCTS ];
options.virtualisation.oci-containers = {
enable = lib.mkEnableOption
"a convenience option to enable containers in platform-agnostic manner";
backend = mkOption {
type = types.enum [ "podman" ];
default = defaultBackend;
description = "Which service to use as a backend for containers.";
};
};
config = mkIf (cfg.enable && cfg.backend == "podman") {
virtualisation.podman.enable = true;
};
}
@@ -1,30 +0,0 @@
# podmactl
`podmactl` is a script to manage the podman machines declared in Home
Manager.
## How it works
`main()` is a (hopefully) straight-forward method to read, but the gist of it is:
1. The declared machines and their configuration are passed in.
2. Existing machines and their configuration are listed.
3. A diff is made from the declared machines and existing machines.
4. New machines are added.
5. Existing machines are updated.
6. Old machines are removed.
7. The machine declared as `active` is started (if necessary).
## Developing
Enter a devshell with `nix-shell`.
Make your changes and then run
```
# Code autoformatting
black .
# Unittests
python -m unittest
```
@@ -1,28 +0,0 @@
{ pkgs ? (import <nixpkgs> { }), }:
pkgs.stdenv.mkDerivation {
name = "podmactl";
src = ./.;
buildInputs = [ pkgs.python311 ];
doCheck = true;
checkPhase = ''
runHook preCheck
(
cd $src
black --check .
python -m unittest
)
runHook postCheck
'';
installPhase = ''
runHook preInstall
mkdir -p $out/bin
cp podmactl.py $out/bin/podmactl
chmod +x $out/bin/podmactl
runHook postInstall
'';
}
@@ -1,317 +0,0 @@
#!/usr/bin/env python3.11
import argparse
import json
import logging
import re
import shlex
import subprocess
import sys
from argparse import ArgumentParser
from dataclasses import asdict, dataclass, field, fields
from functools import reduce
from operator import concat
from typing import Dict, Generic, Iterable, List, Optional, TypeVar
DEFAULT_MACHINE = "podman-machine-default"
T = TypeVar("T")
logger = logging.getLogger("podman-launchd")
logger_commander = logger.getChild("commander")
CAMEL_REGEX = re.compile(r"([A-Z]+)")
UNDERSCORE_REGEX = re.compile(r"^_")
@dataclass(frozen=True)
class Machine:
# Resource config for CLI
cpus: int
disk_size: int
memory: int
# Metadata about the machine
name: str
active: bool = field(compare=False, default=False)
qemu_binary: Optional[str] = None
"""A path to a custom QEMU command to be used when starting the machine with a specific arch"""
# Optional CLI parameters
image_path: Optional[str] = None
"""A local path to a custom QEMU image"""
@classmethod
def from_dict(cls, a_dict: dict) -> "Machine":
return Machine(
**{
snake_key: value
for key, value in a_dict.items()
if (snake_key := camel2snake(key).lower()) in MACHINE_FIELDS
}
)
MACHINE_FIELDS = [field.name for field in fields(Machine)]
@dataclass
class Diff(Generic[T]):
new: List[T] = field(default_factory=list)
modified: List[T] = field(default_factory=list)
same: List[T] = field(default_factory=list)
removed: List[T] = field(default_factory=list)
class PodmanMachineCommander:
MACHINE_CLI_ARGS = ("cpus", "disk_size", "memory")
def __init__(self, command: str = None):
self.command = command or "podman"
def _call(self, *args: str, **kwargs) -> str:
"""Call podman machine"""
args_ = [self.command, "machine"] + list(args)
logger_commander.debug("Executing %s", shlex.join(args_))
# no subprocess.run here as streaming is necessary
stdout_lines = []
with subprocess.Popen(
args_,
# Capture both streams in stdout
stdout=subprocess.PIPE,
stderr=subprocess.STDOUT,
**kwargs,
) as process:
# Collect stdout+stderr and steam if requested
for line in process.stdout:
line_str = line.decode().rstrip()
stdout_lines.append(line_str)
logger_commander.debug(line_str)
stdout = "\n".join(stdout_lines)
# Check if the command failed
if (return_code := process.returncode) != 0:
print(stdout, file=sys.stderr)
raise subprocess.CalledProcessError(return_code, args_, stdout)
return stdout
def _call_json(self, *args: str, **kwargs) -> dict:
"""Call podman requesting JSON output and interpret it as such"""
return json.loads(self._call(*args, "--format", "json", **kwargs))
@classmethod
def make_cli_args(
cls, machine: Machine, selected_args: Iterable[str] = MACHINE_CLI_ARGS
):
"""
Converts dict from list of key-value pair
to list of ["--key1", value1, "--key2", value2, ... ]
"""
machine_dict = asdict(machine)
return reduce(
concat,
[
[("--" + key.replace("_", "-")), str(value)]
for key in selected_args
if (value := machine_dict.get(key))
],
[],
)
def get_active_machine_name(self) -> str:
"""Name of the machine that is currently running"""
output_json = self._call_json("info")
return output_json.get("Host", {}).get("CurrentMachine")
def list(self) -> Dict[str, Machine]:
"""Get all machines known to podman"""
machine_jsons = self._call_json("list")
if not isinstance(machine_jsons, list):
raise ValueError("Unexpected output from command", machine_jsons)
# `podman machine list` has different units for disk_size, memory, etc.
# `podman machine inspect` has the information we need
inspected_jsons = self.inspect(
*[listed_machine["Name"] for listed_machine in machine_jsons]
)
return {
machine.name: machine
for inspected_json in inspected_jsons
if (
machine := Machine.from_dict(
{"name": inspected_json["Name"], **inspected_json["Resources"]}
)
)
}
def inspect(self, *machine_names: str):
"""Get information about a machine from podman"""
# The podman machine interface is really confusing
# inspect only returns JSON and other commands require --format json
return json.loads(self._call("inspect", *machine_names))
def add(self, machine: Machine):
"""
Let podman create a machine's config and initialize it
Also downloads the image of the machine
"""
self._call(
"init",
*self.make_cli_args(machine, self.MACHINE_CLI_ARGS + ("image_path",)),
machine.name,
)
def update(self, machine: Machine):
"""Update a machine's configuration and write it to disk"""
self._call("set", *self.make_cli_args(machine), machine.name)
# Set the custom QEMU path in the machine's config
# This is necessary for running machines with a specific architecture
if machine.qemu_binary:
inspection = self.inspect(machine.name)[0]
config_path = inspection.get("ConfigPath", {}).get("Path", {})
with open(config_path) as config_file:
config = json.load(config_file)
if not (cmd_line := config.get("CmdLine")):
logger.error(
"Cannot find CmdLine in config of %s at", machine.name, config_path
)
cmd_line[0] = machine.qemu_binary
with open(config_path, mode="w") as config_file:
json.dump(config, config_file)
def remove(self, machine: Machine):
"""Kills and removes the machine"""
self._call("rm", "--force", machine.name)
def start(self, machine_name: str):
"""Start up a machine"""
self._call("start", machine_name)
def stop(self, machine_name: str):
"""Stop a running machine"""
self._call("stop", machine_name)
def main(
requested_machines: Dict[str, Machine],
podman_command: str,
):
"""
:param requested_machines: Which machines should exist on the host
:param podman_command: The path to or the podman command itself
"""
podman_command = podman_command or "podman"
commander = PodmanMachineCommander(podman_command)
active_machines = [
name for name, machine in requested_machines.items() if machine.active
]
if len(active_machines) != 1:
raise ValueError("Exactly one machine in the configuration should be active")
requested_active = active_machines[0]
old_machines = commander.list()
# Find machines to add, update, delete
diffs = diff_machines(requested_machines, old_machines)
# Init new machines
for new_machine in diffs.new:
logger.info("Adding machine: %s. This may take some time...", new_machine.name)
commander.add(new_machine)
# Init the default machine if it's not
# Delete old ones
for removed_machine in diffs.removed:
logger.info("Removing machine: %s", removed_machine.name)
commander.remove(removed_machine)
# Update configuration of qemuBinary if necessary
for mod_machine in diffs.modified:
logger.info("Updating machine: %s", mod_machine.name)
commander.update(mod_machine)
# Start the requested machine if it isn't already running
active_machine = commander.get_active_machine_name()
if active_machine != requested_active:
if active_machine:
logger.info("Stopping machine: %s", active_machine)
commander.stop(active_machine)
logger.info("Starting: %s", requested_active)
commander.start(requested_active)
logger.info("%s is active and podman is ready to be used")
def camel2snake(camel: str) -> str:
"""
Converts camelCase to snake_case
"""
snake = CAMEL_REGEX.sub(r"_\1", camel).lower()
# if snake starts with _ remove it
return UNDERSCORE_REGEX.sub("", snake)
def diff_machines(
requested_machines: Dict[str, Machine], old_machines: Dict[str, Machine]
) -> Diff[Machine]:
diff: Diff[Machine] = Diff()
requested_names = requested_machines.keys()
old_names = old_machines.keys()
requested_items = requested_machines.items()
old_items = old_machines.items()
diff.new = [requested_machines[name] for name in (requested_names - old_names)]
diff.removed = [old_machines[name] for name in (old_names - requested_names)]
diff.same = list(dict(old_items & requested_items).values())
# Find modified machines = same key, different Machine
diff.modified = [
requested_machines[key]
for key in (requested_names & old_names)
if requested_machines[key] != old_machines[key]
]
return diff
def MachineDict(json_path: str) -> dict:
try:
with open(json_path) as json_file:
loaded_json = json.load(json_file)
return {
name: Machine.from_dict({"name": name, **machine})
for name, machine in loaded_json.items()
}
except json.JSONDecodeError as decode_error:
raise argparse.ArgumentTypeError() from decode_error
except Exception as exc:
raise argparse.ArgumentTypeError() from exc
if __name__ == "__main__":
parser = ArgumentParser(
"podman-launchd", description="CRUDs pod machines and starts one"
)
parser.add_argument(
"machines",
help="Path to JSON configuration of machines that should be on this host",
type=MachineDict,
)
parser.add_argument(
"-p", "--podman", help="Name or path of the podman command to use"
)
parser.add_argument(
"--verbose", help="Activate verbose logging", action="store_true"
)
cmd_args = parser.parse_args()
logging.basicConfig(level=logging.DEBUG if cmd_args.verbose else logging.INFO)
try:
main(cmd_args.machines, cmd_args.podman)
except:
logger.exception("Couldn't complete command")
exit(1)
@@ -1,5 +0,0 @@
{ pkgs ? import <nixpkgs> { } }:
pkgs.mkShell {
buildInputs = [ (pkgs.python311.withPackages (ps: with ps; [ black ])) ];
}
@@ -1,232 +0,0 @@
import argparse
import json
import tempfile
import unittest
from podmactl import (
Machine,
MachineDict,
diff_machines,
PodmanMachineCommander,
)
class MachineTestCase(unittest.TestCase):
def test_from_list_dict(self):
"""Ensure that dicts from `podman machine list` can create a machine object"""
self.assertEqual(
Machine(
cpus=2, disk_size=100, memory=2048, name="indie-machine", active=True
),
Machine.from_dict(
dict(
CPUs=2,
DiskSize=100,
Memory=2048,
Name="indie-machine",
)
),
)
def test_from_extra_dict(self):
self.assertEqual(
Machine(
cpus=2, disk_size=100, memory=2048, name="indie-machine", active=True
),
Machine.from_dict(
dict(
cpus=2,
disk_size=100,
memory=2048,
name="indie-machine",
active=True,
new=True,
dont_exist="something",
something_else="ladidah",
)
),
)
def test_from_bad_dict(self):
"""Will pass the wrong number of args to the __init__"""
self.assertRaises(
TypeError,
Machine.from_dict,
dict(
cpus=2,
),
)
def test_make_cli_args(self):
args = PodmanMachineCommander.make_cli_args(
Machine(cpus=2, disk_size=50, memory=4096, name="manjaro", active=False)
)
self.assertEqual(
args,
[
"--cpus",
"2",
"--disk-size",
"50",
"--memory",
"4096",
],
)
def test_make_optional_cli_args(self):
machine = Machine(
cpus=2,
disk_size=50,
memory=4096,
name="manjaro",
active=False,
image_path="somewhere.qcow2.xz",
)
self.assertEqual(
PodmanMachineCommander.make_cli_args(machine),
[
"--cpus",
"2",
"--disk-size",
"50",
"--memory",
"4096",
],
)
self.assertEqual(
PodmanMachineCommander.make_cli_args(
machine, PodmanMachineCommander.MACHINE_CLI_ARGS + ("image_path",)
),
[
"--cpus",
"2",
"--disk-size",
"50",
"--memory",
"4096",
"--image-path",
"somewhere.qcow2.xz",
],
)
class MachineDictTestCase(unittest.TestCase):
def test_load(self):
machine_json = {
"cpus": 2,
"disk_size": 100,
"memory": 2048,
"active": False,
}
machines_json = {"default": machine_json}
with tempfile.NamedTemporaryFile(mode="w") as fp:
json.dump(machines_json, fp)
fp.seek(0)
machines = MachineDict(fp.name)
self.assertDictEqual(
machines,
{
"default": Machine(
cpus=2,
disk_size=100,
memory=2048,
name="default",
active=False,
)
},
)
def test_bad_machine_load(self):
with self.assertRaises(argparse.ArgumentTypeError):
with tempfile.NamedTemporaryFile(mode="w") as fp:
json.dump({"default": {}}, fp)
fp.seek(0)
MachineDict(fp.name)
def test_bad_json_load(self):
with self.assertRaises(argparse.ArgumentTypeError):
with tempfile.NamedTemporaryFile(mode="w") as fp:
fp.write("this is definitely not a json")
fp.seek(0)
MachineDict(fp.name)
class DiffTestCase(unittest.TestCase):
def test_new_machines(self):
diff = diff_machines(
{
"new": Machine(
cpus=1, disk_size=100, memory=1024, name="new", active=True
),
"old": Machine(
cpus=1, disk_size=100, memory=1024, name="old", active=False
),
},
{
"old": Machine(
cpus=1, disk_size=100, memory=1024, name="old", active=False
),
},
)
self.assertListEqual(
diff.new,
[Machine(cpus=1, disk_size=100, memory=1024, name="new", active=False)],
)
self.assertListEqual(
diff.same,
[Machine(cpus=1, disk_size=100, memory=1024, name="old", active=False)],
)
self.assertListEqual(diff.removed, [])
self.assertListEqual(diff.modified, [])
def test_update_machine(self):
diff = diff_machines(
{
"changed": Machine(
cpus=1, disk_size=100, memory=1024, name="changed", active=True
),
},
{
"changed": Machine(
cpus=2, disk_size=100, memory=2048, name="changed", active=False
),
},
)
self.assertListEqual(diff.new, [])
self.assertListEqual(diff.same, [])
self.assertListEqual(diff.removed, [])
self.assertListEqual(
diff.modified,
[Machine(cpus=1, disk_size=100, memory=1024, name="changed", active=False)],
)
def test_remove_machine(self):
diff = diff_machines(
{
"same": Machine(
cpus=1, disk_size=100, memory=1024, name="same", active=True
),
},
{
"same": Machine(
cpus=1, disk_size=100, memory=1024, name="same", active=False
),
"removed": Machine(
cpus=1, disk_size=100, memory=1024, name="removed", active=True
),
},
)
self.assertListEqual(diff.new, [])
self.assertListEqual(
diff.same,
[Machine(cpus=1, disk_size=100, memory=1024, name="same", active=False)],
)
self.assertListEqual(
diff.removed,
[Machine(cpus=1, disk_size=100, memory=1024, name="removed", active=False)],
)
self.assertListEqual(diff.modified, [])
if __name__ == "__main__":
unittest.main()
-274
View File
@@ -1,274 +0,0 @@
{ config, lib, pkgs, ... }:
let
cfg = config.virtualisation.podman;
toml = pkgs.formats.toml { };
json = pkgs.formats.json { };
inherit (lib) mkDefault mkIf mkMerge mkOption types;
podmanPackage = (pkgs.podman.override { inherit (cfg) extraPackages; });
# Provides a fake "docker" binary mapping to podman
dockerAlias = pkgs.runCommandNoCC
"${podmanPackage.pname}-docker-alias-${podmanPackage.version}" {
outputs = [ "out" "man" ];
inherit (podmanPackage) meta;
} ''
mkdir -p $out/bin
ln -s ${podmanPackage}/bin/podman $out/bin/docker
mkdir -p $man/share/man/man1
for f in ${podmanPackage.man}/share/man/man1/*; do
basename=$(basename $f | sed s/podman/docker/g)
ln -s $f $man/share/man/man1/$basename
done
'';
podmactl = pkgs.callPackage ./podmactl { };
machineOpts = {
# Options here are loaded into python. For simplicity, please use
# snake_case.
options = {
active = mkOption {
type = types.bool;
default = false;
description = ''
This machine should be started. Only one machine can be active at a time
'';
};
qemu_binary = mkOption {
type = types.nullOr types.str;
default = null;
example = "''${pkgs.qemu}/bin/qemu-system-x86_64";
description = ''
Use this to start VM with the qemu appropriate for your architecture.
'';
};
# Options passed to Podman machine.
# See https://docs.podman.io/en/latest/markdown/podman-machine.1.html
cpus = mkOption {
type = types.ints.positive;
default = 1;
description = "The number of CPUs to assign to the VM.";
};
disk_size = mkOption {
type = types.ints.positive;
default = 100;
description = "Size of disk in gigabytes. Can only be increased";
};
image_path = mkOption {
type = types.nullOr types.str;
default = null;
example = lib.literalExpression ''
builtins.fetchurl "https://builds.coreos.fedoraproject.org/prod/streams/stable/builds/38.20230819.3.0/x86_64/fedora-coreos-38.20230819.3.0-qemu.x86_64.qcow2.xz"'';
description = ''
Image to be used when starting the VM
Can be a local path or a URL to an image.
Alternatives can be found at <https://fedoraproject.org/en/coreos/download>.
'';
};
memory = mkOption {
type = types.ints.positive;
default = 2048;
description = "RAM in MB to be assigned to the machine";
};
};
};
in {
meta.maintainers = [ pkgs.lib.maintainers.michaelCTS ];
options.virtualisation.podman = {
enable = mkOption {
type = types.bool;
default = false;
description = ''
This option enables Podman, a daemonless container engine for
developing, managing, and running OCI Containers on your Linux System.
It is a drop-in replacement for the {command}`docker` command.
'';
};
enableDockerSocket = mkOption {
type = types.bool;
default = false;
description = ''
Make the Podman socket available in place of the Docker socket, so
Docker tools can find the Podman socket.
Podman implements the Docker API.
'';
};
enableDockerAlias = mkOption {
type = types.bool;
default = false;
description = ''
Create an alias mapping {command}`docker` to {command}`podman`.
'';
};
extraPackages = mkOption {
type = with types; listOf package;
default = [ ];
example = lib.literalExpression "[ pkgs.gvisor ]";
description = ''
Extra packages to be installed in the Podman wrapper.
'';
};
finalPackage = lib.mkOption {
type = types.package;
internal = true;
readOnly = true;
default = podmanPackage;
description = ''
The final Podman package (including extra packages).
'';
};
defaultNetwork.extraPlugins = lib.mkOption {
type = types.listOf json.type;
default = [ ];
description = ''
Extra CNI plugin configurations to add to Podman's default network.
'';
};
machines = lib.mkOption {
type = types.attrsOf (types.submodule machineOpts);
# One and only one machine may be active at any given time
apply = machines:
assert ((lib.lists.count (machine: machine.active)
(lib.attrsets.attrValues machines)) == 1);
machines;
default = {
podman-machine-default = {
active = true;
cpus = 2;
disk_size = 100;
memory = 2048;
};
};
example = lib.literalExpression ''
{
intel-x86 = {
cpus = 2;
disk_size = 200;
memory = 4096;
image_path = "fedora-coreos-38.20230806.3.0-qemu.x86_64.qcow2.xz";
qemu_binary = "${pkgs.qemu}/bin/qemu-system-x86_64";
};
}
'';
description = ''
Virtual machine descriptions when Podman is run in on non-Linux systems.
'';
};
};
config = mkIf cfg.enable (mkMerge [
{
home.packages = [ cfg.finalPackage ]
++ lib.optional cfg.enableDockerAlias dockerAlias;
virtualisation.containers = {
enable = true; # Enable common /etc/containers configuration
};
}
(mkIf pkgs.stdenv.hostPlatform.isLinux (mkMerge [
{
systemd.user = {
services.podman = {
Unit = {
Description = "Podman API Service";
Requires = "podman.socket";
After = "podman.socket";
Documentation = "man:podman-system-service(1)";
StartLimitIntervalSec = 0;
};
Service = {
Type = "exec";
KillMode = "process";
Environment = ''LOGGING=" --log-level=info"'';
ExecStart = [
"${cfg.finalPackage}/bin/podman"
"$LOGGING"
"system"
"service"
];
};
Install = { WantedBy = [ "default.target" ]; };
};
sockets.podman = {
Unit = {
Description = "Podman API Socket";
Documentation = "man:podman-system-service(1)";
};
Socket = {
ListenStream = "%t/podman/podman.sock";
SocketMode = 660;
};
Install.WantedBy = [ "sockets.target" ];
};
};
}
(mkIf cfg.enableDockerSocket {
home.sessionVariables."DOCKER_HOST" =
"unix:///$XDG_RUNTIME_DIR/podman/podman.sock";
})
]))
(mkIf pkgs.stdenv.isDarwin (mkMerge [
{
home.packages = [
pkgs.qemu # To manage machines
pkgs.openssh # To ssh into the machines
];
}
{
home.extraActivationPath = [
pkgs.qemu # To manage machines.
pkgs.openssh # To ssh into the machines.
];
# CRUD the requested podman machines when activating the profile
home.activation.podman-machine =
lib.hm.dag.entryAfter [ "writeBoundary" ]
(lib.strings.concatStringsSep " " [
"$DRY_RUN_CMD"
"${podmactl}/bin/podmactl"
"--podman"
"${cfg.finalPackage}/bin/podman"
"$VERBOSE_ARG"
"${json.generate "podman-machines.json" cfg.machines}"
]);
}
# Socket is actually only available after the launchd agent has
# successfully completed and the machine has been started.
(mkIf cfg.enableDockerSocket {
home.sessionVariables."DOCKER_HOST" =
"unix:///Users/$USER/.local/share/containers/podman/machine/qemu/podman.sock";
})
]))
]);
}
+1 -1
View File
@@ -1,4 +1,4 @@
{
"release": "24.05",
"release": "23.11",
"isReleaseBranch": false
}
+4 -12
View File
@@ -4,10 +4,9 @@ let
lib = import ../modules/lib/stdlib-extended.nix pkgs.lib;
nmt = fetchTarball {
url =
"https://gitlab.com/api/v4/projects/rycee%2Fnmt/repository/archive.tar.gz?sha=4df00c569b1badfedffecd7ccd60f794550486db";
sha256 = "1cyly1zazgj8z6bazml4js7lqaqvpp8lw045aqchlpvp42bl1lp4";
nmtSrc = fetchTarball {
url = "https://git.sr.ht/~rycee/nmt/archive/v0.5.1.tar.gz";
sha256 = "0qhn7nnwdwzh910ss78ga2d00v42b0lspfd7ybl61mpfgz3lmdcj";
};
modules = import ../modules/modules.nix {
@@ -41,9 +40,7 @@ let
isDarwin = pkgs.stdenv.hostPlatform.isDarwin;
isLinux = pkgs.stdenv.hostPlatform.isLinux;
in
import nmt {
in import nmtSrc {
inherit lib pkgs modules;
testedAttrPath = [ "home" "activationPackage" ];
tests = builtins.foldl' (a: b: a // (import b)) { } ([
@@ -84,7 +81,6 @@ import nmt {
./modules/programs/git
./modules/programs/git-cliff
./modules/programs/gpg
./modules/programs/gradle
./modules/programs/granted
./modules/programs/helix
./modules/programs/himalaya
@@ -136,7 +132,6 @@ import nmt {
./modules/programs/rtx
./modules/programs/ruff
./modules/programs/sagemath
./modules/programs/sapling
./modules/programs/sbt
./modules/programs/scmpuff
./modules/programs/sioyek
@@ -159,7 +154,6 @@ import nmt {
./modules/programs/zplug
./modules/programs/zsh
./modules/services/syncthing/common
./modules/virtualisation/podman
./modules/xresources
] ++ lib.optionals isDarwin [
./modules/launchd
@@ -247,7 +241,6 @@ import nmt {
./modules/services/recoll
./modules/services/redshift-gammastep
./modules/services/screen-locker
./modules/services/signaturepdf
./modules/services/swayidle
./modules/services/swayosd
./modules/services/sxhkd
@@ -264,7 +257,6 @@ import nmt {
./modules/services/wlsunset
./modules/services/xsettingsd
./modules/systemd
./modules/virtualisation/oci-containers
./modules/targets-linux
]);
}
@@ -54,17 +54,9 @@ from = Foo Bar <addr@mail.invalid>
outgoing = smtp+insecure+plain://foobar@smtp.host.invalid:42
outgoing-cred-cmd = echo PaSsWorD!
[i1_maildir-mbsync]
[i_maildir-mbsync]
from = Foo Bar <addr@mail.invalid>
source = maildir:///home/hm-user/Maildir/i1_maildir-mbsync
[i2_maildirpp-mbsync]
from = Foo Bar <addr@mail.invalid>
source = maildirpp:///home/hm-user/Maildir/i2_maildirpp-mbsync/Inbox
[i3_maildir_flatten-mbsync]
from = Foo Bar <addr@mail.invalid>
source = maildir:///home/hm-user/Maildir/i3_maildir_flatten-mbsync
source = maildir:///home/hm-user/Maildir/i_maildir-mbsync
[j_maildir-offlineimap]
from = Foo Bar <addr@mail.invalid>
+1 -10
View File
@@ -202,16 +202,7 @@ with lib;
tls.useStartTls = true;
};
};
i1_maildir-mbsync = basics // { mbsync.enable = true; };
i2_maildirpp-mbsync = basics // {
mbsync.enable = true;
mbsync.subFolders = "Maildir++";
};
i3_maildir_flatten-mbsync = basics // {
mbsync.enable = true;
mbsync.subFolders = "Maildir++";
mbsync.flatten = ".";
};
i_maildir-mbsync = basics // { mbsync.enable = true; };
j_maildir-offlineimap = basics // { offlineimap.enable = true; };
k_notEnabled = basics // { aerc.enable = false; };
l_smtp-auth-none = basics // {
+1 -1
View File
@@ -14,6 +14,6 @@
in ''
assertFileExists "${configFile}"
assertFileRegex "${configFile}" \
'^\s*let direnv = (/nix/store/.*direnv.*/bin/direnv export json$'
'let direnv = (/nix/store/.*direnv.*/bin/direnv export json | from json)'
'';
}
@@ -6,20 +6,20 @@
<TITLE>Bookmarks</TITLE>
<H1>Bookmarks Menu</H1>
<DL><p>
<DT><H3 ADD_DATE="1" LAST_MODIFIED="1" PERSONAL_TOOLBAR_FOLDER="true">Bookmarks Toolbar</H3>
<DT><H3 PERSONAL_TOOLBAR_FOLDER="true">Bookmarks Toolbar</H3>
<DL><p>
<DT><A HREF="https://nixos.wiki/wiki/Home_Manager" ADD_DATE="1" LAST_MODIFIED="1">Home Manager</A>
</DL><p>
</p></DL>
<DT><A HREF="https://en.wikipedia.org/wiki/Special:Search?search=%s&amp;go=Go" ADD_DATE="1" LAST_MODIFIED="1" SHORTCUTURL="wiki" TAGS="wiki">wikipedia</A>
<DT><A HREF="https://www.kernel.org" ADD_DATE="1" LAST_MODIFIED="1">kernel.org</A>
<DT><H3 ADD_DATE="1" LAST_MODIFIED="1">Nix sites</H3>
<DT><H3>Nix sites</H3>
<DL><p>
<DT><A HREF="https://nixos.org/" ADD_DATE="1" LAST_MODIFIED="1">homepage</A>
<DT><A HREF="https://nixos.wiki/" ADD_DATE="1" LAST_MODIFIED="1" TAGS="wiki,nix">wiki</A>
<DT><H3 ADD_DATE="1" LAST_MODIFIED="1">Nix sites</H3>
<DT><H3>Nix sites</H3>
<DL><p>
<DT><A HREF="https://nixos.org/" ADD_DATE="1" LAST_MODIFIED="1">homepage</A>
<DT><A HREF="https://nixos.wiki/" ADD_DATE="1" LAST_MODIFIED="1">wiki</A>
</DL><p>
</DL><p>
</DL>
</p></DL>
</p></DL>
</p></DL>
-72
View File
@@ -1,72 +0,0 @@
{ config, ... }: {
config = {
programs.fish = {
enable = true;
shellAbbrs = {
l = "less";
gco = "git checkout";
"-C" = {
position = "anywhere";
expansion = "--color";
};
L = {
position = "anywhere";
setCursor = true;
expansion = "% | less";
};
"!!" = {
position = "anywhere";
function = "last_history_item";
};
vim_edit_texts = {
position = "command";
regex = ".+\\.txt";
function = "vim_edit";
};
"4DIRS" = {
setCursor = "!";
expansion = ''
for dir in */
cd $dir
!
cd ..
end
'';
};
dotdot = {
regex = "^\\.\\.+$";
function = "multicd";
};
};
};
nmt = {
description =
"if fish.shellAbbrs is set, check fish.config contains valid abbreviations";
script = ''
assertFileContains home-files/.config/fish/config.fish \
"abbr --add -- l less"
assertFileContains home-files/.config/fish/config.fish \
"abbr --add -- gco 'git checkout'"
assertFileContains home-files/.config/fish/config.fish \
"abbr --add --position anywhere -- -C --color"
assertFileContains home-files/.config/fish/config.fish \
"abbr --add --position anywhere --set-cursor -- L '% | less'"
assertFileContains home-files/.config/fish/config.fish \
"abbr --add --function last_history_item --position anywhere -- !!"
assertFileContains home-files/.config/fish/config.fish \
"abbr --add --function vim_edit --position command --regex '.+\.txt' -- vim_edit_texts"
assertFileContains home-files/.config/fish/config.fish \
"abbr --add '--set-cursor=!' -- 4DIRS 'for dir in */
cd \$dir
!
cd ..
end
'"
assertFileContains home-files/.config/fish/config.fish \
"abbr --add --function multicd --regex '^\.\.+$' -- dotdot"
'';
};
};
}
-1
View File
@@ -1,5 +1,4 @@
{
fish-abbrs = ./abbrs.nix;
fish-format-scripts = ./format-scripts.nix;
fish-functions = ./functions.nix;
fish-no-functions = ./no-functions.nix;
@@ -1,26 +0,0 @@
{ config, lib, pkgs, ... }:
with lib;
{
config = {
programs.gradle = {
enable = true;
home = ".gbt";
settings = { "org.gradle.caching" = true; };
initScripts = { "some-script.gradle".text = "println 'hello world'"; };
};
programs.java.package =
pkgs.runCommandLocal "java" { home = ""; } "mkdir $out";
test.stubs.gradle = { };
nmt.script = ''
assertFileContains home-path/etc/profile.d/hm-session-vars.sh \
'export GRADLE_USER_HOME="/home/hm-user/.gbt"'
assertFileExists home-files/.gbt/gradle.properties
assertFileExists home-files/.gbt/init.d/some-script.gradle
'';
};
}
@@ -1,7 +0,0 @@
{
gradle-empty-settings = ./empty-settings.nix;
gradle-example-settings = ./example-settings.nix;
gradle-init-scripts-settings = ./init-scripts-settings.nix;
gradle-alternate-home-settings = ./alternate-home-settings.nix;
}
@@ -1,17 +0,0 @@
{ pkgs, ... }:
{
config = {
programs.gradle.enable = true;
programs.java.package =
pkgs.runCommandLocal "java" { home = ""; } "mkdir $out";
test.stubs.gradle = { };
nmt.script = ''
assertPathNotExists home-files/.gradle
assertFileNotRegex home-path/etc/profile.d/hm-session-vars.sh 'GRADLE_USER_HOME'
'';
};
}
@@ -1,42 +0,0 @@
{ config, lib, pkgs, ... }:
with lib;
{
config = {
programs.gradle = {
enable = true;
settings = {
"org.gradle.caching" = true;
"org.gradle.parallel" = true;
"org.gradle.java.home" = pkgs.jdk17;
"org.gradle.java.installations.paths" = "${pkgs.jdk8},${pkgs.jdk11}";
};
};
programs.java.package =
pkgs.runCommandLocal "java" { home = ""; } "mkdir $out";
test.stubs = {
gradle = { };
jdk = { };
jdk8 = { };
jdk11 = { };
jdk17 = { };
};
nmt.script = ''
assertFileExists home-files/.gradle/gradle.properties
assertFileContent home-files/.gradle/gradle.properties ${
builtins.toFile "gradle.expected" ''
# Generated with Nix
org.gradle.caching = true
org.gradle.java.home = @jdk17@
org.gradle.java.installations.paths = @jdk8@,@jdk11@
org.gradle.parallel = true
''
}
'';
};
}
@@ -1 +0,0 @@
println 'external-init-script-1'
@@ -1,37 +0,0 @@
{ config, lib, pkgs, ... }:
with lib;
{
config = {
programs.gradle = {
enable = true;
initScripts = {
"inline-init-script.gradle".text = ''
println 'inline-init-script'
'';
"external-init-script.gradle".source = ./external-init-script.gradle;
};
};
programs.java.package =
pkgs.runCommandLocal "java" { home = ""; } "mkdir $out";
test.stubs.gradle = { };
nmt.script = ''
assertFileExists home-files/.gradle/init.d/inline-init-script.gradle
assertFileContent home-files/.gradle/init.d/inline-init-script.gradle ${
pkgs.writeText "gradle.expected" ''
println 'inline-init-script'
''
}
assertFileExists home-files/.gradle/init.d/external-init-script.gradle
assertFileContent home-files/.gradle/init.d/external-init-script.gradle ${
./external-init-script.gradle
}
'';
};
}
@@ -1,4 +0,0 @@
{
sapling-basic = ./sapling-basic.nix;
sapling-most = ./sapling-most.nix;
}
@@ -1,26 +0,0 @@
{ pkgs, ... }:
{
programs.sapling = {
enable = true;
userName = "John Doe";
userEmail = "johndoe@example.com";
};
test.stubs.sapling = { };
nmt.script = let
configfile = if pkgs.stdenv.isDarwin then
"Library/Preferences/sapling/sapling.conf"
else
".config/sapling/sapling.conf";
expected = builtins.toFile "sapling.conf" ''
[ui]
username=John Doe <johndoe@example.com>
'';
in ''
assertFileExists home-files/${configfile}
assertFileContent home-files/${configfile} ${expected}
'';
}
@@ -1,48 +0,0 @@
{ pkgs, ... }:
{
programs.sapling = {
enable = true;
userName = "John Doe";
userEmail = "johndoe@example.com";
aliases = {
cm = "commit";
d = "diff --exclude=*.lock";
s = "status";
view = "!$HG config paths.default | xargs open";
};
extraConfig = {
pager.pager = "delta";
gpg.key = "not-an-actual-key";
};
};
test.stubs.sapling = { };
nmt.script = let
configfile = if pkgs.stdenv.isDarwin then
"Library/Preferences/sapling/sapling.conf"
else
".config/sapling/sapling.conf";
expected = builtins.toFile "sapling.conf" ''
[alias]
cm=commit
d=diff --exclude=*.lock
s=status
view=!$HG config paths.default | xargs open
[gpg]
key=not-an-actual-key
[pager]
pager=delta
[ui]
username=John Doe <johndoe@example.com>
'';
in ''
assertFileExists home-files/${configfile}
assertFileContent home-files/${configfile} ${expected}
'';
}
@@ -2,7 +2,6 @@
Host *
ForwardAgent no
AddKeysToAgent no
Compression no
ServerAliveInterval 0
ServerAliveCountMax 3
@@ -5,7 +5,6 @@ Host dynamicBindPathNoPort
Host *
ForwardAgent no
AddKeysToAgent no
Compression no
ServerAliveInterval 0
ServerAliveCountMax 3
@@ -18,7 +18,6 @@ Host ordered
Host *
ForwardAgent no
AddKeysToAgent no
Compression no
ServerAliveInterval 0
ServerAliveCountMax 3
@@ -7,7 +7,6 @@ Match host xyz canonical
Host *
ForwardAgent no
AddKeysToAgent no
Compression no
ServerAliveInterval 0
ServerAliveCountMax 3
@@ -14,7 +14,7 @@
nmt.script = ''
assertFileNotRegex home-files/.bashrc '@thefuck@/bin/thefuck'
assertPathNotExists home-files/.config/fish/functions/fuck.fish
assertFileNotExists home-files/.config/fish/functions/fuck.fish
assertFileNotRegex home-files/.zshrc '@thefuck@/bin/thefuck'
'';
}
@@ -4,7 +4,7 @@ let
shellIntegration = ''
function ya() {
tmp="$(mktemp -t "yazi-cwd.XXXXX")"
yazi "$@" --cwd-file="$tmp"
yazi --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
cd -- "$cwd"
fi
@@ -4,8 +4,8 @@ let
shellIntegration = ''
function ya
set tmp (mktemp -t "yazi-cwd.XXXXX")
yazi $argv --cwd-file="$tmp"
if set cwd (cat -- "$tmp"); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
yazi --cwd-file="$tmp"
if set cwd (cat -- "$tmp") && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]
cd -- "$cwd"
end
rm -f -- "$tmp"
@@ -2,10 +2,10 @@
let
shellIntegration = ''
def --env ya [args?] {
let tmp = $"($env.TEMP)(char path_sep)yazi-cwd." + (random chars -l 5)
yazi $args --cwd-file $tmp
let cwd = (open $tmp)
def-env ya [] {
let tmp = (mktemp -t "yazi-cwd.XXXXX")
yazi --cwd-file $tmp
let cwd = (cat -- $tmp)
if $cwd != "" and $cwd != $env.PWD {
cd $cwd
}
@@ -4,7 +4,7 @@ let
shellIntegration = ''
function ya() {
tmp="$(mktemp -t "yazi-cwd.XXXXX")"
yazi "$@" --cwd-file="$tmp"
yazi --cwd-file="$tmp"
if cwd="$(cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
cd -- "$cwd"
fi
@@ -1,7 +0,0 @@
[Desktop Entry]
Exec=@xdg-utils@/bin/xdg-open http://localhost:9494
Icon=/signaturepdf/share/signaturepdf/public/favicon.ico
Name=SignaturePDF
Terminal=false
Type=Application
Version=1.4
@@ -1,24 +0,0 @@
{ config, pkgs, ... }:
{
services.signaturepdf = {
enable = true;
port = 9494;
extraConfig = { upload_max_filesize = "24M"; };
};
test.stubs = {
signaturepdf = { outPath = "/signaturepdf"; };
xdg-utils = { };
};
nmt.script = ''
assertFileContent \
home-files/.config/systemd/user/signaturepdf.service \
${./basic-configuration.service}
assertFileContent \
home-path/share/applications/signaturepdf.desktop \
${./basic-configuration.desktop}
'';
}
@@ -1,8 +0,0 @@
[Install]
WantedBy=default.target
[Service]
ExecStart=/signaturepdf/bin/signaturepdf 9494 '-d' 'upload_max_filesize=24M'
[Unit]
Description=signaturepdf; signing, organizing, editing metadatas or compressing PDFs
@@ -1 +0,0 @@
{ signaturepdf-basic-configuration = ./basic-configuration.nix; }
@@ -3,9 +3,6 @@ $mod=SUPER
bezier=smoothOut, 0.36, 0, 0.66, -0.56
bezier=smoothIn, 0.25, 1, 0.5, 1
bezier=overshot, 0.4,0.8,0.2,1.2
plugin=/path/to/plugin1
plugin=/nix/store/00000000000000000000000000000000-foo/lib/libfoo.so
source=sourced.conf
animations {
animation=border, 1, 2, smoothIn
animation=fade, 1, 4, smoothOut
@@ -29,6 +26,8 @@ input {
bindm=$mod, mouse:272, movewindow
bindm=$mod, mouse:273, resizewindow
bindm=$mod ALT, mouse:272, resizewindow
plugin=/path/to/plugin1
plugin=/nix/store/00000000000000000000000000000000-foo/lib/libfoo.so
# window resize
bind = $mod, S, submap, resize
@@ -8,8 +8,6 @@
plugins =
[ "/path/to/plugin1" (config.lib.test.mkStubPackage { name = "foo"; }) ];
settings = {
source = [ "sourced.conf" ];
decoration = {
shadow_offset = "0 5";
"col.shadow" = "rgba(00000099)";
@@ -5,7 +5,7 @@
dmenu = { };
foot = { };
i3status = { };
sway = { version = "1"; };
sway = { };
sway-unwrapped = { version = "1"; };
swaybg = { };
xwayland = { };
@@ -1,52 +0,0 @@
{ config, lib, pkgs, ... }:
lib.mkIf config.test.enableBig {
virtualisation.oci-containers.enable = true;
nmt.script = lib.mkIf pkgs.stdenv.isLinux ''
servicePath=home-files/.config/systemd/user
assertFileExists $servicePath/podman.service $servicePath/podman.socket
podmanServiceNormalized="$(normalizeStorePaths "$servicePath/podman.service")"
assertFileContent $podmanServiceNormalized \
${
builtins.toFile "podman.service-expected" ''
[Install]
WantedBy=default.target
[Service]
Environment=LOGGING=" --log-level=info"
ExecStart=/nix/store/00000000000000000000000000000000-podman/bin/podman
ExecStart=$LOGGING
ExecStart=system
ExecStart=service
KillMode=process
Type=exec
[Unit]
After=podman.socket
Description=Podman API Service
Documentation=man:podman-system-service(1)
Requires=podman.socket
StartLimitIntervalSec=0
''
}
assertFileContent $servicePath/podman.socket \
${
builtins.toFile "podman.socket-expected" ''
[Install]
WantedBy=sockets.target
[Socket]
ListenStream=%t/podman/podman.sock
SocketMode=660
[Unit]
Description=Podman API Socket
Documentation=man:podman-system-service(1)
''
}
'';
}
@@ -1 +0,0 @@
{ oci-containers-basic-config = ./basic-config.nix; }
@@ -1,52 +0,0 @@
{ config, pkgs, lib, ... }:
lib.mkIf config.test.enableBig {
virtualisation.podman.enable = true;
nmt.script = lib.mkIf pkgs.stdenv.isLinux ''
servicePath=home-files/.config/systemd/user
assertFileExists $servicePath/podman.service $servicePath/podman.socket
podmanServiceNormalized="$(normalizeStorePaths "$servicePath/podman.service")"
assertFileContent $podmanServiceNormalized \
${
builtins.toFile "podman.service-expected" ''
[Install]
WantedBy=default.target
[Service]
Environment=LOGGING=" --log-level=info"
ExecStart=/nix/store/00000000000000000000000000000000-podman/bin/podman
ExecStart=$LOGGING
ExecStart=system
ExecStart=service
KillMode=process
Type=exec
[Unit]
After=podman.socket
Description=Podman API Service
Documentation=man:podman-system-service(1)
Requires=podman.socket
StartLimitIntervalSec=0
''
}
assertFileContent $servicePath/podman.socket \
${
builtins.toFile "podman.socket-expected" ''
[Install]
WantedBy=sockets.target
[Socket]
ListenStream=%t/podman/podman.sock
SocketMode=660
[Unit]
Description=Podman API Socket
Documentation=man:podman-system-service(1)
''
}
'';
}
@@ -1,4 +0,0 @@
{
podman-basic-config = ./basic-config.nix;
podman-docker-alias = ./docker-alias.nix;
}
@@ -1,14 +0,0 @@
{ config, pkgs, lib, ... }:
lib.mkIf config.test.enableBig {
virtualisation.podman = {
enable = true;
enableDockerAlias = true;
enableDockerSocket = true;
};
nmt.script = ''
assertFileIsExecutable home-path/bin/docker
assertFileContains home-path/etc/profile.d/hm-session-vars.sh "DOCKER_HOST"
'';
}