Skip to content

Commit

Permalink
aliae: init at 0.22.1
Browse files Browse the repository at this point in the history
Co-authored-by: Nikolay Korotkiy <sikmir@disroot.org>
Co-authored-by: éclairevoyant <848000+eclairevoyant@users.noreply.github.com>
  • Loading branch information
3 people authored Sep 5, 2024
1 parent e678a65 commit 864bf23
Showing 1 changed file with 57 additions and 0 deletions.
57 changes: 57 additions & 0 deletions pkgs/by-name/al/aliae/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
{
lib,
stdenv,
buildGoModule,
fetchFromGitHub,
installShellFiles,
}:

buildGoModule rec {
pname = "aliae";
version = "0.22.1";

src = fetchFromGitHub {
owner = "jandedobbeleer";
repo = "aliae";
rev = "refs/tags/v${version}";
hash = "sha256-slixB7mzEdX3ecgbM6tO9IzVH+1w6DwssD1X3MrwAHw=";
};

vendorHash = "sha256-U0Mt2U8WxDFDadIxASz609tUtiF4tETobAmYrk29Lh0=";

sourceRoot = "${src.name}/src";

nativeBuildInputs = [ installShellFiles ];

ldflags = [
"-s"
"-w"
"-X main.Version=${version}"
];

tags = [
"netgo"
"osusergo"
"static_build"
];

postInstall =
''
mv $out/bin/{src,aliae}
''
+ lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
installShellCompletion --cmd aliae \
--bash <($out/bin/aliae completion bash) \
--fish <($out/bin/aliae completion fish) \
--zsh <($out/bin/aliae completion zsh)
'';

meta = {
description = "Cross shell and platform alias management";
mainProgram = "aliae";
homepage = "https://aliae.dev";
changelog = "https://github.com/JanDeDobbeleer/aliae/releases/tag/v${version}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ vedantmgoyal9 ];
};
}

0 comments on commit 864bf23

Please sign in to comment.