bash scripting question
Hello everyone,
Code:
#!/bin/sh Code:
robert@myth-dvr:~$ /usr/local/bin/change_channel.sh one Any ideas would be greatly appreciated. Robert |
Moin
I don't exactly understand, what you want. Which values do you expect as $1? If you want to split the argument into single digits, you first have to assure that the argument is a number. Actually your sed splits every argument (even if it is a number or not) into single characters. Maybe this sed helps: Code:
sed -e 's/[0-9]/& /g' |
The "for" loop breaking up stuff?
Code:
#!/bin/bash |
I think I know what you are trying to do... but I'm not sure...
If you are pressing a number combination 1 2 3 4 that gets cached then translated and separated with your for loop... then you really just need spaces in between them. Code:
function function_name () { It's kind of hard to understand what you are trying to do with the for command if you don't tell us more information. |
All times are GMT -5. The time now is 12:25 PM. |