Dvdselect readdvd.sh
Aus VDR Wiki
(Unterschied zwischen Versionen)
(http://sematild.qsh.eu/resource1375.htm) |
(-spam) |
||
Zeile 1: | Zeile 1: | ||
− | |||
Skripte vom [[dvdselect-plugin]]. | Skripte vom [[dvdselect-plugin]]. | ||
Version vom 8. Januar 2009, 23:29 Uhr
Skripte vom dvdselect-plugin.
$PATH/dvdselect_readdvd.sh
#!/bin/sh # # dvdselect_readdvd.sh # # source: dvdselect-plugin # # This script will by called by the vdr-plugin dvdselect to copy a DVD to # the local drive. # # It gets the following parameters: # # $1 = directory for dvd's (see plugin configuration menu) # $2 = name of dvd # $3 = original dvd-device rm -f "$1/$2.iso" mkdir -p "$1/" echo "dd if=$3 of=\"$1/$2.iso\" > /var/log/vdr/readdvd.log 2>&1" | at now
$PATH/dvdselect_readdvd.sh
#!/bin/sh # # dvdselect_readdvd.sh # # source: dvdselect-plugin # # an LinVDR angepasst, da LinVDR kein at-Kommando hat # modified for LinVDR, because there is no at-command # # This script will by called by the vdr-plugin dvdselect to copy a DVD to # the local drive. # # It gets the following parameters: # # $1 = directory for dvd's (see plugin configuration menu) # $2 = name of dvd # $3 = original dvd-device rm -f "$1/$2.iso" mkdir -p "$1/" echo " \ svdrpsend.pl -d localhost "MESG DVD einlesen gestartet" 2>/dev/null 1>/dev/null ; \ dd if=$3 of=\"$1/$2.iso\" ; \ svdrpsend.pl -d localhost "MESG DVD $2 fertig" 2>/dev/null 1>/dev/null ; \ " > /tmp/dvdselect_read-temp.sh chmod 700 /tmp/dvdselect_read-temp.sh /tmp/dvdselect_read-temp.sh &
$PATH/dvdselect_readdvd.sh
#!/bin/sh # # dvdselect_readdvd.sh # # This script will by called by the vdr-plugin dvdselect to copy a DVD to # the local drive, via readcd from packed cdrecord # # $1 outdir # $2 name (if call with "neue_DVD" default german title, name replaced with name of dvd volume) # $3 device { # ATAPI LW des Brenner BRENNER="$3" if ! test -d "$1"; then echo "Verzeichnis $1 nicht gefunden" exit 1 fi if test "$2" == "" -o "$2" == "neue_DVD" ; then VOLUME=`volname $BRENNER | tr -d " "` if test "$VOLUME" == "" ; then if test "$2" == "" ; then VOLUME="neue_DVD" else VOLUME="$2" fi fi else VOLUME="$2" fi IMAGE="$1/$VOLUME.iso" NC="/bin/nc 127.0.0.1 2001" AT="/usr/bin/at -q t now" WRAPPER=$(basename $0) SHOW=$(echo $(basename "$IMAGE") | cut -b -30) echo \ "echo -e \"MESG Starte $WRAPPER : $SHOW.. \nQUIT\" | $NC &>/dev/null;\ readcd -s dev=ATAPI:$BRENNER f='$IMAGE' 1>/dev/null 2>/tmp/$VOLUME.log ;\ eject $3 >/dev/null;\ echo -e \"MESG $WRAPPER fertig : $SHOW.. , in \$((\$(date +%s) - $(date +%s))) Sek.\nQUIT\" | $NC &> /dev/null;\ echo -e \\\a >/dev/tty0" | $AT } 2>&1