Skip to content

Commit

Permalink
kryptor: .NET 6 -> 8 (#363629)
Browse files Browse the repository at this point in the history
  • Loading branch information
corngood authored Dec 10, 2024
2 parents 0101e48 + e7b93f4 commit 2eccf31
Show file tree
Hide file tree
Showing 3 changed files with 57 additions and 17 deletions.
38 changes: 30 additions & 8 deletions pkgs/by-name/kr/kryptor/deps.nix

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

30 changes: 21 additions & 9 deletions pkgs/by-name/kr/kryptor/package.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{ lib
, buildDotnetModule
, fetchFromGitHub
, dotnetCorePackages
{
lib,
buildDotnetModule,
fetchFromGitHub,
dotnetCorePackages,
versionCheckHook,
}:

buildDotnetModule rec {
Expand All @@ -11,25 +13,35 @@ buildDotnetModule rec {
src = fetchFromGitHub {
owner = "samuel-lucas6";
repo = "Kryptor";
rev = "v${version}";
tag = "v${version}";
hash = "sha256-BxUmDzmfvRelQDHb5uLcQ2YPL7ClxZNFGm/gQoDK8t8=";
};

dotnet-sdk = dotnetCorePackages.sdk_6_0;
dotnet-sdk = dotnetCorePackages.sdk_8_0;
projectFile = "src/Kryptor.sln";
nugetDeps = ./deps.nix;

executables = ["kryptor"];
executables = [ "kryptor" ];

dotnetFlags = ["-p:IncludeNativeLibrariesForSelfExtract=true"];
dotnetFlags = [ "-p:TargetFramework=net8.0" ];

doInstallCheck = true;
nativeInstallCheckInputs = [ versionCheckHook ];

passthru = {
updateScript = ./update.sh;
};

meta = {
changelog = "https://github.com/samuel-lucas6/Kryptor/releases/tag/v${version}";
description = "Simple, modern, and secure encryption and signing tool that aims to be a better version of age and Minisign";
homepage = "https://github.com/samuel-lucas6/Kryptor";
license = lib.licenses.gpl3Only;
mainProgram = "kryptor";
maintainers = with lib.maintainers; [ arthsmn ];
maintainers = with lib.maintainers; [
arthsmn
gepbird
];
platforms = lib.platforms.all;
};
}
6 changes: 6 additions & 0 deletions pkgs/by-name/kr/kryptor/update.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/env nix-shell
#!nix-shell --pure -i bash -p bash nix nix-update git cacert
set -euo pipefail

nix-update kryptor
$(nix-build . -A kryptor.fetch-deps --no-out-link)

0 comments on commit 2eccf31

Please sign in to comment.