Skip to content

Commit

Permalink
nitrokey-firmware: migrate
Browse files Browse the repository at this point in the history
Co-authored-by: Auguste Baum <auguste.apple@gmail.com>
Co-authored-by: Shahar "Dawn" Or <mightyiampresence@gmail.com>
  • Loading branch information
3 people committed Nov 28, 2023
1 parent c95484d commit 8ec63d0
Show file tree
Hide file tree
Showing 14 changed files with 48 additions and 191 deletions.
24 changes: 24 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 8 additions & 3 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,19 @@
inputs.treefmt-nix.inputs.nixpkgs.follows = "nixpkgs";
inputs.sops-nix.url = "github:Mic92/sops-nix";
inputs.sops-nix.inputs.nixpkgs.follows = "nixpkgs";
inputs.rust-overlay.url = "github:oxalica/rust-overlay";
inputs.rust-overlay.inputs.flake-utils.follows = "flake-utils";
inputs.rust-overlay.inputs.nixpkgs.follows = "nixpkgs";

outputs = {
self,
nixpkgs,
flake-utils,
treefmt-nix,
sops-nix,
rust-overlay,
...
}:
} @ inputs:
with builtins; let
inherit
(nixpkgs.lib)
Expand Down Expand Up @@ -54,15 +58,16 @@
};
explicitPkgs = import ./pkgs {
inherit (pkgs) lib;
inherit callPackage;
inherit callPackage inputs;
};
allPackages = pkgsByName // explicitPkgs;
in
allPackages;

importNixpkgs = system: overlays:
import nixpkgs {
inherit system overlays;
inherit system;
overlays = overlays ++ [rust-overlay.overlays.default];
};

importNixosConfigurations = import ./configs/all-configurations.nix;
Expand Down
File renamed without changes.
16 changes: 16 additions & 0 deletions pkgs/default.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,19 @@
{
lib,
callPackage,
inputs,
}: let
linuxSystem = "x86_64-linux";
pkgsArm = import inputs.nixpkgs {
system = linuxSystem;
crossSystem.config = "arm-none-eabi";
};
pkgsAvr = import inputs.nixpkgs {
system = linuxSystem;
crossSystem.config = "avr";
};
stdenvArm = pkgsArm.stdenv;
stdenvAvr = pkgsAvr.stdenv;
self = rec {
# LiberaForms is intentionally disabled.
# Refer to <https://github.com/ngi-nix/ngipkgs/issues/40>.
Expand All @@ -28,6 +40,10 @@
pretalx-venueless
pretalx-public-voting
;
nitrokey-3 = callPackage ./nitrokey-firmware/nitrokey-3 {};
nitrokey-pro = callPackage ./nitrokey-firmware/nitrokey-pro.nix {inherit stdenvArm;};
nitrokey-start = callPackage ./nitrokey-firmware/nitrokey-start.nix {gcc11StdenvArm = pkgsArm.gcc11Stdenv;};
nitrokey-trng-rs232 = callPackage ./nitrokey-firmware/nitrokey-trng-rs232.nix {inherit stdenvAvr;};
};
in
self
1 change: 0 additions & 1 deletion pkgs/nitrokey-firmware/.gitignore

This file was deleted.

21 changes: 0 additions & 21 deletions pkgs/nitrokey-firmware/LICENSE

This file was deleted.

42 changes: 0 additions & 42 deletions pkgs/nitrokey-firmware/README.md

This file was deleted.

82 changes: 0 additions & 82 deletions pkgs/nitrokey-firmware/flake.lock

This file was deleted.

42 changes: 0 additions & 42 deletions pkgs/nitrokey-firmware/flake.nix

This file was deleted.

File renamed without changes.
File renamed without changes.

0 comments on commit 8ec63d0

Please sign in to comment.