| |
| |
| Join The Cult | Tweakers | Image Gallery | Donate | Search | Today's Posts | Mark Forums Read | |
Welcome to Tweak3DThis is an open forum about tech stuff, games, and cars. Sign-up here to join the discussion. |
![]() |
| | LinkBack | Thread Tools | Display Modes |
| | Question About Sort command | permalink #1 |
| Tweak Minion | This is more for a guru(read: Wedge or anyone else that know haha). I'm going over a test for a linux course, and one of the commands I need to use is the Sort command. I have never used it, and the man page wasn't too userfriendly. So I guess if someone could give me an example how it is used that would be great. | |
| | ||
| | | |
| | #2 |
| | |
| | |
| | permalink #2 | |
| Rogue One | The manpage doesn't seem too bad, but here are some simple examples: If you just want to sort the lines in a file: sort <filename> If you want to sort in reverse order: sort -r <filename> If you want to remove duplicates from the results: sort -u <filename> | |
| Per Ardua Ad Astra | ||
| | | |
| | permalink #3 | |
| Tweak Minion | Ohh ok I get it now. I messed around with it and it actually sorted the stuff alphabetically. The reason I never realised it before is because is just did and ls > file.txt and then i did a sort of file.txt but it was already in alphabetacle order haha. | |
| | | |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |