Delete all files in a folder that don't match a certain file extension

2010-04-30 1 min read Bash Fedora Linux

$ rm !(.foo|.bar|*.baz)

Deletes all files in a folder that are NOT *.foo, *.bar or *.baz files. Edit the pattern inside the brackets as you like.

  • <a href="http://www.commandlinefu.com/commands/view/5351/delete-all-files-in-a-folder-that-dont-match-a-certain-file-extension">View this command to comment, vote or add to favourites
  • <a href="http://feeds2.feedburner.com/commands/by/hutch">View all commands by <a href="http://feeds2.feedburner.com/commands/by/hutch">hutch

<a href="http://www.commandlinefu.com"><img src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/header-logo.jpg" alt="" align="bottom" />

by David Winterbottom (<a href="http://codeinthehole.com">codeinthehole.com)

<a href="http://feedads.g.doubleclick.net/~a/kewaFMgsXI4A1vQfeLscg2Vcv8o/0/da"><img src="http://blog.amit-agarwal.com/wp-content/uploads/img.zemanta.com/~a/kewaFMgsXI4A1vQfeLscg2Vcv8o/0/di" alt="" align="bottom" />
<a href="http://feedads.g.doubleclick.net/~a/kewaFMgsXI4A1vQfeLscg2Vcv8o/1/da"><img src="http://blog.amit-agarwal.com/wp-content/uploads/img.zemanta.com/~a/kewaFMgsXI4A1vQfeLscg2Vcv8o/1/di" alt="" align="bottom" />

<img src="http://blog.amit-agarwal.com/wp-content/uploads/img.zemanta.com/~r/Command-line-fu/~4/TCRb2ku_V1Y" alt="" width="1" height="1" align="bottom" />

Continue reading

Lock the hardware eject button of the cdrom

2010-04-29 1 min read Fedora Learning Linux

$ eject -i 1 This command will lock the hardware eject button of your cdrom drive. Some uses are:

1: If you have a toddler and has discovered the cdrom button

2: If you are carrying a laptop in a bag or case and don&#8217;t want it to eject if the button is inadvertently pressed.

To unlock the button use:

eject -i 0

  • <a href="http://www.commandlinefu.com/commands/view/5390/lock-the-hardware-eject-button-of-the-cdrom">View this command to comment, vote or add to favourites
  • <a href="http://feeds2.feedburner.com/commands/by/mdelatorre">View all commands by <a href="http://feeds2.feedburner.com/commands/by/mdelatorre">mdelatorre

<a href="http://www.commandlinefu.com"><img src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/header-logo.jpg" alt="" align="bottom" />

Continue reading

Xoost – Search engine

2010-03-10 0 min read Uncategorized
\"Image
Image via CrunchBase

<a title="Xoost Search engine" href="http://www.xoost.com" target="_blank">Xoost is a community search engine. From Xoost page:

Imagine you are searching for a topic related to your favourite Music, Travel destinations, Events. With Xoost you will benefit from the exponential value of doing it much more productively together with your friends or family members. It’s all about sharing Search skills & Knowledge.

Continue reading

check out http://browsershots.org/

2009-12-19 1 min read Learning Uncategorized

If you are a web developer and are worried about how your <a class="zem_slink" href="http://en.wikipedia.org/wiki/Website" title="Website" rel="wikipedia">website would look like in the various browsers and do not have the resources to test all the browsers, what do you do? Check out the <a class="zem_slink" href="http://en.wikipedia.org/wiki/Web_page" title="Web page" rel="wikipedia">webpage at

<a href="http://browsershots.org/">http://browsershots.org/<h6 class="zemanta-related-title">Related articles by Zemanta <ul class="zemanta-article-ul"> <li class="zemanta-article-ul-li"><a href="http://www.macstories.net/iphone/website-iphone/">Setting Up Your Website to Run on iPhone Browser (macstories.net) <div class="zemanta-pixie"><a class="zemanta-pixie-a" href="http://reblog.zemanta.com/zemified/8d5363f4-7641-40c8-b111-4a4d12d41ba5/" title="Reblog this post [with Zemanta]"><img class="zemanta-pixie-img" src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/reblog_e36.png" alt="Reblog this post [with Zemanta]" /><span class="zem-script more-related more-info pretty-attribution paragraph-reblog">

Continue reading
Newer posts