diff --git a/pkgs/applications/version-management/gql/default.nix b/pkgs/applications/version-management/gql/default.nix new file mode 100644 index 000000000000..c0c9f133e0a6 --- /dev/null +++ b/pkgs/applications/version-management/gql/default.nix @@ -0,0 +1,53 @@ +{ lib +, rustPlatform +, fetchFromGitHub +, pkg-config +, libgit2 +, openssl +, zlib +, stdenv +, darwin +}: + +rustPlatform.buildRustPackage rec { + pname = "gql"; + version = "0.1.0"; + + src = fetchFromGitHub { + owner = "AmrDeveloper"; + repo = "GQL"; + rev = version; + hash = "sha256-UEfluWgoSuPnHGsoPcVLuAqmJsqCJL2B29UsQeZctuE="; + }; + + cargoHash = "sha256-y49pnx1OkUu7yKnwTGpPGv3ULUPpj/Z4bOPVIO3nS0E="; + + nativeBuildInputs = [ + pkg-config + ]; + + buildInputs = [ + libgit2 + openssl + zlib + ] ++ lib.optionals stdenv.isDarwin [ + darwin.apple_sdk.frameworks.Security + ]; + + env = { + OPENSSL_NO_VENDOR = true; + }; + + # Cargo.lock is outdated + preConfigure = '' + cargo metadata --offline + ''; + + meta = with lib; { + description = "A SQL like query language to perform queries on .git files"; + homepage = "https://github.com/AmrDeveloper/GQL"; + changelog = "https://github.com/AmrDeveloper/GQL/releases/tag/${src.rev}"; + license = licenses.mit; + maintainers = with maintainers; [ figsoda ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 4dd0082b31c4..367f9db65284 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8274,6 +8274,8 @@ with pkgs; gptfdisk = callPackage ../tools/system/gptfdisk { }; + gql = callPackage ../applications/version-management/gql { }; + grafterm = callPackage ../tools/misc/grafterm { }; gradience = callPackage ../applications/misc/gradience { };