Hide

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again.

Delete that bloated snippets file you've been using and share your personal repository with the world. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.


Get involved!

You can sign-in using OpenID credentials, or register a traditional username and password.

First-time OpenID users will be automatically assigned a username which can be changed after signing in.

Universal configuration monitoring and system of record for IT.
Hide

Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for:

Hide

News

May 19, 2015 - A Look At The New Commandlinefu
I've put together a short writeup on what kind of newness you can expect from the next iteration of clfu. Check it out here.
March 2, 2015 - New Management
I'm Jon, I'll be maintaining and improving clfu. Thanks to David for building such a great resource!
Hide

Top Tags

Hide

Functions

Psst. Open beta.

Wow, didn't really expect you to read this far down. The latest iteration of the site is in open beta. It's a gentle open beta-- not in prime-time just yet. It's being hosted over at UpGuard (link) and you are more than welcome to give it a shot. Couple things:

  • » The open beta is running a copy of the database that will not carry over to the final version. Don't post anything you don't mind losing.
  • » If you wish to use your user account, you will probably need to reset your password.
Your feedback is appreciated via the form on the beta page. Thanks! -Jon & CLFU Team

list unique file extensions recursively for a path, include extension frequency stats

Terminal - list unique file extensions recursively for a path, include extension frequency stats
find /some/path -type f -and -printf "%f\n" | egrep -io '\.[^.]*$' | sort | uniq -c | sort -rn
2012-04-02 19:25:35
User: kyle0r
Functions: egrep find sort uniq
0
list unique file extensions recursively for a path, include extension frequency stats

the

find -printf "%f\n" prints just the file name from the given path. This means directory paths which contain extensions will not be considered.

Alternatives

There are 3 alternatives - vote for the best!

Terminal - Alternatives
find . -type f | awk -F'.' '{print $NF}' | sort| uniq -c | sort -g
2011-02-14 09:15:29
User: cp
Functions: awk find sort uniq
Tags: uniq ls grep
11

... plus do a sort according frequency

ls -Xp | grep -Eo "\.[^/]+$" | sort | uniq
2011-02-10 20:47:59
User: Amarok
Functions: grep ls sort
Tags: uniq ls grep
4

Works on current directory, with built-in sorting.

find /some/path -type f -printf '%f\n' | grep -o '\..\+$' | sort | uniq -c | sort -rn
2013-03-18 14:42:29
User: skkzsh
Functions: find grep sort uniq
2

Get the longest match of file extension (Ex. For 'foo.tar.gz', you get '.tar.gz' instead of '.gz')

find /path/to/dir -type f | grep -o '\.[^./]*$' | sort | uniq
2010-08-12 14:32:48
User: dooblem
Functions: find grep sort
1

Just a little simplification.

find /path/to/dir -type f -name '*.*' | sed 's@.*/.*\.@.@' | sort | uniq
2010-08-12 15:48:54
User: putnamhill
Functions: find sed sort
1

If your grep doesn't have an -o option, you can use sed instead.

Know a better way?

If you can do better, submit your command here.

What others think

