Merge pull request #247548 from figsoda/reshape

reshape: refactor
This commit is contained in:
Weijia Wang 2023-08-06 21:20:54 +02:00 committed by GitHub
commit d642995097
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1098 deletions

File diff suppressed because it is too large Load Diff

View File

@ -1,9 +1,6 @@
{ lib
, stdenv
, fetchFromGitHub
, rustPlatform
, fetchpatch
, git
, fetchCrate
, postgresqlTestHook
, postgresql
}:
@ -12,13 +9,13 @@ rustPlatform.buildRustPackage rec {
pname = "reshape";
version = "0.6.1";
src = fetchFromGitHub {
owner = "fabianlindfors";
repo = pname;
rev = "v${version}";
hash = "sha256-iX8qhDk0PP0AB3bJ6ck8AZ9SCErFH416ggAkgK8O900=";
src = fetchCrate {
inherit pname version;
hash = "sha256-pTEOVDeCE69dn005nj1ULGKjguCtC1uReI/l3WEz4+w=";
};
cargoHash = "sha256-KYU5drTVHdWmlE01Fq1TxJZTe87yBpDKIGm4P+RRCGw=";
nativeCheckInputs = [
postgresqlTestHook
postgresql
@ -32,18 +29,10 @@ rustPlatform.buildRustPackage rec {
postgresqlTestUserOptions = "LOGIN SUPERUSER";
# upstream doesn't ship a Cargo.lock, is generated by the update script
postPatch = ''
cp ${./Cargo.lock} Cargo.lock
'';
cargoLock.lockFile = ./Cargo.lock;
cargoHash = "sha256-UL/vP8055JRbbf5bqf0V3wGh+iF9ztVhyoMrtNs/c+4=";
meta = with lib; {
description = "An easy-to-use, zero-downtime schema migration tool for Postgres";
homepage = "https://github.com/fabianlindfors/reshape";
changelog = "https://github.com/fabianlindfors/reshape/releases/tag/v${version}";
license = licenses.mit;
maintainers = with maintainers; [ ilyakooo0 ];
};