add shebang on lib files
This commit is contained in:
parent
9fe99d98dd
commit
1a9758a251
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getConfig() {
|
||||
while read key value
|
||||
do
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getConfigDestination() {
|
||||
case "$key" in
|
||||
'path')
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getConfigGeneral() {
|
||||
case $key in
|
||||
'max-load')
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getConfigSource() {
|
||||
case "$key" in
|
||||
'path')
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
printConfig() {
|
||||
{
|
||||
cat <<-EOF
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
checkCopy() {
|
||||
(
|
||||
[ -z "${destinationfrequency[$destination]}" ] \
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
copyFiles_action() {
|
||||
echo '
|
||||
SELECT
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
copyFiles_matching() {
|
||||
extension="${filename##*.}"
|
||||
cp -al \
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
Delete() {
|
||||
#Delete table < where_key where_operator where_value
|
||||
# [where_key where_operator where_value
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
Insert() {
|
||||
#Insert table [no_id] < key value
|
||||
# [key value
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
InsertIfUnset() {
|
||||
#InsertIfUnset table [no_id] < key value \n key value
|
||||
local \
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
InsertOrUpdate() {
|
||||
#InsertOrUpdate table set_key set_value [set_key set_value […]] < where_key where_value
|
||||
# [where_key where_value
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
Select() {
|
||||
#Select table [col1 [col2 [..]]] < WHERE_key WHERE_operator WHERE_value
|
||||
# [WHERE_key WHERE_operator WHERE_value
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
Update() {
|
||||
#Update table set_key set_value [set_key set_value […]] < where_key where_operator where_value
|
||||
# [where_key where_operator where_value
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
closeDatabase() {
|
||||
echo .quit >&3
|
||||
(( debug )) && echo -n "Waiting for SQLite to terminate... "
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
openDatabase() {
|
||||
if [ ! -d "$tempdir" ]
|
||||
then
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
decodeFile() {
|
||||
if ! decodetaskid=$(
|
||||
Select tasks id <<<"key = $tmpfile"
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
decodeMpcdec() {
|
||||
tmpfile="${fileid}mpcdec"
|
||||
commandline=(mpcdec "$sourcepath/$filename" "$tempdir/$tmpfile.wav")
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
decodeOpusdec() {
|
||||
tmpfile="${fileid}opusdec"
|
||||
commandline=(opusdec "$sourcepath/$filename" "$tempdir/$tmpfile.wav")
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
decodeSox() {
|
||||
commandline=(sox --single-threaded --temp "$tempdir")
|
||||
soxoptions_in=''
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
createDestinations() {
|
||||
for destination in ${!destinationpath[@]}
|
||||
do
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
updateMimes() {
|
||||
Update mime_actions action 1 <<<"action != 1"
|
||||
for destination in ${!destinationskipmime[@]}
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
encodeFile::mp3() {
|
||||
lameopts=(lame --quiet -v --abr ${destinationquality[$destination]})
|
||||
[ -n "$album" ] && lameopts+=(--tl "$album" )
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
encodeFile::opus() {
|
||||
opusencopts=(opusenc --music --quiet)
|
||||
opusencopts+=(--bitrate ${destinationquality[$destination]})
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
encodeFile::vorbis() {
|
||||
oggencopts=(oggenc -Q -q ${destinationquality[$destination]})
|
||||
[ -n "$albumartist" ] && oggencopts+=(-c "ALBUMARTIST=$albumartist")
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getDestDir() {
|
||||
destdir="${destinationpath[$destination]}/"
|
||||
if [ -n "${destinationrenamepath[$destination]}" ]
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getDestFile() {
|
||||
if [ -n "${destinationrename[$destination]}" ]
|
||||
then
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getFiles() {
|
||||
scantime=$(date +%s)
|
||||
for prune_expression in "${skippeddirectories[@]}"
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
removeObsoleteFiles() {
|
||||
Delete source_files <<-EOWhere
|
||||
last_seen < $scantime
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
sanitizeFile() {
|
||||
shopt -s extglob
|
||||
string="$1"
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getInfosAPE_version='APE-1'
|
||||
tagreaders+=( "$getInfosAPE_version" )
|
||||
getInfos::APE() {
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getInfosFLAC_version='FLAC-1'
|
||||
tagreaders+=( "$getInfosFLAC_version" )
|
||||
getInfos::FLAC() {
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getInfosMP3_version='ID3-2'
|
||||
tagreaders+=( "$getInfosMP3_version" )
|
||||
getInfos::MP3() {
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getInfosOgg_version='Ogg-1'
|
||||
tagreaders+=( "$getInfosOgg_version" )
|
||||
getInfos::Ogg() {
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getInfosOpus_version='Opus-1'
|
||||
tagreaders+=( "$getInfosOpus_version" )
|
||||
getInfos::Opus() {
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getRateChannelMPC() {
|
||||
while read key value garbage
|
||||
do
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getRateChannelSoxi() {
|
||||
rate=$(soxi -r "$sourcepath/$filename" 2>/dev/null)
|
||||
channels=$(soxi -c "$sourcepath/$filename" 2>/dev/null)
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getTags_version='unknown-2'
|
||||
tagreaders+=( "$getTags_version" )
|
||||
getTags() {
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
gettag() {
|
||||
echo -e "$infos" \
|
||||
| sed -n "/^${1}=/I{s/^${1}=//I;p;q}"
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
tryAPE() {
|
||||
grep -q 'APETAGEX' \
|
||||
"$sourcepath/$filename" \
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
gettaskinfos() {
|
||||
echo '
|
||||
SELECT
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
progressSpin() {
|
||||
case $(( ++count % 40 )) in
|
||||
0) echo -ne '\b|' ;;
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
checkworkers() {
|
||||
for key in ${!workers[@]}
|
||||
do
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
cleaner() {
|
||||
for key in ${!failedtasks[@]}
|
||||
do
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
createworker() {
|
||||
worker $1 &
|
||||
workers[$1]=$!
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
destroyworker() {
|
||||
dyingworker=${workers[$1]}
|
||||
unset workers[$1]
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
getworkerid() {
|
||||
local i
|
||||
for (( i=0 ; i >= 0 ; i++ ))
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
master() {
|
||||
if (( active >= concurrency)) || [ -n "$quit" ]
|
||||
then
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
#!/bin/bash
|
||||
worker() {
|
||||
exec 2>>"$tempdir/worker$1.log"
|
||||
(( debug >= 2 )) && echo "${cmd_arg[@]}" >&2
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user