Merge pull request #201375 from WolfangAukang/pocket-casts-0.6

pocket-casts: 0.5.0 -> 0.6.0
This commit is contained in:
ajs124 2022-11-18 03:20:25 +01:00 committed by GitHub
commit d772d0fff2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 17 deletions

View File

@ -3,11 +3,11 @@
stdenv.mkDerivation rec {
pname = "pocket-casts";
version = "0.5.0";
version = "0.6.0";
src = fetchurl {
url = "https://github.com/felicianotech/pocket-casts-desktop-app/releases/download/v${version}/${pname}_${version}_amd64.deb";
sha256 = "sha256-frBtIxwRO/6k6j0itqN10t+9AyNadqXm8vC1YP960ts=";
sha256 = "sha256-nHdF9RDOkM9HwwmK/axiIPM4nmKrWp/FHNC/EI1vTTc=";
};
nativeBuildInputs = [
@ -18,31 +18,32 @@ stdenv.mkDerivation rec {
buildInputs = [ alsa-lib gtk3 libXScrnSaver libXtst mesa nss ];
dontBuild = true;
dontConfigure = true;
unpackPhase = ''
dpkg-deb -x ${src} ./
unpackCmd = ''
# If unpacking using -x option, there is a permission error
dpkg-deb --fsys-tarfile $src | tar -x --no-same-permissions --no-same-owner;
'';
installPhase = ''
runHook preInstall
mv usr $out
mv opt $out
mv "$out/opt/Pocket Casts" $out/opt/pocket-casts
mv $out/share/icons/hicolor/0x0 $out/share/icons/hicolor/256x256
mkdir -p $out
mv bin $out
mv lib $out
mv share $out
cp $out/lib/pocket-casts/resources/app/icon.png $out/share/pixmaps/pocket-casts.png
runHook postInstall
'';
postFixup = ''
substituteInPlace $out/share/applications/pocket-casts.desktop \
--replace '"/opt/Pocket Casts/pocket-casts"' $out/bin/pocket-casts \
--replace '/usr/share/icons/hicolor/0x0/apps/pocket-casts.png' "pocket-casts"
--replace Name=pocket-casts "Name=Pocket Casts" \
--replace GenericName=pocket-casts "GenericName=Podcasts App" \
--replace Exec=pocket-casts Exec=$out/bin/pocket-casts
makeWrapper ${electron}/bin/electron \
$out/bin/pocket-casts \
--add-flags $out/opt/pocket-casts/resources/app.asar
--add-flags $out/lib/pocket-casts/resources/app/main.js
'';
meta = with lib; {

View File

@ -4770,9 +4770,7 @@ with pkgs;
pn = callPackage ../tools/text/pn { };
pocket-casts = callPackage ../applications/audio/pocket-casts {
electron = electron_14;
};
pocket-casts = callPackage ../applications/audio/pocket-casts { };
pouf = callPackage ../tools/misc/pouf { };