audiodl

A youtube-dl wrapper for downloading audio files.
git clone git://git.swab.dev/audiodl.git
Log | Files | Refs | README | LICENSE

commit ebb29340bd2d7bc8a63da2c9896122bde98b91aa
parent 5853ed44a6802d8935da3a5dabcfe5a316ad5b42
Author: Jaron Swab <jaron@swab.dev>
Date:   Fri,  2 Apr 2021 15:38:06 -0400

Added man page and markdown version for use with pandoc

Diffstat:
Aaudiodl.1 | 97+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Aaudiodl.1.md | 70++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 167 insertions(+), 0 deletions(-)

diff --git a/audiodl.1 b/audiodl.1 @@ -0,0 +1,97 @@ +.\" Automatically generated by Pandoc 2.11.4 +.\" +.TH "audiodl" "1" "April 2021" "audiodl 0.1.0" "" +.hy +.SH NAME +.PP +audiodl - A youtube-dl wrapper for downloading audio files. +.SH SYNOPSIS +.PP +\f[B]audiodl\f[R] URL [\f[I]OPTION\f[R]]\&... +.SH DESCRIPTION +.PP +\f[B]audiodl\f[R] is a youtube-dl wrapper which automates the creation, +movement, and playlist additions when downloading an audio file from a +given URL. +Running \f[B]audiodl\f[R] with only a URL provided will place the audio +file in the directory of execution. +The resulting MP3 file will consist of the title of the video being +converted. +.SH OPTIONS +.TP +\f[B]-h\f[R], \f[B]\[en]help\f[R] +Displays a reference of the options and their usage. +.TP +\f[B]-n\f[R], \f[B]\[en]name\f[R] +The name of the resulting MP3 file. +(Wrap in double quotes if spaces are present.) +.TP +\f[B]-s\f[R], \f[B]\[en]separator\f[R] +The character to replace any space with. +\f[B]-n\f[R] or \f[B]\[en]name\f[R] must be provided. +.TP +\f[B]-d\f[R], \f[B]\[en]directory\f[R] +The directory where the MP3 should be moved to. +If not in a parent directory, the absolute path from \[lq]/home\[rq] +must be given. +.TP +\f[B]-p\f[R], \f[B]\[en]playlist\f[R] +The file to place the audio file name in. +This file is a new line separated list of file names and must +(currently) live in the director with the music. +If not in a parent directory, the absolute path from \[lq]/home\[rq] +must be given. +.SH Examples +.TP +\f[B]audiodl \[lq]https://some.url\[rq]\f[R] +Downloads the file, converts it to MP3, and places in the current +directory with the default title from youtube-dl. +.TP +\f[B]audiodl \[lq]https://some.url\[rq] -n \[lq]Some Name\[rq]\f[R] +Downloads the file, converts it to MP3, and places in the current +directory with the file name \[lq]SomeName.mp3\[rq]. +.TP +\f[B]audiodl \[lq]https://some.url\[rq] -n \[lq]Some Name\[rq] -s \[lq]-\[rq]\f[R] +Downloads the file, converts it to MP3, and places in the current +directory with the file name \[lq]Some-Name.mp3\[rq]. +.TP +\f[B]audiodl \[lq]https://some.url\[rq] -n \[lq]Some Name\[rq] -s \[lq]-\[rq] -d \[lq]/home/audiodl/music/lofi\[rq]\f[R] +Downloads the file, converts it to MP3, and places in the lofi directory +under \[lq]/home/audiodl/music\[rq] with the file name +\[lq]Some-Name.mp3\[rq]. +.TP +\f[B]audiodl \[lq]https://some.url\[rq] -n \[lq]Some Name\[rq] -s \[lq]-\[rq] -d \[lq]/home/audiodl/music/lofi\[rq] -p \[dq]/home/audiodl/music/lofi/lofi.playlist\f[R] +Downloads the file, converts it to MP3, places in the lofi directory +under \[lq]/home/audiodl/music\[rq] with the file name +\[lq]Some-Name.mp3\[rq], and adds \[lq]Some-Name.mp3\[rq] as a new line +in \[lq]lofi.playlist\[rq] under \[lq]/home/audiodl/music/lofi\[rq]. +.SH EXIT VALUES +.TP +\f[B]0\f[R] +Success +.TP +\f[B]1\f[R] +Execution failed, check stderr for information. +.SH BUGS +.PP +I\[cq]m sure theres one somewhere\&... +.SH COPYRIGHT +.PP +Copyright (C) 2021 Jaron R. +Swab +.PP +This program is free software: you can redistribute it and/or modify it +under the terms of the GNU Affero General Public License as published by +the Free Software Foundation, either version 3 of the License, or (at +your option) any later version. +.PP +This program is distributed in the hope that it will be useful, but +WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +See the GNU Affero General Public License for more details. +.PP +You should have received a copy of the GNU Affero General Public License +along with this program. +If not, see <https://www.gnu.org/licenses/>. +.SH AUTHORS +Jaron R. Swab. diff --git a/audiodl.1.md b/audiodl.1.md @@ -0,0 +1,70 @@ +% audiodl(1) audiodl 0.1.0 +% Jaron R. Swab +% April 2021 + +# NAME +audiodl - A youtube-dl wrapper for downloading audio files. + +# SYNOPSIS +**audiodl** URL [*OPTION*]... + +# DESCRIPTION +**audiodl** is a youtube-dl wrapper which automates the creation, movement, and playlist additions when downloading an audio file from a given URL. Running **audiodl** with only a URL provided will place the audio file in the directory of execution. The resulting MP3 file will consist of the title of the video being converted. + +# OPTIONS +**-h**, **--help** +: Displays a reference of the options and their usage. + +**-n**, **--name** +: The name of the resulting MP3 file. (Wrap in double quotes if spaces are present.) + +**-s**, **--separator** +: The character to replace any space with. **-n** or **--name** must be provided. + +**-d**, **--directory** +: The directory where the MP3 should be moved to. If not in a parent directory, the absolute path from "/home" must be given. + +**-p**, **--playlist** +: The file to place the audio file name in. This file is a new line separated list of file names and must (currently) live in the director with the music. If not in a parent directory, the absolute path from "/home" must be given. + +# Examples +**audiodl "https://some.url"** +: Downloads the file, converts it to MP3, and places in the current directory with the default title from youtube-dl. + +**audiodl "https://some.url" -n "Some Name"** +: Downloads the file, converts it to MP3, and places in the current directory with the file name "SomeName.mp3". + +**audiodl "https://some.url" -n "Some Name" -s "-"** +: Downloads the file, converts it to MP3, and places in the current directory with the file name "Some-Name.mp3". + +**audiodl "https://some.url" -n "Some Name" -s "-" -d "/home/audiodl/music/lofi"** +: Downloads the file, converts it to MP3, and places in the lofi directory under "/home/audiodl/music" with the file name "Some-Name.mp3". + +**audiodl "https://some.url" -n "Some Name" -s "-" -d "/home/audiodl/music/lofi" -p "/home/audiodl/music/lofi/lofi.playlist** +: Downloads the file, converts it to MP3, places in the lofi directory under "/home/audiodl/music" with the file name "Some-Name.mp3", and adds "Some-Name.mp3" as a new line in "lofi.playlist" under "/home/audiodl/music/lofi". + +# EXIT VALUES +**0** +: Success + +**1** +: Execution failed, check stderr for information. + +# BUGS +I'm sure theres one somewhere... + +# COPYRIGHT +Copyright (C) 2021 Jaron R. Swab + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as published +by the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see <https://www.gnu.org/licenses/>.