Mac OS X Finder and changing extensions.

[prev] [thread] [next] [lurker] [Date index for 2003/09/02]

From: Mark Fowler
Subject: Mac OS X Finder and changing extensions.
Date: 11:13 on 02 Sep 2003
Okay, this thing is driving me insane.

I want to change my foo.html file to foo.tt2.  I want to put some template
code in it.

Will the finder let me do this?  Nope!  I click and change it's extension
and it just changes it.  Keeps the nice HTML icon.  Hey, nice I think.
Everything runs, but ten minutes later my script can't find the file.
Why?  Because it's been renamed to foo.tt2.html.  Argh!

Apparently, if the extension isn't known to the OS then the policy is to
just hide the actual extension and show the name that you've changed the
file to.  This is nice for Ma and Pop when they're using the computer, but
I'M TRYING TO GET SOME WORK DONE, OKAY?  I really need the file to be
called what I renamed it to.

So I try renaming the file foo.txt and sure enough it prompts me, saying
'Are you sure you want to change the extension...'.  So I click 'use .txt'
and the file is renamed to foo.txt (which I check in an xterm, and it
really is called that) Then I change it from foo.txt to foo.tt2.  And it
gives me foo.tt2 in the finder, but the file is now foo.tt2.txt.  No
closer!

So I give up on this.  I use 'mv foo.tt2.txt foo.tt2'.  Huzzah!  The file
is called what it needs to be called.   Except now the finder displays it
as 'foo'.  No extension.

What is going on?  How do I get this thing to stop!  Not even Windows
Explorer is this braindead.

-- 
#!/usr/bin/perl -T
use strict;
use warnings;
print q{Mark Fowler, mark@xxxxxxxxxxxxxx.xxx, http://twoshortplanks.com/};

Generated at 14:02 on 01 Jul 2004 by mariachi 0.52