I have a file called FILELIST that has about 200 lines in it, when you cat FILELIST it looks like this:
/SYS3/PRDSCHED/SF257902
/SYS3/PRDSCHED/SF271902
/SYS3/PRDSCHED/SF272
/SYS3/PRDSCHED/SF282902
/SYS3/PRDSCHED/SF302902
I would like to go into this file called "FILELIST" and cut the characters that have files that are more than 21 characters per line. The results should look like this:
/SYS3/PRDSCHED/SF257
/SYS3/PRDSCHED/SF271
/SYS3/PRDSCHED/SF272
/SYS3/PRDSCHED/SF282
/SYS3/PRDSCHED/SF302
What I tried before was:
cat FILELIST | sed -c21- > FILETEMP
mv FILETEMP FILELIST
But this only gives me the cut pieces like shown below:
902
902
902
902
Any ideas????
/SYS3/PRDSCHED/SF257902
/SYS3/PRDSCHED/SF271902
/SYS3/PRDSCHED/SF272
/SYS3/PRDSCHED/SF282902
/SYS3/PRDSCHED/SF302902
I would like to go into this file called "FILELIST" and cut the characters that have files that are more than 21 characters per line. The results should look like this:
/SYS3/PRDSCHED/SF257
/SYS3/PRDSCHED/SF271
/SYS3/PRDSCHED/SF272
/SYS3/PRDSCHED/SF282
/SYS3/PRDSCHED/SF302
What I tried before was:
cat FILELIST | sed -c21- > FILETEMP
mv FILETEMP FILELIST
But this only gives me the cut pieces like shown below:
902
902
902
902
Any ideas????