Fast location bag is one kind of the most traditional layouts associated with Back pack, in a lot of collection of, at this time there continually can be found just one symbolic rapidly bag. As the almost all distinct type of this particular name brand, the item stresses the particular importances of simple model. watercolor quick 27 bags collect quite a few sorts of cool along with well-liked factors, to make sure that that series will come is the hot-selling items, varied men and women could question precisely why, permit me identify.When the item ended up being classy for females to offer baby dolls donning tiny variants with their clothes (the mini-me, so to speak), developers of bags makes Two measurements of his or her layouts'"capturing and also the most compact data inside the dolls' really small purses.The 1st is the space of revenue amount. Anybody using reduced cash flow will buy many comparatively low-cost furnishing to seek out for the feeling, also to indicate that themselves are another fellow member to the present session. The actual next is the without any flavoring. To the accurate massive manufacturer, it's hard to lessen all things the design and style, that may be, it decides on to be able to concision even though this implies exceedingly conventional on the individual that do not matter this kind of lessons.Much from the price ranges for more expensive merchandise depends upon your logo name along with the cost of buying the brand themselves. As a result illegal copies can give you the very same product or service in a reduce pace by simply definitely not charging you you to get a logo name they just do not individual. What is important quite simply opt for individuals Indicate Heuer Reproductions in which finest replicate the original view in every it's wonder by employing the complete items as well as actually shut lookalikes. Various other variations to look for are generally mentioned below.Permit us make a quick provide connected with Initialed or monogrammed Neverfull Millimeters for you. Monogram Neverfull Millimeter will be the youngest bag. Established, ageless in addition to modern is it is true portraiture. It can be produced by basic and also soft company logo fabric together with normal cowhide leather-based trims. You'll be able to switch it that you like style and design. When the eye-catching artists tend to be limited, it might be a chic area bag, When launch you are looking at be considered a multipurpose have bag. This type ofLV bagsis really hot within whenever. Do you really feel ecstatic with your a lovely bag? Can this bag could be the one which a person imagines? Enjoyable the numerous look for is the goal of company.Varying via cellular lining solution to sewing, tag, concluding, logo position, seem and other specifications, a sensible specific may independent original LV Vuittons products with the co-artists counterfeit handle significantly less effort. But in addition LV name brand beginner, it might be a great state of mind task to be aware of when since replica bag sold as a actual LV merchandise. Yet a new person that does a terrific examination following your suggestions explained right here can realize their desire to detect an imitation Louis Vuitons item.In order to declare on their own since the top supplier involving his time, this aesthete seemed to be productive, greater than anybody, throughout translating his / her desires influenced by painters: Andrew Warhol, Mondrian along with Ben Wesselman over the sixties, Picasso in the 70's, Suv Gogh in addition to Bonnard from the 80s. Their production currently have constantly made a detraction, from your primary see-through blouses (1968) to be able to the scent, Opium, released inside 1977. Yet his / her toughness can be their possible and convey total classicism, together with Catherine Deneuve while his or her ambassador. Since the heir to be able to and Balenciaga, this individual contains to their outlines, minimalist simply by facts: "Beauty is a method connected with relocating".Men have got http://www.hermesbeltsbirkinkellybag.co.uk/ in fact moaned in addition to moan for several years relating to trendy wounding as well as until basically not too long ago assorted dropped small to know it was from providing their own wallet inside their returning pocket and soon after on the idea. It is now encouraged of which guys placed their pocketbook in their the front pants pocket or layer billfold instead of his or her again pocket where by they will sit down on this.

Comment by stephanieg915 6 days ago

