mirror of
https://github.com/drduh/YubiKey-Guide.git
synced 2025-04-26 20:13:38 +02:00
Merge pull request #490 from drduh/wip-20apr25
update nix readme reference to fix #486
This commit is contained in:
commit
3912fc0f20
1 changed files with 5 additions and 8 deletions
|
@ -3,14 +3,11 @@
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
|
||||||
drduhConfig.url = "github:drduh/config";
|
|
||||||
drduhConfig.flake = false;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = {
|
outputs = {
|
||||||
self,
|
self,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
drduhConfig,
|
|
||||||
}: let
|
}: let
|
||||||
mkSystem = system:
|
mkSystem = system:
|
||||||
nixpkgs.lib.nixosSystem {
|
nixpkgs.lib.nixosSystem {
|
||||||
|
@ -26,7 +23,7 @@
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
gpgAgentConf = pkgs.runCommand "gpg-agent.conf" {} ''
|
gpgAgentConf = pkgs.runCommand "gpg-agent.conf" {} ''
|
||||||
sed '/pinentry-program/d' ${drduhConfig}/gpg-agent.conf > $out
|
sed '/pinentry-program/d' ${self}/../config/gpg-agent.conf > $out
|
||||||
echo "pinentry-program ${pkgs.pinentry.curses}/bin/pinentry" >> $out
|
echo "pinentry-program ${pkgs.pinentry.curses}/bin/pinentry" >> $out
|
||||||
'';
|
'';
|
||||||
dicewareAddress = "localhost";
|
dicewareAddress = "localhost";
|
||||||
|
@ -36,14 +33,14 @@
|
||||||
if [ -z "$viewer" ]; then
|
if [ -z "$viewer" ]; then
|
||||||
viewer="${pkgs.glow}/bin/glow -p"
|
viewer="${pkgs.glow}/bin/glow -p"
|
||||||
fi
|
fi
|
||||||
exec $viewer "${self}/README.md"
|
exec $viewer "${self}/../README.md"
|
||||||
'';
|
'';
|
||||||
shortcut = pkgs.makeDesktopItem {
|
shortcut = pkgs.makeDesktopItem {
|
||||||
name = "yubikey-guide";
|
name = "yubikey-guide";
|
||||||
icon = "${pkgs.yubikey-manager-qt}/share/icons/hicolor/128x128/apps/ykman.png";
|
icon = "${pkgs.yubikey-manager-qt}/share/icons/hicolor/128x128/apps/ykman.png";
|
||||||
desktopName = "drduh's YubiKey Guide";
|
desktopName = "YubiKey Guide";
|
||||||
genericName = "Guide to using YubiKey for GnuPG and SSH";
|
genericName = "Guide to using YubiKey for GnuPG and SSH";
|
||||||
comment = "Open the guide in a reader program";
|
comment = "Open YubiKey Guide in a reader program";
|
||||||
categories = ["Documentation"];
|
categories = ["Documentation"];
|
||||||
exec = "${viewYubikeyGuide}/bin/view-yubikey-guide";
|
exec = "${viewYubikeyGuide}/bin/view-yubikey-guide";
|
||||||
};
|
};
|
||||||
|
@ -247,7 +244,7 @@
|
||||||
echo "Creating \$GNUPGHOME…"
|
echo "Creating \$GNUPGHOME…"
|
||||||
install --verbose -m=0700 --directory="$GNUPGHOME"
|
install --verbose -m=0700 --directory="$GNUPGHOME"
|
||||||
fi
|
fi
|
||||||
[ ! -f "$GNUPGHOME/gpg.conf" ] && cp --verbose "${drduhConfig}/gpg.conf" "$GNUPGHOME/gpg.conf"
|
[ ! -f "$GNUPGHOME/gpg.conf" ] && cp --verbose "${self}/../config/gpg.conf" "$GNUPGHOME/gpg.conf"
|
||||||
[ ! -f "$GNUPGHOME/gpg-agent.conf" ] && cp --verbose ${gpgAgentConf} "$GNUPGHOME/gpg-agent.conf"
|
[ ! -f "$GNUPGHOME/gpg-agent.conf" ] && cp --verbose ${gpgAgentConf} "$GNUPGHOME/gpg-agent.conf"
|
||||||
echo "\$GNUPGHOME is \"$GNUPGHOME\""
|
echo "\$GNUPGHOME is \"$GNUPGHOME\""
|
||||||
'';
|
'';
|
||||||
|
|
Loading…
Add table
Reference in a new issue