rectangle: 0.85 -> 0.86, refactor (#380096)

This commit is contained in:
Weijia Wang 2025-02-07 15:21:32 +01:00 committed by GitHub
commit d0ba0e3eb5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3,16 +3,16 @@
stdenvNoCC, stdenvNoCC,
fetchurl, fetchurl,
undmg, undmg,
gitUpdater, nix-update-script,
}: }:
stdenvNoCC.mkDerivation rec { stdenvNoCC.mkDerivation (finalAttrs: {
pname = "rectangle"; pname = "rectangle";
version = "0.85"; version = "0.86";
src = fetchurl { src = fetchurl {
url = "https://github.com/rxhanson/Rectangle/releases/download/v${version}/Rectangle${version}.dmg"; url = "https://github.com/rxhanson/Rectangle/releases/download/v${finalAttrs.version}/Rectangle${finalAttrs.version}.dmg";
hash = "sha256-TBUC5z2BZMt0eb9NAD3/y9y23iRzs7YRJSfyb3QN1Mc="; hash = "sha256-UUL5xaZn+NDQ5VvlVH9ROek5AFQ5fyZLGubLc/qQqcI=";
}; };
sourceRoot = "."; sourceRoot = ".";
@ -22,26 +22,23 @@ stdenvNoCC.mkDerivation rec {
installPhase = '' installPhase = ''
runHook preInstall runHook preInstall
mkdir -p $out/Applications mkdir -p "$out/Applications"
mv Rectangle.app $out/Applications mv Rectangle.app "$out/Applications"
runHook postInstall runHook postInstall
''; '';
passthru.updateScript = gitUpdater { passthru.updateScript = nix-update-script { };
url = "https://github.com/rxhanson/Rectangle";
rev-prefix = "v";
};
meta = with lib; { meta = {
description = "Move and resize windows in macOS using keyboard shortcuts or snap areas"; description = "Move and resize windows in macOS using keyboard shortcuts or snap areas";
homepage = "https://rectangleapp.com/"; homepage = "https://rectangleapp.com/";
sourceProvenance = with sourceTypes; [ binaryNativeCode ]; license = lib.licenses.mit;
platforms = platforms.darwin; maintainers = with lib.maintainers; [
maintainers = with maintainers; [
Intuinewin Intuinewin
wegank wegank
]; ];
license = licenses.mit; platforms = lib.platforms.darwin;
sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];
}; };
} })