This is just a blurb to help a specif new user.

The only thing else I can say is if you are going to use a command or set of commands a lot then put it a comand/batch/bash file and set it so you can enter arguments on the fly or at least be able to edit them the way you wish. it’s that simple.

i.e.:
talktxt chmodded with +x
Code:
# speak a text file
echo Speaking $1
cat $1 | festival –tts

$ ./talktxt /etc/issue
$ cp talktxt talkps
$ vim talkps

talkps chmodded with +x

Code:
# speak a pdf file
echo Speaking $1
ps2ascii $1 | festival –tts

$ ./talkps somefile.pdf

———————————————–
Easier to adapt code as necessary without writing whole new scripts. You can do a lot more complicated things, but just wanted to use a basic example. You do not have to use “vim” to edit the files. Any ascii/text editor will work.

The power of Unix!
fileget
Code:
wget $1 -O $2

old
$ wget http://somelongurl.com/dir/subdir/file.txt -O path/to/wherever/file.txt
new
$ ./fileget http://somelongurl.com/dir/subdir/file.txt path/to/wherever

or
“cut and paste”
cursor up
$ echo ./fileget http://somelongurl.com/dir/subdir/file.txt path/to/wherever > getfiles
$ vim getfiles

Code:
./fileget http://somelongurl.com/dir/subdir/file.txt path/to/wherever
./fileget http://somelongurl.com/dir/subdir/file1.txt path/to/wherever
./fileget http://somelongurl.com/dir/subdir/file2.txt path/to/wherever

or

Code:
wget http://somelongurl.com/dir/subdir/file.txt -O path/to/wherever
wget http://somelongurl.com/dir/subdir/file1.txt -O path/to/wherever
wget http://somelongurl.com/dir/subdir/file2.txt -O path/to/wherever

$ ./getfiles

Advertisements