File tree Expand file tree Collapse file tree 3 files changed +147
-0
lines changed
pkgs/by-name/pa/parabolic Expand file tree Collapse file tree 3 files changed +147
-0
lines changed Original file line number Diff line number Diff line change 1+ { lib
2+ , buildDotnetModule
3+ , fetchFromGitHub
4+ , dotnetCorePackages
5+ , gtk4
6+ , libadwaita
7+ , pkg-config
8+ , wrapGAppsHook4
9+ , glib
10+ , shared-mime-info
11+ , gdk-pixbuf
12+ , blueprint-compiler
13+ , python3
14+ , ffmpeg
15+ } :
16+
17+ buildDotnetModule rec {
18+ pname = "parabolic" ;
19+ version = "2023.12.0" ;
20+
21+ src = fetchFromGitHub {
22+ owner = "NickvisionApps" ;
23+ repo = "Parabolic" ;
24+ rev = version ;
25+ hash = "sha256-mbGByw/wgovo81l2LDtDE5p+Mh6aJ5DOcZCNzVfmAtA=" ;
26+ fetchSubmodules = true ;
27+ } ;
28+
29+ dotnet-sdk = dotnetCorePackages . sdk_8_0 ;
30+ dotnet-runtime = dotnetCorePackages . runtime_8_0 ;
31+ pythonEnv = python3 . withPackages ( ps : with ps ; [ yt-dlp ] ) ;
32+
33+ projectFile = "NickvisionTubeConverter.GNOME/NickvisionTubeConverter.GNOME.csproj" ;
34+ nugetDeps = ./deps.nix ;
35+ executables = "NickvisionTubeConverter.GNOME" ;
36+
37+ nativeBuildInputs = [
38+ pkg-config
39+ wrapGAppsHook4
40+ glib
41+ shared-mime-info
42+ gdk-pixbuf
43+ blueprint-compiler
44+ ] ;
45+
46+ buildInputs = [ gtk4 libadwaita ] ;
47+
48+ runtimeDeps = [
49+ gtk4
50+ libadwaita
51+ glib
52+ gdk-pixbuf
53+ ] ;
54+
55+ postPatch = ''
56+ substituteInPlace NickvisionTubeConverter.Shared/Linux/org.nickvision.tubeconverter.desktop.in --replace '@EXEC@' "NickvisionTubeConverter.GNOME"
57+ '' ;
58+
59+ postInstall = ''
60+ install -Dm444 NickvisionTubeConverter.Shared/Resources/org.nickvision.tubeconverter.svg -t $out/share/icons/hicolor/scalable/apps/
61+ install -Dm444 NickvisionTubeConverter.Shared/Resources/org.nickvision.tubeconverter-symbolic.svg -t $out/share/icons/hicolor/symbolic/apps/
62+ install -Dm444 NickvisionTubeConverter.Shared/Linux/org.nickvision.tubeconverter.desktop.in -T $out/share/applications/org.nickvision.tubeconverter.desktop
63+ '' ;
64+
65+ makeWrapperArgs = [ "--prefix PATH : ${ lib . makeBinPath [ pythonEnv ffmpeg ] } " ] ;
66+
67+ passthru . updateScript = ./update.sh ;
68+
69+ meta = with lib ; {
70+ description = "Download web video and audio" ;
71+ homepage = "https://github.com/NickvisionApps/Parabolic" ;
72+ license = licenses . mit ;
73+ maintainers = with maintainers ; [ ewuuwe ] ;
74+ mainProgram = "parabolic" ;
75+ platforms = platforms . linux ;
76+ } ;
77+ }
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env nix-shell
2+ #! nix-shell -I nixpkgs=./. -i bash -p curl jq common-updater-scripts
3+ # shellcheck shell=bash
4+
5+ set -eu -o pipefail
6+
7+ version=$( curl -s ${GITHUB_TOKEN: +-u " :$GITHUB_TOKEN " } \
8+ https://api.github.com/repos/NickvisionApps/Parabolic/releases/latest | jq -e -r .tag_name)
9+ old_version=$( nix-instantiate --eval -A parabolic.version | jq -e -r)
10+
11+ if [[ $version == " $old_version " ]]; then
12+ echo " New version same as old version, nothing to do." >&2
13+ exit 0
14+ fi
15+
16+ update-source-version parabolic " $version "
17+
18+ $( nix-build -A parabolic.fetch-deps --no-out-link) " $( dirname -- " ${BASH_SOURCE[0]} " ) /deps.nix"
You can’t perform that action at this time.
0 commit comments