Skip to content

Commit

Permalink
flake: add go overlay for 1.22.3
Browse files Browse the repository at this point in the history
  • Loading branch information
sechmann committed May 16, 2024
1 parent 7a643c1 commit 314b901
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
6 changes: 3 additions & 3 deletions flake.lock

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

15 changes: 13 additions & 2 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,24 @@

# Nixpkgs instantiated for supported system types.
nixpkgsFor = forAllSystems (system: import nixpkgs { inherit system; });

goOverlay = final: prev: {
go = prev.go.overrideAttrs (old: {
version = "1.22.3";

src = prev.fetchurl {
url = "https://go.dev/dl/go1.22.3.src.tar.gz";
hash = "sha256-gGSO80+QMZPXKlnA3/AZ9fmK4MmqE63gsOy/+ZGnb2g=";
};
});
};
in
{
# Provide some binary packages for selected system types.
packages = forAllSystems (
system:
let
pkgs = nixpkgsFor.${system};
pkgs = (nixpkgsFor.${system}.extend goOverlay);
in
{
device-agent = pkgs.buildGoModule {
Expand Down Expand Up @@ -56,7 +67,7 @@
devShells = forAllSystems (
system:
let
pkgs = nixpkgsFor.${system};
pkgs = (nixpkgsFor.${system}.extend goOverlay);
in
{
default = pkgs.mkShell {
Expand Down

0 comments on commit 314b901

Please sign in to comment.