can a tty execute command on another tty?
there's many ways to do things-I'm wondering if this is a valid avenue to solve mine. I'm running fdupes on my duplicate music files and come up with 6xxx dupes. *sigh* I used the -d command to prompt for deletion so now the tty it's running in asks me to press 1 for each dupe. I found I can open another tty and type
'echo "1" > /dev/pts/4'
and the 1 will show up on the other tty. is there a way to make that term send that to the process (make it execute)? or is there a way to pass that character directly to the process? my ultimate goal is to write a script that will put the 6xxx 1's in there for me. Thanks guys!
My understanding is, you want to automate the manual process of giving input to the fdupes process.
just create a file with the required number of 1's in it.
for i in `seq 1 6xxx` ; do echo 1 > /tmp/file ; done
"your fdupes command" < /tmp/file
By using the "<" indirection operator you can give input to the process using a file.
i hope this solves ur problem.
to append to /tmp/file you will want to use "echo 1 >> /tmp/file" instead of "echo 1 > /tmp/file"
You guys are the snizzznittlekabangabob!
On a real tip-THANKS!!!! It has worked and saved me from losing even more hair off of my head. A thousand thank yous! :-)
Gaurav/Lukav you guys are the BEST!!
|All times are GMT -5. The time now is 03:18 AM.|