To copy a file

Ξ September 22nd, 2007 | → 0 Comments | ∇ boring, stuff and junk |

Recently a friend asked me how I would go about copying a file on his Windows machine to the same directory but append the date to the filename in the standard ISO 8601 format (YYYYMMDD) with the leading zeros, of course. At first I gave him the following answer for a windows batch file:

SET myfile=win.ini
FOR /F “tokens=1-4 delims=/ ” %%I IN (’DATE /t’) DO SET mydate=%%L%%J%%K
copy %myfile% %myfile%-%mydate

Which got me to thinking of how to do it in some other languages, out of boredom. So here it is in Classic ASP:

file = “win.ini”
set fs=Server.CreateObject(”Scripting.FileSystemObject”)
fs.CopyFile file, file & “-” & Year(date) & Right(Cstr(100 + Month(date)),2) & Right(Cstr(100 + Day(date)),2)

And the best for last, here it is in PHP:

$file = ‘win.ini’;
if(!copy($file,$file.’-’.date(”YmdHis”))) { echo ‘File copy failed’; }

If you can do this in a language not presented here, please […]

Original post by Maker


Enemy Territory - QUAKE Wars

Ξ September 19th, 2007 | → 0 Comments | ∇ boring |

I installed the Enemy Territory - QUAKE Wars Demo and I must say, it’s far more fun than I had previously anticipated. The first time I installed it, I selected “no” when prompted to install some other software with it. Sadly, this turned out to be Punkbuster which is required on most public servers. I had to uninstall the entire game, then install it again. This time I selected yes, but near the end of the install I was presented with this fun little message about three times:

This had zero effect on the success of the installation, however. I just thought it was funny to present this error to the end user. I giggled. It’s a demo though, so I suppose I’ll let it slide. I recommend checking this out if you get a chance, it’s a lot of fun.

Original post by Maker


Moon Shot

Ξ September 17th, 2007 | → 0 Comments | ∇ photography |

Original post by dram



Ξ September 14th, 2007 | → 0 Comments | ∇ special |

Original post by dram



Ξ September 12th, 2007 | → 0 Comments | ∇ um yeah |

This sums it up.

Original post by Heebus


This I Believe

Ξ September 12th, 2007 | → 0 Comments | ∇ special |

A friend of mine asked me, “What do you believe in?” This is something I’ve given some thought to so I had an answer for him, but it wasn’t as coherent or thought through as I would have liked. I highly enjoy the radio segment on NPR This I Believe. It’s interesting to hear other’s beliefs in their own words and is one of the reasons I’ve put some thought into my own beliefs. In order to force myself to think through my beliefs and to be able to express them more clearly, I’m going to make it a project of mine to write essays about all the things I believe in. Thankfully for you, This I Believe’s website has essay writing tips that I’ll likely need.

Original post by dram


Civil Air Patrol Searching for Steve Fosset

Ξ September 7th, 2007 | → 0 Comments | ∇ special |

CNN Video : Search for Fosset
CAPBlog linked to this great segment about CAP’s efforts in the search for Steve Fosset.
I haven’t talked about CAP at all since relaunching this site, but it’s an organization I’m a part of and very proud of my service to it. I have friends that are out there helping with this search and I truly wish I could be out there with them. Unfortunately, I haven’t had the time to train up for Search and Rescue operations. Even though we likely won’t have another search of this magnitude for quite some time, it will probably prompt me to work towards getting qualified to help in the future.

Original post by dram


  • Rumours and Lies