Help with shell scrip syntax errors

 
Thread Tools Search this Thread
# 8  
Old 10-15-2016
Quote:
Originally Posted by RudiC
How did you add them?
Code:
echo "$channel_remove" << "channels.txt"

won't work, no way!
Code:
 sed -E "s/$channel_remove//g"

# 9  
Old 01-19-2017
Surely to remove a channel, you need to

Code:
grep -v "$channel_remove" channels.txt > channels.NEW
mv channels.NEW channels.txt


ps - just noticed the sed command that Demas had posted which will answer this query too.
# 10  
Old 01-24-2017
Take note of the last line, done .
Something is missing, for example...
Code:
while true
do
        lots of code here
done        #Your line 48 as 49 does not technically exist.


|
Thread Tools Search this Thread
Search this Thread:
Advanced Search

More UNIX and Linux Forum Topics You Might Find Helpful
Finding latest file in dir but getting syntax errors simpltyansh Shell Programming and Scripting 3 05-17-2017 09:14 AM
Help with Shell Scrip in Masking particular columns in .csv file or .txt file using shell script Mahesh G Shell Programming and Scripting 5 11-07-2016 12:59 AM
Converting from Linux bash (GNU) to Solaris script syntax errors oly_r Shell Programming and Scripting 13 05-03-2013 10:42 AM
Seek help on shell script syntax errors duke0001 Emergency UNIX and Linux Support 8 08-03-2011 04:06 AM
Get file name in shell scrip loop: bad substitution soueric Solaris 4 05-03-2011 12:20 AM
how to combine two files into one file using shell scrip netbanker Shell Programming and Scripting 2 12-06-2010 06:34 PM
line count with if /else - syntax errors kwalkner Shell Programming and Scripting 6 11-09-2010 05:01 PM
I dont really think that the math header has syntax errors tcerka UNIX for Dummies Questions & Answers 1 09-13-2010 05:40 PM
PERL Syntax Errors nurani Shell Programming and Scripting 2 06-16-2010 01:49 AM
perl version for syntax errors bigben1220 Shell Programming and Scripting 13 05-12-2010 07:11 AM
How to convert shell scrip to binaric command raghunsi UNIX for Advanced & Expert Users 1 02-03-2010 02:27 AM
Using cp command inside shell scrip yoavbe Shell Programming and Scripting 2 06-22-2006 10:57 AM
If a is windows gui ( client), b is a unix gui ( Server for a) and c is a shell scrip hchivukula UNIX for Dummies Questions & Answers 1 06-12-2005 09:34 AM
AWK Syntax errors :/ yongho Shell Programming and Scripting 6 06-08-2005 03:08 PM
Execute an Oracle stored procedure from a shell scrip mh53j_fe Shell Programming and Scripting 1 06-03-2005 04:17 PM