Subversion Repositories programming

Rev

Rev 89 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
89 irasnyd 1
#!/bin/bash
2
 
98 irasnyd 3
if [ -z "$@" ]; then echo "I need a filename..."; exit; fi;
4
 
89 irasnyd 5
MY_FILENAME=$(echo "$@" | sed 's/\.avi//' | sed 's/\.ogm//' | sed 's/\.mkv//').nfo
6
 
7
### Output title ###
8
echo -n 'Title: ' > ${MY_FILENAME}
9
echo "$(echo ${MY_FILENAME} | sed 's/\.nfo//' | sed 's/\[........\]//' )" >> ${MY_FILENAME}
10
echo >> ${MY_FILENAME}
11
 
12
### Ouput file info ###
13
echo -n 'File Info: ' >> ${MY_FILENAME}
14
file "$@" >> ${MY_FILENAME}
15
echo >> ${MY_FILENAME}
16
 
17
### Output messages ###
18
echo 'Par2s will be included at 14% as well.' >> ${MY_FILENAME}
19
echo >> ${MY_FILENAME}
20
echo 'Please use the par2 when possibile since I do not intend to repost any files' >> ${MY_FILENAME}
21
echo 'after I can see that they are all complete on servers other than the one that' >> ${MY_FILENAME}
22
echo 'it was posted to. Missing files and incomplete files will be backfiled as I see' >> ${MY_FILENAME}
23
echo 'them.' >> ${MY_FILENAME}
24
echo >> ${MY_FILENAME}
25
echo 'If you are not sure what par2 files are or how to use them please visit' >> ${MY_FILENAME}
26
echo 'http://www.timdoc.com and READ IT.' >> ${MY_FILENAME}
27
echo >> ${MY_FILENAME}
28
echo 'I DO NOT recieve any text replies to my posts, since I read this group in a' >> ${MY_FILENAME}
29
echo 'binary-only newsreader.' >> ${MY_FILENAME}
30
echo >> ${MY_FILENAME}
31
echo 'Requests:' >> ${MY_FILENAME}
32
echo 'None at this time' >> ${MY_FILENAME}
33