1
0
mirror of https://github.com/nix-community/home-manager synced 2024-07-01 02:48:30 +02:00
Commit Graph

1595 Commits

Author SHA1 Message Date
Sumner Evans
f911ebbec9
lib.booleans: add yesNo function (#2818)
Closes #2772
2022-04-07 22:36:13 -06:00
Robert Helgesson
47b3719f51
taskwarrior: minor script cleanup 2022-04-07 23:35:55 +02:00
Alex Miranda
8a046f36eb
Translate using Weblate (Portuguese (Brazil))
Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (Portuguese (Brazil))

Currently translated at 100.0% (32 of 32 strings)

Co-authored-by: Alex Miranda <alexmirandamoraes@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/home-manager/cli/pt_BR/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/pt_BR/
Translation: Home Manager/Home Manager CLI
Translation: Home Manager/Home Manager Modules
2022-04-07 19:36:38 +02:00
Daniel Nagy
3071ea205d
starship: skip one program invocation on each shell init (#2862)
The code that is being evaled without the `--print-full-init` flag is
this:

```sh
__main() {
    local major="${BASH_VERSINFO[0]}"
    local minor="${BASH_VERSINFO[1]}"

    if ((major > 4)) || { ((major == 4)) && ((minor >= 1)); }; then
        source <(/nix/store/...-starship-1.3.0/bin/starship init bash --print-full-init)
    else
        source /dev/stdin <<<"$(/nix/store/...-starship-1.3.0/bin/starship init bash --print-full-init)"
    fi
}
__main
unset -f __main
```

This code checks for bash version >= 4.1 , which has been released in
2009. Since this version is widely unavailable in nixpkgs, we can skip
one program invocation and directly call `starship init bash
--print-full-init`.
2022-04-07 13:36:34 -04:00
x10an14
e361373b5f
taskwarrior: make .taskrc writable (#2761)
This is achieved by generating the Home Manager configuration
file as `~/.config/task/home-manager-taskrc`, and including that
file into ~/.config/task/taskrc.

Fixes #2360

Co-authored-by: mainrs <5113257+mainrs@users.noreply.github.com>
Co-authored-by: Nicolas Berbiche <nicolas@normie.dev>
2022-04-07 13:29:53 -04:00
André Silva
66ffa7a0a6
systemd: fix creation of user service unit files (#2867)
* systemd: fix creation of user service unit files

* helix: fix failing test due to file output format change

Co-authored-by: Nicolas Berbiche <nicolas@normie.dev>
2022-04-07 02:38:20 -04:00
Ilan Joselevich
07b941f0c4
mpd-discord-rpc: init service (#2728) 2022-04-04 23:48:13 -04:00
Naïm Favier
399a3dfeaf
gpg: create homedir with 700 permissions (#2823)
It can happen in some cases that home-manager first runs before gpg
creates its homedir, and it creates it with 755 permissions which the
user then needs to change by hand.

Do this in the module instead: before linking files, make sure the
homedir exists, and if it doesn't, create it with the right permissions.
2022-04-04 23:40:15 -04:00
Radosław Szamszur
a985e711e8
screen-locker: Add option to configure x screensaver cycle (#2853)
Some screen lockers which will be used with xss-lock might require
to set x screensaver timeout with cycle.
2022-04-04 23:32:27 -04:00
ilkecan
3549f5d0f5
xdg-user-dirs: allow paths and define sessionVariables (#2757)
Changed option types to `either str path` to allow using path values.

The related session variable is defined for the default and the extra
user directories now.
2022-04-04 23:32:03 -04:00
Roch D'Amour
0382c5f75e
git: Add option to use difftastic as diff tool (#2850)
Difftastic is a syntax-aware diff tool which can be used with git.
2022-04-04 08:53:29 -06:00
Mario Rodas
9580f6c42a
zellij: add configuration for darwin
Zellij uses a different path to hold its configuration on Darwin.
2022-03-30 23:56:01 +02:00
Naïm Favier
8db712a6a2
types: fix dagOf behaviour with mkIf
This makes definitions like

    home.activation.foo = mkIf false "bar"

work, where previously they would complain about
`home.activation.foobar.data` being used but not defined.

The crucial part is that we don't call `convertAllToDags` in
`dagOf.merge`, because we need to process `mkIf`/`mkMerge` properties
first. So we let `attrEquivalent.merge` do its job normally, but give
it a type `dagEntryOf` that does the conversion.

Ideally this shouldn't require so much boilerplate; I'd like to
implement something like

    types.changeInto dagContentType elemType dagEntryAnywhere

in Nixpkgs.
2022-03-30 23:29:09 +02:00
Oğuz Ersen
f5a44afa19
Translate using Weblate (Turkish)
Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (Turkish)

Currently translated at 100.0% (32 of 32 strings)

Co-authored-by: Oğuz Ersen <oguz@ersen.moe>
Translate-URL: https://hosted.weblate.org/projects/home-manager/cli/tr/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/tr/
Translation: Home Manager/Home Manager CLI
Translation: Home Manager/Home Manager Modules
2022-03-27 09:44:00 +02:00
Robert Helgesson
80583677e7
Translate using Weblate (Japanese)
Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (Korean)

Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (German)

Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (Spanish)

Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (Russian)

Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (French)

Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (Norwegian Bokmål)

Currently translated at 85.7% (12 of 14 strings)

Translate using Weblate (Swedish)

Currently translated at 100.0% (14 of 14 strings)

Co-authored-by: Robert Helgesson <robert@rycee.net>
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/de/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/es/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/fr/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/ja/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/ko/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/nb_NO/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/ru/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/sv/
Translation: Home Manager/Home Manager Modules
2022-03-27 09:44:00 +02:00
Hosted Weblate
c607ae8671
Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Update translation files

Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Co-authored-by: Hosted Weblate <hosted@weblate.org>
Translate-URL: https://hosted.weblate.org/projects/home-manager/cli/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/
Translation: Home Manager/Home Manager CLI
Translation: Home Manager/Home Manager Modules
2022-03-27 09:44:00 +02:00
Yevhen Shymotiuk
d123fca83c
browserpass: add brave support 2022-03-27 01:12:50 +01:00
Moises Nessim
2f58d0a3de
nix: add support for nix profile
PR #2833

Co-authored-by: David Arnold <dar@xoe.solutions>
Co-authored-by: Florian Franzen <Florian.Franzen@gmail.com>
2022-03-26 15:11:28 +01:00
Robert Helgesson
171702dd88
files: avoid cleanup if old home-files is missing 2022-03-26 15:05:43 +01:00
Farseen
8afee75d0d
dconf: note that system dconf must be enabled
Before enabling dconf in Home Manager, dconf must be enabled in system
config.

Otherwise it will fail like this:

```
$ home-manager switch
Starting Home Manager activation
Activating checkFilesChanged
Activating checkLinkTargets
Activating writeBoundary
Activating installPackages
replacing old 'home-manager-path'
installing 'home-manager-path'
Activating dconfSettings
error: GDBus.Error:org.freedesktop.systemd1.NoSuchUnit: Unit dconf.service not found.
```
2022-03-26 09:33:10 +01:00
Naïm Favier
e2ebc3a3af
picom: use types.lines for extraOptions 2022-03-23 23:10:24 +01:00
Naïm Favier
0cf9dadf5b
irssi: use types.lines for extraConfig 2022-03-23 23:10:23 +01:00
Manu [tennox]
6c730bc054
Translate using Weblate (German)
Currently translated at 100.0% (14 of 14 strings)

Translate using Weblate (German)

Currently translated at 100.0% (32 of 32 strings)

Co-authored-by: Manu [tennox] <tennox@posteo.de>
Translate-URL: https://hosted.weblate.org/projects/home-manager/cli/de/
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/de/
Translation: Home Manager/Home Manager CLI
Translation: Home Manager/Home Manager Modules
2022-03-23 19:56:54 +01:00
stephaneyfx
48a1584d8b
i3-sway: Empty set argument was passed to wrong function (#2819)
This would give the error "attempt to call something which is not a
function but a list" given that `optionals a b` returns a list. `indent`
is the one taking this empty set as second argument.
2022-03-22 14:04:28 -06:00
Basti
80b4360678
i3/sway: improve i3.nix to handle options as list like in sway, adjusted functions for less new-lines (#2314)
* i3/sway: Improve code to generate config to avoid new-line issues on code/config changes

* Maintainer: Add SebTM as maintainer
2022-03-21 16:52:57 -06:00
Nazarii Bardiuk
bbc5e0c1e1
tmux: fix broken vi bindings (#2817)
Keybindings have wrong order of arguments: the -N flag should go before
the binding key
2022-03-21 16:25:36 -06:00
polykernel
835797f3a4
xsession.pointerCursor: escape special characters in the cursor path (#2805)
- Escape special character in the cursor name and default cursor file name
  in the cursor path for the xsetroot command.
2022-03-20 18:12:03 -06:00
polykernel
46dc2e5d9f
gtk: fix missing newline in formatted config (#2809)
The conversion from `concatMapStrings` to `concatStringsSep` introduced in https://github.com/nix-community/home-manager/pull/2481
creates an unintended behavior change where the formatted config does not end in a newline.[1]
This is problematic for manipulation at the Nix level. In particular, this cause a regression in
the generation of gtk2 settings due to concatenated of the formatted config and `gtk2.extraConfig`
without a newline in between.

This commit restores `concatMapStrings` to match the previous behavior and adds a newline to
the final string for the generated gtk2 config. The test case for gtk2-basic-config
was also updated to check behavior at concatenation boundaries.

[1] - https://github.com/nix-community/home-manager/pull/2481#discussion_r830648706
2022-03-20 16:22:56 -04:00
Naïm Favier
57476b5d28
xcursor: remove warning and use mkDefault for GTK options (#2808) 2022-03-20 13:32:34 -04:00
Leon Vack
e96fc6d8f9
tmux: add notes to existing keybindings (#2540) (#2742)
Adds notes to the keybindings created in the tmux config making them
show up in C-b ? and tmux list-keys -N

Fixes #2540
2022-03-19 19:12:21 -04:00
mihnea-s
7cf15b19a9
vscode: add user tasks (#2804) 2022-03-18 18:54:24 -04:00
Naïm Favier
e2a85ac43f
bspwm: add alwaysResetDesktops (#2785)
If set to true, desktops configured in `monitors` will be reset every time
the config is run.

If set to false, desktops will only be configured the first time the config is run.
This is useful if you want to dynamically add desktops and you don't want them
to be destroyed if you re-run `bspwmrc`.
2022-03-17 22:56:56 -04:00
polykernel
32e433d07d
nix: add structural settings (#2718)
Nix permits user level configurations through ~/.config/nix/nix.conf that allow
customization of system-wide settings and behavior. This is beneficial in chroot
environments and for per-user configurations. System level Nix configurations in the
form of /etc/nix/nix.conf can be specified declaratively via the NixOS nix module but as
of currently no counter part exists in home-manager.

This PR is a port of the RFC42 implementation for the NixOS nix module[1]
to home-manager. Non-applicable options have been excluded and the config generation
backends have been tweaked to the backends offered by home-manager. A notable change
from the NixOS module is a mandatory option to specify the Nix binary corresponding
to the version "nix.conf" should be generated against. This is necessary because
the validation phase is dependent on the `nix show-config` subcommand on the host platform.
While it is possible to avoid validation entirely, the lack of type checking was deemed too significant.
In NixOs, the version information can be retrieved from the `package` option itself which
declares the Nix binary system-wide. However in home-manager, there is no pure way to
detect the system Nix version and what state version the "nix.conf" should be generated
against. Thus an option is used to overcome this limitation by forcing the user to
specify the Nix package. Note this interaction can still be automated by forwarding
the system-wide Nix package to the home-manager module if needed.

Three unit tests were added to test the module behavior for the empty settings, the example
settings and the example registry configurations respectively.

[1] - NixOS/nixpkgs#139075
2022-03-17 22:47:32 -04:00
Sumner Evans
590da80ceb
neovim/coc: fix loading CoC plugin (#2801)
Specifically, refactored all places that use cfg.plugins to use a new
combined list that includes CoC if it's enabled.
2022-03-17 20:43:03 -06:00
Naïm Favier
a4b0a3faa4
xdg: add XDG_*_HOME variables to systemd.user.sessionVariables (#2790)
Make sure those variables are set in systemd user services.
This mirrors the situation for `XDG_*_DIRS` variables.
2022-03-17 22:22:53 -04:00
polykernel
e01facc340
gtk: add cursor theme configuration (#2481)
* gtk: add cursor theme configuration

- Added the `cursorTheme` under the gtk module.
- Added tests for the gtk3 settings file generation, and renamed
  the gtk2 unit test expected file for clarity.
- Added guard against generating a blank `gtk.css` when `cfg.extraCss`
  is empty.
- Replaced `concatMapStrings` calls with `concatStringsSep`. The library function
  `concatMapStrings` generates an intemediate list which is then passed to
  `concatStringsSep`, As we are not performing other transformation except
  the addition of newlines, a direct call to `concatStringsSep` is sufficient.
- Updated description of examples to be more general "~/.config" -> "$XDG_CONFIG_HOME".
- Update helper functions `toGtk3Ini` and `formatGtk2Option` to use the library
  function `boolToString` and escape the separator in the key name.

* xcursor: delegate GTK cursor settings to gtk.cursorTheme

- Added deprecation warning for GTK settings in the `xsession.cursorTheme` module.
- Modified config section to use `gtk.cursorTheme` for GTK cursor settings.
2022-03-17 15:30:48 -04:00
Kylie McClain
970b57fd3c
autorandr: add filter option (#2795)
xrandr's filter option is useful for enabling integer scaling on
displays that don't have support for it at a graphics card level.
2022-03-17 13:45:04 +01:00
NomisIV
472e67d1bb
himalaya: add support for account.folders
Add support for `account.folders.(inbox|sent|draft)` in the himalaya
account configuration.

PR #2747
2022-03-13 23:20:41 +01:00
iosmanthus
8bdfa41b4e
fusuma: add module
Fusuma is a tool supports multitouch gestures with libinput driver on
Linux.
2022-03-13 22:17:55 +01:00
Karl Hallsby
da92196a95
mu: allow aliases to be used by mu configuration file
This has no effect if the user does not have any aliases defined for
any accounts.

This will also only add `--my-address=` to only accounts that are
enabled to be tracked by mu.
2022-03-13 20:27:35 +01:00
ReplayCoding
5d4327cff4
irssi: fix syntax error when no channels are specified 2022-03-13 13:33:09 +01:00
Loïc Reynier
afe96e7433
pubs: add module
Note, the pubs configuration file uses ConfigObj syntax, which is
similar to the INI files syntax but with extra functionalities like
nested sections. This prevents it from using Nix's INI format
generator. Here is an example of pubs configuration that cannot be
generated using Nix's INI format generator:

    [plugins]

    [[git]]
    manual=False

For this reason, we opted for a stringly-typed configuration since the
use of a structured `settings` option would require a custom parser.
2022-03-06 10:40:28 +01:00
Doğu Us
abd221c4b3
Translate using Weblate (Turkish)
Currently translated at 35.7% (5 of 14 strings)

Co-authored-by: Doğu Us <usdogu@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/tr/
Translation: Home Manager/Home Manager Modules
2022-03-06 10:08:57 +01:00
Anon Ymous
4e6856397e
Translate using Weblate (Polish)
Currently translated at 64.2% (9 of 14 strings)

Co-authored-by: Anon Ymous <mivon27841@shackvine.com>
Translate-URL: https://hosted.weblate.org/projects/home-manager/modules/pl/
Translation: Home Manager/Home Manager Modules
2022-03-06 10:08:57 +01:00
maximsmol
87beebc7a2
just: add module 2022-03-06 09:50:52 +01:00
Yt
d119cea376
i3status-rust: change default to newer version (#2774) 2022-03-03 22:32:59 -05:00
Sebastian Sellmeier
e58a7cb13d
xdg-desktop-entries: adjust to API changes
The `makeDesktopItem` function changed in a backwards incompatible way
in

    0c713dbed4

This commit updates the module accordingly.

Fixes #2767
2022-03-04 01:08:00 +01:00
sudosubin
ea85f4b1fd
launchd: fix multiple agents 2022-02-27 14:58:54 +01:00
Robert Helgesson
2499b91692
treewide: apply nixfmt to a few more files 2022-02-27 02:19:44 +01:00
kmaasrud
1d90b6065a
tiny: add module (#2735)
Added module for tiny, a TUI IRC client written in Rust. Thanks to @ratsclub for helping me write my first Nix module!
2022-02-26 17:42:01 -05:00