Changelog: https://github.com/sbdchd/squawk/releases/tag/v0.24.0 Diff: https://github.com/sbdchd/squawk/compare/v0.23.0...v0.24.0
50 lines
1 KiB
Nix
50 lines
1 KiB
Nix
{ darwin
|
|
, fetchFromGitHub
|
|
, lib
|
|
, libiconv
|
|
, libpg_query
|
|
, openssl
|
|
, pkg-config
|
|
, rustPlatform
|
|
, stdenv
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "squawk";
|
|
version = "0.24.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "sbdchd";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
hash = "sha256-eic5j/mD4PBCMcATTSTJSKazZFJOxQuW7NyiYPjKCcM=";
|
|
};
|
|
|
|
cargoHash = "sha256-kzb00W9IlshhiV+vUIOlO6BnprHr2XPf8P207WYFP5I=";
|
|
|
|
nativeBuildInputs = [
|
|
pkg-config
|
|
rustPlatform.bindgenHook
|
|
];
|
|
|
|
buildInputs = lib.optionals (!stdenv.isDarwin) [
|
|
libiconv
|
|
openssl
|
|
] ++ lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [
|
|
CoreFoundation
|
|
Security
|
|
]);
|
|
|
|
OPENSSL_NO_VENDOR = 1;
|
|
|
|
LIBPG_QUERY_PATH = libpg_query;
|
|
|
|
meta = with lib; {
|
|
description = "Linter for PostgreSQL, focused on migrations";
|
|
homepage = "https://squawkhq.com/";
|
|
changelog = "https://github.com/sbdchd/squawk/blob/v${version}/CHANGELOG.md";
|
|
license = licenses.gpl3Only;
|
|
maintainers = with lib.maintainers; [ andrewsmith ];
|
|
};
|
|
}
|