r3dux.org

A number-pimping side project from the valleys in *NEW* upside-down flavour.

  • Home
  • ABOUT
  • OLD SITE
  • SEARCH
  • FEEDBACK

Perfect timing

r3dux | January 30, 2011

Bubble Bursting

Comments
No Comments »
Categories
Imagery
Tags
Bubble, Bursting
Comments rss Comments rss
Trackback Trackback

How To: Remove all desktop.ini (or indeed any recurring) files in Linux

r3dux | January 29, 2011

I spent a while going through my music hive today, just putting music I’d ripped and dumped into the New folder into the correct spot, placing all albums by the same band into a folder called the band name etc, and there’s a hella lot of desktop.ini and Thumbs.db files floating around. This might be useful for people running Windows, but I’m not (or at least not anymore, and not for a long, long time) – so lets be rid of them, shall we?

Blatantly Unnecessary Warning: Deleting files deletes files! Fo’ real, yo! So try out the “tester” script before unconditionally deleting things you might now want to! =D

Measure Twice, Cut Once

Before we delete files en masse – let’s check to see what files we’re opting to remove. To do this, and assuming we want to check what desktop.ini files we can remove, just enter something along the lines of the following into the bash:

find path-to-folder -name desktop.ini

For example, if my music is stored on my NAS at /mnt/Share/_Serva, then to check what files will be removed, I’ll enter:

find /mnt/Share/_Serva -name desktop.ini

After hitting return on the above, you should be given a list of instances of files called desktop.ini and we get to put our minds at ease that it’s not even thinking about adding any other files (such as mp3s or what-have-you) to the list.

Cease and Desist

Once we’re happy we’re going to remove only the files we want gone, to interactively delete all the desktop.ini files from a given folder and any subfolders (and by interactively, I mean it’ll ask you whether you want to delete each one), enter the following command into the bash:

find path-to-folder -name desktop.ini -exec rm -i {} \;

So in my instance, to interactively (i.e. I’d then have to confirm each delete) remove all instances of desktop.ini, I’d enter:

find /mnt/Share/_Serva -name desktop.ini -exec rm -i {} \;

If I wanted to automatically remove all copies of files named desktop.ini without confirming each deletion, then I can just strip off the -i switch, leaving:

find path-to-folder -name desktop.ini -exec rm {} \;

You can then do the same thing for Thumbs.db or any other filename just by substituting the appropriate details after the -name switch.

Done & done =D

P.S. Just for the record, removing the -i will make the deletion occur automatically unless the file is write-protected, but you can always sudo that away, just like the request for a sandwich.

Credits & thanks: MegaJim over on Ubuntu Forums.

Comments
No Comments »
Categories
Coding, Linux
Tags
Bash, delete, desktop.ini, erase, Remove, Thumbs.db
Comments rss Comments rss
Trackback Trackback

Two can play that game

r3dux | January 28, 2011

Shark Comic

Zing! =P

Comments
No Comments »
Categories
Humour, Imagery
Tags
Comic, Disguise, Prank, Shark
Comments rss Comments rss
Trackback Trackback

How a Bail-out Works

r3dux | January 27, 2011

Interesting quote from the Financial Times:

The rain beats down on a small Irish town. The streets are deserted. Times are tough. Everyone is in debt and living on credit. A rich German arrives at the local hotel, asks to view its rooms, and puts on the desk a €100 note. The owner gives him a bunch of keys and he goes off for an inspection.

As soon as he has gone upstairs, the hotelier grabs the note and runs next door to pay his debt to the butcher. The butcher hurries down the street to pay what he owes to his feed merchant. The merchant heads for the pub and uses the note to pay his bar bill. The publican slips the note to the local hooker who’s been offering her services on credit. She rushes to the hotel to pay what she owes for room hire. As she puts the €100 note on the counter, the German appears, says the rooms are unsuitable, picks up his €100 note and leaves town.

No one did any work. No one earned anything. Everyone is out of debt. Everyone is feeling better. And that is how a bail-out works.

Comments
7 Comments »
Categories
Life
Tags
Bail-out, Money, Quote
Comments rss Comments rss
Trackback Trackback

Genesis Chapter 1 (OpenGL Version)

r3dux | January 22, 2011

I ordered a copy of the OpenGL SuperBible (5th Edition) the other day, because I really can’t make the transition away from fixed-pipeline OpenGL without it, and I thought I’d take a quick look at the book review on slashdot – where I found this gem in the comments…

1:1 – In the beginning God created the heaven and the earth.

1:2 – And the earth was without form, and void; and darkness was upon the face of the deep. And the Spirit of God moved upon the face of the waters.

1:3 – And God typed,

glEnable(GL_LIGHTING);

…but there was no light, for GL_LIGHTING is deprecated in OpenGL 3.0, and even in 2.0 there’s like five other settings that He would have had to enable to get anything to display.

1:4 – And God went back to the NeHe tutorial, and it was good, but somewhat out-of-date.

LoLz! =D

Comments
1 Comment »
Categories
Coding, Humour
Tags
Genesis, OpenGL, Slashdot
Comments rss Comments rss
Trackback Trackback

« Previous Entries

Translate

Categories

Archives

Tags

3D ActionScript ActionScript 3.0 Adobe AI Ballarat Bash C++ Class Convert CS4 Effect Error Film Flash GLSL Gnome Hack How-To install Jaunty Java Kinect Linkage Linux Mash-Up Microsoft Motion OpenGL Particle Problem PS3 Remix Retro script Slides Sound Systems Texture Ubuntu Video VirtualBox Wii Windows XBox

Gamercard

OpenR3dux

Misc.

Flattr this

RSS Feed

r3dux twitter feed



“The distance doesn't matter; it is only the first step that is difficult.”

 - Marquise de Deffand

rss Comments rss valid xhtml 1.1 design by jide powered by Wordpress get firefox