Procházet zdrojové kódy

removed unnecessary binaries, and updated mbell

master
mort před 9 roky
rodič
revize
c4f6576aa5
3 změnil soubory, kde provedl 15 přidání a 19 odebrání
  1. 15
    11
      bin/mbell
  2. binární
      bin/youtube-dl
  3. 0
    8
      bin/youtube-stream

+ 15
- 11
bin/mbell Zobrazit soubor

@@ -1,24 +1,28 @@
#!/bin/bash

if [[ $1 ]]; then
name=$1
else
name="<unknown>"
fi
# Written by Francis Wharf, https://github.com/xeom

code=1
# Default
name="<unknown>"

# If there is an argument, use it as program name
[[ $1 ]] && name=$1

while true; do
read -r -d "" -t 10;
# Read, ignoring escapes, until the first bell char if
# no bell is received in 10 seconds, the script loops
read -r -d $(printf "\007") -t 10;
code=$?

# If the code is a timeout error, continue
if [[ $code > 128 ]]; then
continue
fi

if [[ $code != 0 ]]; then
break;
# If read returned eof, suicide
elif [[ $code != 0 ]]; then
exit 0
fi

mnotify "$name" "Bell from $name"
# If read returned success, notify user of bell
mnotify "$name" "Bell received"
done;

binární
bin/youtube-dl Zobrazit soubor


+ 0
- 8
bin/youtube-stream Zobrazit soubor

@@ -1,8 +0,0 @@
#!/bin/sh

dir="$(mktemp -d)"
cd "$dir"
youtube-dl "$1"
airstream * -o "$2"
cd ..
rm -r "$dir"

Načítá se…
Zrušit
Uložit