]> gitweb.fluxo.info Git - trashman.git/commitdiff
Feat: hoarder: yt-splitter
authorSilvio Rhatto <rhatto@riseup.net>
Fri, 28 May 2021 12:23:52 +0000 (09:23 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Fri, 28 May 2021 12:23:52 +0000 (09:23 -0300)
share/hoarder/yt-splitter/info [new file with mode: 0644]
share/hoarder/yt-splitter/unix/linux/install [new file with mode: 0755]

diff --git a/share/hoarder/yt-splitter/info b/share/hoarder/yt-splitter/info
new file mode 100644 (file)
index 0000000..aa88f6e
--- /dev/null
@@ -0,0 +1 @@
+downloads and splits audio tracks from a YouTube video according to the chapters/tracks
diff --git a/share/hoarder/yt-splitter/unix/linux/install b/share/hoarder/yt-splitter/unix/linux/install
new file mode 100755 (executable)
index 0000000..8671b03
--- /dev/null
@@ -0,0 +1,28 @@
+#!/usr/bin/env bash
+#
+# Install yt-splitter package manager.
+#
+
+# Parameters
+SHARE="$1"
+LIB="$2"
+
+# Include basic functions
+. $LIB/trashman/functions || exit 1
+
+# Requirements
+trashman_require wget ffmpeg
+
+# Dependency: youtube-dl
+hoarder install youtube-dl
+
+# Additional parameters
+VERSION="0.1.2"
+URL="https://github.com/redsolver/yt-splitter/releases/download/v$VERSION/yt-splitter-linux"
+DEST="$HOME/.local/bin/yt-splitter"
+
+# Remove any older version
+rm -f $DEST
+
+# Download and install
+wget "$URL" -O "$DEST" && chmod +x "$DEST" || exit 1