[TxMt] Re: Another suggestion: open with TextMate

Freek Dijkstra freek at macfreek.nl
Sun Dec 11 23:55:37 UTC 2005


Sune Foldager wrote:
> On 12/12/2005, at 0.08, Freek Dijkstra wrote:
> 
>> Allan Odgaard wrote:
>>> Single-click opens it in TextMate, double-click in the 
>>> Finder--assigned application. In addition you can right-click and 
>>> select “Open «file» in New Window”.
>>
>> No, it doesn't. It highly depends on the type of file. Today, I spent 
>> 15 minutes to find a reproducible example, but couldn't find one.
> 
> Right click on the file and 'treat as text file' or whatever it's 
> called? Textmate keeps a list of extensions it considers text files. 
> This might of course be a problem with no-extension files, I am not sure.

It's specifically about files without an extension. Though I attempt to 
give all files I create a good extension, some files just don't have one 
by default, like the "README" and "INSTALLATION" files you sometimes see 
in a freshly downloaded folder with source files.

Of course, I can quickly go to the finder and rename the file, but that 
would more or less defeat the ease-of-use of TextMate.

In those cases I get a contextual menu with these options:
   New File...
   Add Existing Files...
   Rename...
   Remove Selected Files...
   --
   Open Selected File in New Window (disabled)
   Reveal "README" In Finder
   No Alternative Application for "README" (disabled)
   Show Information... (disabled)
   --
   New Folder
   Group Selected Files (disabled)
   --
   Treat Files with ".txt" as Text (disabled)

The "Treat Files with ".txt" as Text" shows the extension of the 
previously selected file, which in this case was a .txt file, but if I 
previously had selected a .doc file, it would have said ".doc" and still 
be disabled. A slight visual bug, nothing serious.

Note that a missing file extension is not the only reason why TextMate 
does not want to open the file. For example, I downloaded Owen's file:

mkdir testfolder; cd testfolder
wget http://backspaces.net/files/misc
head misc > misc1

If I then open testfolder (i.e. "mate testfolder"), I get a drawer with 
misc and misc1. TextMate opens misc1 without problems, but refuses to 
display the content of misc. "file" give the same result for both files:
"Bourne shell script text executable".

Regards,
Freek



More information about the textmate mailing list