mythlink.pl File Reference
Go to the source code of this file.
Functions |
| | our ($dest, $format, $usage, $underscores, $live, $rename, $maxlength) |
| | our ($chanid, $starttime, $filename) |
| | our ($dformat, $dseparator, $dreplacement, $separator, $replacement) |
| | our ($db_host, $db_user, $db_name, $db_pass, $video_dir, $verbose) |
| | GetOptions ('link|destination|path:s'=>\$dest, 'chanid=s'=>\$chanid, 'starttime=s'=>\$starttime, 'filename=s'=>\$filename, 'format=s'=>\$format, 'live'=>\$live, 'separator=s'=>\$separator, 'replacement=s'=>\$replacement, 'rename'=>\$rename, 'maxlength=i'=>\$maxlength, 'usage|help'=>\$usage, 'underscores'=>\$underscores, 'verbose'=>\$verbose) |
| | if ($usage) |
| | chomp ($hostname) |
| | if ($base_dir eq '') |
| | vprint ("Link destination directory: $dest") |
| | unless (-e $dest) |
| die $dest is not a directory n | unless (-d $dest) |
| | if (!defined($filename) and!defined($chanid)) |
| | if (defined($chanid)) |
Variables |
| use | DBI |
| use | MythTV |
| | $dformat = '%T %- %Y-%m-%d |
| g i A | S |
| | $dseparator = '-' |
| | $dreplacement = '-' |
| | $format = $dformat |
| | $separator = $dseparator |
| | $replacement = $dreplacement |
| | $maxlength = -1 |
| our | $safe_sep = $separator |
| our | $safe_rep = $replacement |
| | $hostname = `hostname` |
| my | $Myth = new MythTV() |
| | $dbh = $Myth->{'dbh'} |
| | $base_dir = $sgroup->FindRecordingDir('show_names') |
| | $dest = "$base_dir/show_names" |
| my | rows = () |
Function Documentation
| our |
( |
$ |
dest, |
|
|
$ |
format, |
|
|
$ |
usage, |
|
|
$ |
underscores, |
|
|
$ |
live, |
|
|
$ |
rename, |
|
|
$ |
maxlength | |
|
) |
| | |
| our |
( |
$ |
chanid, |
|
|
$ |
starttime, |
|
|
$ |
filename | |
|
) |
| | |
| our |
( |
$ |
dformat, |
|
|
$ |
dseparator, |
|
|
$ |
dreplacement, |
|
|
$ |
separator, |
|
|
$ |
replacement | |
|
) |
| | |
| our |
( |
$ |
db_host, |
|
|
$ |
db_user, |
|
|
$ |
db_name, |
|
|
$ |
db_pass, |
|
|
$ |
video_dir, |
|
|
$ |
verbose | |
|
) |
| | |
| GetOptions |
( |
'link|destination|path:s' |
, |
|
|
\$ |
dest, |
|
|
' |
chanid = s'=, |
|
|
\$ |
chanid, |
|
|
' |
starttime = s'=, |
|
|
\$ |
starttime, |
|
|
' |
filename = s'=, |
|
|
\$ |
filename, |
|
|
' |
format = s'=, |
|
|
\$ |
format, |
|
|
'live' |
, |
|
|
\$ |
live, |
|
|
' |
separator = s'=, |
|
|
\$ |
separator, |
|
|
' |
replacement = s'=, |
|
|
\$ |
replacement, |
|
|
'rename' |
, |
|
|
\$ |
rename, |
|
|
' |
maxlength = i'=, |
|
|
\$ |
maxlength, |
|
|
'usage|help' |
, |
|
|
\$ |
usage, |
|
|
'underscores' |
, |
|
|
\$ |
underscores, |
|
|
'verbose' |
, |
|
|
\$ |
verbose | |
|
) |
| | |
| vprint |
( |
"Link destination directory: $dest" |
|
) |
|
| die $dest is not a directory n unless |
( |
-d $ |
dest |
) |
|
| if |
( |
! |
defined$filename) and!defined($chanid |
) |
|
Variable Documentation
| $dformat = '%T %- %Y-%m-%d |
| $replacement = $dreplacement |
| $base_dir = $sgroup->FindRecordingDir('show_names') |
| $dest = "$base_dir/show_names" |