Netbooks have become fine and expensive waste pricey computer system consumer electronics. Defending all of them from acquiring destroyed in addition to shattered is vital for its staying power. No matter whether are generally holding your notebook for the university, workplace or getting this alongside while venturing, you want to ensure that your mobile computer is safe to use. Carrying a costly mobile computer can be associated with the appropriate the laptop back pack, certainly. Along with, a good notebook computer instance shields your high-priced device. Moreover, the particular compactness in addition to ease of laptops in addition get them to popular to keep things interesting when going on your own, work with a tight schedule in addition to a quantity of other considerations. In contrast, your flexibility in addition enhances the chance of currently being scratched or even ruined, in particular at the time of going. Branded notebook computer bags are probably the how to reduce the risk of damage to your notebook computer; they're going to protect it from punctures via finding broken. Nowadays, these people come to be a crucial object with regard to everyday activities, specifically the people who must have these people all over the place. Putting on a bag having heavy objects can cause force on ones spinal. Whether you are the basic or a expert, usually have a comfortable bag, this will help in the long run together with stop you from creating back or maybe make soreness. Just an advice-choose one that suits properly in your neck together with sells the burden from your time for the body.Laptop cases are a high-end investment and everyone look for a brand name case to guard their own high priced products. Whether you need to have a bag pertaining to frequent travel or maybe would like to make an impression on your buddies from the school or even keep pricey Mac pc dust-free, an elegant and stylish laptop computer sleeve will offer you a exciting completely new solution to communicate by yourself. In addition, university students can personalize their particular bags with slogans, piece of art and 3d stickers. However, when selecting some sort of laptop instance with regard to established objective observe the expertise of the cushioning, the high quality and also quantity of zips as well as compartments, and also the sizing along with the model of this bag. Laptop masturbator sleeves as well as digital faces appear more elegant because they are slender and fashionable. In addition, they provide unique protection to netbooks although reducing further large. There are a number regarding back packs you can buy, select the color and design that are great for your personal style and also enhance your personality. Only a advice: opt for the 1 keep your equipment cushioning and protected. http://www.hermesbeltsbirkinkellybag.co.uk/ These days, there are numerous brands that provide good quality bags along with back packs for just a laptop. Here's a report on many well-known along with famous laptop bags manufacturers: Belkin, Circumstance Judgement, Items, Kara, Quik silver, Traveling Azure and also this number really is limitless. Branded notebook computer instances can be found in numerous types of shapes, styles and colors, by elegant natural leather situations to modify back packs. Leather laptop bags it's really important fashionable. These models in addition show off their most recent selection in internet shopping centers; you will get pleasant notebook computer bags inside rupees 1000. Custom as well as personalised notebook computer masturbator sleeves likewise make great corporate gifts, small business discount items or a good current with special events similar to Anniversaries, and so on. Nowadays, every person likes to produce his/her own individualized bag, in particular young people. There are a variety connected with manufacturers that allow individuals to personalize their bag to adjust to the personality from the individual, in conjunction with installing the idea to your distinct wants. Laptop computer bag types can be published with all the company logo within the need for the company and can be purchased at an exceptionally low price. Brand name custom made laptop bags are for sale for everyone.

Comment by stephanieg915 6 days ago

www.canadagoosefemmehomme2016.fr/canada-goose-parka_61.html

www.canadagoosefemmehomme2016.fr/canada-goose-expedition-homme_207.html

www.canadagoosefemmehomme2016.fr/logo-canada-goose_138.html

www.canadagoosefemmehomme2016.fr/parka-canada-goose-langford_425.html

www.canadagoosefemmehomme2016.fr/canada-goose-pas-cher-enfant_337.html

www.canadagoosefemmehomme2016.fr/parka-canada-goose-occasion_186.html

www.canadagoosefemmehomme2016.fr/canada-goose-cramoisi_47.html

www.canadagoosefemmehomme2016.fr/doudoune-canada-goose-femme-prix_362.html

www.canadagoosefemmehomme2016.fr/canada-goose-tuque_58.html

www.canadagoosefemmehomme2016.fr/nouvelle-collection-canada-goose_451.html

www.canadagoosefemmehomme2016.fr/canada-goose-fabrication_275.html

www.canadagoosefemmehomme2016.fr/canada-goose-point-de-vente_371.html

www.canadagoosefemmehomme2016.fr/canada-goose-snow-mantra_209.html

www.canadagoosefemmehomme2016.fr/canada-goose-resolute_66.html

www.canadagoosefemmehomme2016.fr/yukon-bomber-canada-goose_147.html

www.canadagoosefemmehomme2016.fr/canada-goose-the-chateau_364.html

www.canadagoosefemmehomme2016.fr/adresse-magasin-canada-goose-montreal_297.html

www.canadagoosefemmehomme2016.fr/pantalon-canada-goose_315.html

www.canadagoosefemmehomme2016.fr/doudoune-canada-goose-pour-femme_475.html

www.canadagoosefemmehomme2016.fr/revendeur-canada-goose_106.html

