![]() |
|
|
|||||||
| Home | Forums | Register | Rules & FAQ | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
Other UNIX.COM Threads You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Sort command - strange behaviour | miwinter | UNIX for Advanced & Expert Users | 16 | 05-29-2008 04:19 AM |
| Error message while executing the shell script | ajayyaduwanshi | Shell Programming and Scripting | 4 | 10-25-2007 04:12 AM |
| Strange error message with regex test... | fgilain | Shell Programming and Scripting | 4 | 05-31-2006 06:52 PM |
| ed strange error message | frenki | Shell Programming and Scripting | 6 | 10-29-2004 03:00 AM |
| Strange "Unable to load interpreter" message! | solvman | UNIX for Advanced & Expert Users | 6 | 05-15-2002 06:03 PM |
![]() |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|||
|
a strange message when executing the sort command
Dear all,
when I issue the command: gunzip -c file.gz |sort the command is executed normally and correctly but a message keeps appearing everytime I run the command: the message: sort: missing NEWLINE added at end of input file STDIN Does anyone know what is the meaning of this message? Thanks in advance |
| Forum Sponsor | ||
|
|
|
|||
|
Dear Zazzybob,
thanks so much for the information, but i am so new to unix, and I can't completely follow up with u. I need to understand the source of the problem, that is why the sort command is adding a new line at the end of the file. and when i execute the command : gunzip -c file.gz |tail -1 , the result is the last two lines, not the last line only. Thanks |
|
|||
|
Unix files that us humans consider text, use ASCII 10 for carriage control - it's called a newline character.
Unzip the file. Open the file in an editor, go to the end of the very last line and hit the return key on the keyboard. That will add a newline (\n) to the end of the file. Save the changed file. Re-zip it. |
|||
| Google UNIX.COM |