-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #333198 from isabelroses/forgejo-cli
forgejo-cli: init at 0.1.1
- Loading branch information
Showing
1 changed file
with
62 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
{ | ||
lib, | ||
rustPlatform, | ||
fetchFromGitea, | ||
pkg-config, | ||
libgit2, | ||
oniguruma, | ||
openssl, | ||
zlib, | ||
stdenv, | ||
darwin, | ||
}: | ||
let | ||
version = "0.1.1"; | ||
in | ||
rustPlatform.buildRustPackage { | ||
pname = "forgejo-cli"; | ||
inherit version; | ||
|
||
src = fetchFromGitea { | ||
domain = "codeberg.org"; | ||
owner = "Cyborus"; | ||
repo = "forgejo-cli"; | ||
rev = "v${version}"; | ||
hash = "sha256-367O4SpGA0gWM/IIJjIbCoi4+N/Vl58T5Jw/NVsE+7o="; | ||
}; | ||
|
||
cargoHash = "sha256-F7UBLqMXYS8heJs1mdmiFTHUfgoMKEb+KV4tiDsIRDY="; | ||
|
||
nativeBuildInputs = [ pkg-config ]; | ||
|
||
buildInputs = | ||
[ | ||
libgit2 | ||
oniguruma | ||
openssl | ||
zlib | ||
] | ||
++ lib.optionals stdenv.isDarwin ( | ||
with darwin.apple_sdk.frameworks; | ||
[ | ||
Security | ||
SystemConfiguration | ||
] | ||
); | ||
|
||
env = { | ||
RUSTONIG_SYSTEM_LIBONIG = true; | ||
}; | ||
|
||
meta = { | ||
description = "CLI application for interacting with Forgejo"; | ||
homepage = "https://codeberg.org/Cyborus/forgejo-cli"; | ||
changelog = "https://codeberg.org/Cyborus/forgejo-cli/releases/tag/v${version}"; | ||
license = with lib.licenses; [ | ||
asl20 | ||
mit | ||
]; | ||
maintainers = with lib.maintainers; [ isabelroses ]; | ||
mainProgram = "fj"; | ||
}; | ||
} |