Skip to content

Commit

Permalink
git: removing all warnings about the gpgPath migration
Browse files Browse the repository at this point in the history
It simply cannot be done, if signing continues to be a submodule and
NixOS/nixpkgs#96006 continues to be a problem.
  • Loading branch information
pluiedev committed Jul 18, 2023
1 parent 76204e2 commit c739712
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 45 deletions.
3 changes: 1 addition & 2 deletions format
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#! /usr/bin/env nix-shell
#! nix-shell -i bash -p git gnugrep gnused findutils nixfmt
#1 nix-shell -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/6616de389ed55fba6eeba60377fc04732d5a207c.tar.gz -i bash -p git gnugrep gnused findutils nixfmt
#! nix-shell -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/6616de389ed55fba6eeba60377fc04732d5a207c.tar.gz -i bash -p git gnugrep gnused findutils nixfmt

nixfmt_args=()
files=()
Expand Down
7 changes: 1 addition & 6 deletions modules/programs/git.nix
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ let
in attrsOf supersectionType;

signModule = types.submodule {
imports = [ (mkRenamedOptionModule [ "gpgPath" ] [ "program" ]) ];
options = {
signByDefault = mkOption {
type = types.bool;
Expand Down Expand Up @@ -425,18 +424,14 @@ in {
config = mkIf cfg.enable (mkMerge [
{
home.packages = [ cfg.package ];

assertions = [
(assertAtMostOneIsSet cfg (builtins.map (tool: [ tool "enable" ]) [
"delta"
"diff-so-fancy"
"difftastic"
]))
];
warnings = if (cfg.signing.gpgPath or "") != "" then [''
`programs.git.signing.gpgPath` has been deprecated.
Please use `programs.git.signing.program` instead.
''] else
[ ];

programs.git.iniContent.user = {
name = mkIf (cfg.userName != null) cfg.userName;
Expand Down

This file was deleted.

27 changes: 0 additions & 27 deletions tests/modules/programs/git/git-with-signing-key-id-legacy.nix

This file was deleted.

0 comments on commit c739712

Please sign in to comment.