Raspberry Pi Linux LESSON 9: Using the Linux Sort Command

preview_player
Показать описание
This is a quick lesson that shows you how to sort lists and files using the Linux sort command. We show how you can sort a file with output going to your terminal window, or how to send the output to a new file. We look at sorting alphabetically, numerically or by calendar month. We also show how to reverse sort.

See more details on this lesson at our WEB site at:
Рекомендации по теме
Комментарии
Автор

Thanks a lot for all your lessons, i really learn from your vids. I just want to add (as i learned now on my own) that the sort -M command only works when you type in the months in the same language as the raspberry is setup with the language/country settings :-).

markussorrentino
Автор

nice tut. also iv used a command called alias and i use it for all kinds of things but 1 good reason to use it is if your used to windows commands and you miss dir command you can alias ls and dir together and now when i type dir it actually ls :)
here are some examples you can use for a future lesson if you wish to!

here is an example which will allow ipconfif to be used instead of just ifconfig on linux when your used to windows this can be quite fun

type in your terminal the following:

alias ipconfig='ifconfig'

heres that dir example:

alias dir='ls -l'

Heres a ssh connect line example:


another eample for resetting a service:


alias srest='sudo /etc/init.d/apache2 restart'
heres an example for ssh connection to a raspberry pi

alias picon1='ssh 192.168.1.16'

(please note that the above example about ssh is not permanent but the rest are! can you work out how to make this a permanent alias?

Автор

Paul-

Excellent class. I find myself trying to find examples in which to implement these commands. More to follow...

chefbundles
Автор

Great video Mr. Mcwhorter. I didn't know any of these commands thank you.

erygion
Автор

A new command "touch" was used here but never explained on previous lessons.
If someone wants to know, I found this: The touch command is used to create, change and modify timestamps of a file.

radioxpert
Автор

Thank you Mr.McWorther, I find this a very useful tool, I will use it a lot

aynursunagatullin
Автор

Hello Paul,
As i usig Sort  -M  than stand March before January in the list
not between? why. I use the latest software NOBS

cjspijker
Автор

is anyone having the problem where the video is corrupt for the entire series

moritz
Автор

Got a question. I'm not trying to be rude but what is the point of learning this command lines when you can do them in graphic interface (not sure what to call it... Linux?) ? Is it to use them in python codes later on ? or maybe some sort of batch files ? Thanks for the great upload.

turboromy
Автор

How we can Send Command on lxterminal by using Python code/Script

adnansaeed
Автор

شكرا 
يا استاذ .... 
mr . paul go to google translate . from Arabic to English .

Eng.Mohammad_Alotaiby
Автор

Linus Torvalds and everyone else on the planet pronounces it Lih-nix (not Lie-nix). Get it straight!
What did I learn? You can't type, you can't spell July, you forgot October, and you take 40 forevers to teach the simplest Linux commands.

nox