www.canadagoosefemmehomme2016.fr/canada-goose-pour-b��b��_146.html

www.canadagoosefemmehomme2016.fr/parka-canada-goose_120.html

Comment by sguerra376 4 days ago

http://www.canadagoosefemmehomme2016.fr/vetement-goose-canada_345.html

http://www.canadagoosefemmehomme2016.fr/forum-canada-goose_60.html

http://www.canadagoosefemmehomme2016.fr/manteau-hiver-canada-goose_480.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-laval_347.html

http://www.canadagoosefemmehomme2016.fr/doudoune-canada-goose-femme_68.html

http://www.canadagoosefemmehomme2016.fr/blouson-canada-goose-pas-cher_78.html

http://www.canadagoosefemmehomme2016.fr/goose-canada_169.html

http://www.canadagoosefemmehomme2016.fr/revendeur-canada-goose-france_401.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-canada-prix_284.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-montebello-femme_373.html

http://www.canadagoosefemmehomme2016.fr/manteau-type-canada-goose_369.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-parka-femme_349.html

http://www.canadagoosefemmehomme2016.fr/doudoune-canada-goose-rose_421.html

http://www.canadagoosefemmehomme2016.fr/point-de-vente-canada-goose_304.html

http://www.canadagoosefemmehomme2016.fr/livigno-canada-goose_72.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-logo_212.html

http://www.canadagoosefemmehomme2016.fr/bonnet-canada-goose_289.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-xxs_391.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-calgary_278.html

http://www.canadagoosefemmehomme2016.fr/casquette-canada-goose_134.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-foxe_91.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-parajumpers_49.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-grise-femme_269.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-site-officiel_57.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-blanc_171.html

Comment by sguerra376 4 days ago

http://www.canadagoosefemmehomme2016.fr/canada-goose-femme-rouge_59.html

http://www.canadagoosefemmehomme2016.fr/logo-canada-goose_138.html

http://www.canadagoosefemmehomme2016.fr/expedition-parka-canada-goose_210.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-grande-taille_92.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-bomber_402.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-pas-cher-femme_305.html

http://www.canadagoosefemmehomme2016.fr/point-de-vente-canada-goose_304.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-payer-en-3-fois_242.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-whistler_318.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-accessoires_183.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-blouson-aviateur-chilliwack-homme_321.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-fabrication_275.html

http://www.canadagoosefemmehomme2016.fr/doudoune-homme-canada-goose-pas-cher_204.html

http://www.canadagoosefemmehomme2016.fr/marque-doudoune-canada-goose_74.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-pas-cher-france_142.html

http://www.canadagoosefemmehomme2016.fr/vente-doudoune-canada-goose-femme_197.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-dawson-parka_374.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-sans-fourrure_311.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-montebello-noir_170.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-femme-pas-cher_139.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-��-paris_227.html

http://www.canadagoosefemmehomme2016.fr/solaris-parka-canada-goose_110.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-parka-langford_176.html

http://www.canadagoosefemmehomme2016.fr/canada-goose-femme-bleu-marine_151.html

Comment by sguerra376 4 days ago

www.canadagoosefemmehomme2016.fr/doudoune-homme-canada-goose_366.html

www.canadagoosefemmehomme2016.fr/acheter-une-canada-goose_177.html

www.canadagoosefemmehomme2016.fr/canada-goose-accessoires_183.html

www.canadagoosefemmehomme2016.fr/magasin-canada-goose-new-york_396.html

www.canadagoosefemmehomme2016.fr/doudoune-canada-goose-montebello-femme_128.html

www.canadagoosefemmehomme2016.fr/canada-goose-pour-enfant_217.html

www.canadagoosefemmehomme2016.fr/canada-goose-chilliwak_109.html

www.canadagoosefemmehomme2016.fr/parka-canada-goose-pas-cher_358.html

