1
0
Fork 0

feat: tmpl

Signed-off-by: jolheiser <john.olheiser@gmail.com>
main
jolheiser 2023-07-05 11:15:58 -05:00
parent efc72954a2
commit fcaba5a3e9
Signed by: jolheiser
GPG Key ID: B853ADA5DA7BBF7A
4 changed files with 31 additions and 19 deletions

View File

@ -14,7 +14,5 @@
modules = import ./modules; # NixOS modules
overlays = import ./overlays; # nixpkgs overlays
example-package = pkgs.callPackage ./pkgs/example-package { };
# some-qt5-package = pkgs.libsForQt5.callPackage ./pkgs/some-qt5-package { };
# ...
tmpl = pkgs.callPackage ./pkgs/tmpl { };
}

View File

@ -1,5 +1,5 @@
{
description = "My personal NUR repository";
description = "jolheiser personal NUR repository";
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
outputs = { self, nixpkgs }:
let
@ -12,11 +12,11 @@
"armv7l-linux"
];
forAllSystems = f: nixpkgs.lib.genAttrs systems (system: f system);
in
{
legacyPackages = forAllSystems (system: import ./default.nix {
pkgs = import nixpkgs { inherit system; };
});
packages = forAllSystems (system: nixpkgs.lib.filterAttrs (_: v: nixpkgs.lib.isDerivation v) self.legacyPackages.${system});
in {
legacyPackages = forAllSystems (system:
import ./default.nix { pkgs = import nixpkgs { inherit system; }; });
packages = forAllSystems (system:
nixpkgs.lib.filterAttrs (_: v: nixpkgs.lib.isDerivation v)
self.legacyPackages.${system});
};
}

View File

@ -1,9 +0,0 @@
{ stdenv }:
stdenv.mkDerivation rec {
name = "example-package-${version}";
version = "1.0";
src = ./.;
buildPhase = "echo echo Hello World > example";
installPhase = "install -Dm755 example $out";
}

View File

@ -0,0 +1,23 @@
{ buildGoModule, fetchFromGitea, lib, ... }:
buildGoModule rec {
pname = "tmpl";
version = "0.3.1";
src = fetchFromGitea {
domain = "git.jojodev.com";
owner = "jolheiser";
repo = "tmpl";
rev = "v${version}";
sha256 = "sha256-2GThTkTSiPv4SiWmRC/acKQ7k5uqrQQRM56eOxWCg7Q=";
};
vendorSha256 = "sha256-PmguDbjTSz0jzj1pwUNZrO1aAFNkWSo/FAef29TjsGI=";
ldflags = [ "-s" "-w" "-X=go.jolheiser.com/tmpl/cmd.Version=${version}" ];
meta = with lib; {
description = "Template automation for bootstrapping projects";
homepage = "https://git.jojodev.com/jolheiser/tmpl";
license = licenses.mit;
};
}