www.canadagoosefemmehomme2016.fr/canada-goose-payer-en-plusieurs-fois_152.html

www.canadagoosefemmehomme2016.fr/prix-canada-goose-enfant_75.html

www.canadagoosefemmehomme2016.fr/parka-canada-goose-soldes_241.html

www.canadagoosefemmehomme2016.fr/canada-goose-montebello-noir_170.html

www.canadagoosefemmehomme2016.fr/canada-goose-cramoisi_47.html

www.canadagoosefemmehomme2016.fr/parka-goose-canada_46.html

www.canadagoosefemmehomme2016.fr/canada-goose-milan_99.html

www.canadagoosefemmehomme2016.fr/canada-goose-kensington-parka-femme_448.html

www.canadagoosefemmehomme2016.fr/canada-goose-solaris_107.html

www.canadagoosefemmehomme2016.fr/doudoune-canada-goose-paris_144.html

www.canadagoosefemmehomme2016.fr/canada-goose-homme-pas-cher_440.html

www.canadagoosefemmehomme2016.fr/leboncoin-canada-goose_481.html

www.canadagoosefemmehomme2016.fr/canada-goose-homme-solde_255.html

www.canadagoosefemmehomme2016.fr/doudoune-homme-canada-goose-pas-cher_204.html

www.canadagoosefemmehomme2016.fr/destockage-canada-goose_286.html

www.canadagoosefemmehomme2016.fr/canada-goose-prix-usa_359.html

www.canadagoosefemmehomme2016.fr/canada-goose-femme-bleu-marine_151.html

www.canadagoosefemmehomme2016.fr/acheter-doudoune-canada-goose_258.html

www.canadagoosefemmehomme2016.fr/doudoune-style-canada-goose_283.html

Comment by sguerra376 3 days ago

www.canadagoosefemmehomme2016.fr/constable-parka-canada-goose_97.html

www.canadagoosefemmehomme2016.fr/manteau-hiver-canada-goose_480.html

www.canadagoosefemmehomme2016.fr/mystique-parka-canada-goose_229.html

www.canadagoosefemmehomme2016.fr/canada-goose-xxs_391.html

www.canadagoosefemmehomme2016.fr/canada-goose-chateau-parka_247.html

www.canadagoosefemmehomme2016.fr/chilliwack-bomber-canada-goose_372.html

www.canadagoosefemmehomme2016.fr/canada-goose-a-montreal_306.html

www.canadagoosefemmehomme2016.fr/doudoune-homme-canada-goose_366.html

www.canadagoosefemmehomme2016.fr/achat-canada-goose-en-ligne_153.html

www.canadagoosefemmehomme2016.fr/whistler-parka-canada-goose_309.html

www.canadagoosefemmehomme2016.fr/canada-goose-moncler_415.html

www.canadagoosefemmehomme2016.fr/canada-goose-femme-noir_48.html

www.canadagoosefemmehomme2016.fr/canada-goose-femme-solde_457.html

www.canadagoosefemmehomme2016.fr/canada-goose-femme-victoria_285.html

www.canadagoosefemmehomme2016.fr/revendeur-canada-goose_106.html

www.canadagoosefemmehomme2016.fr/parka-femme-canada-goose_336.html

www.canadagoosefemmehomme2016.fr/manteau-canada-goose-homme_279.html

www.canadagoosefemmehomme2016.fr/promo-canada-goose_263.html

www.canadagoosefemmehomme2016.fr/veste-canada-goose-solde_198.html

www.canadagoosefemmehomme2016.fr/canada-goose-vrai_249.html

www.canadagoosefemmehomme2016.fr/rideau-canada-goose_303.html

www.canadagoosefemmehomme2016.fr/canada-goose-citadel_470.html

www.canadagoosefemmehomme2016.fr/parka-canada-goose-chateau_400.html

Comment by sguerra376 2 days ago

Your point of view

You must be signed in to comment.