[TxMt] Re: recognition of file type in pipe

mail at bibiko.de mail at bibiko.de
Wed Nov 7 18:12:36 UTC 2018



> On 7. Nov 2018, at 13:44, Dr Eberhard W Lisse <el at lisse.na> wrote:
> 
> I occasionally want to pipe JSON (or XML, or other formats) like
> 
> 	csvjson file.csv | mate -
> 
> It does display the file but as plain text.

my hack would be 

csvjson file.csv > /tmp/___q.json | mate -m untitled /tmp/___q.json && rm /tmp/___q.json

ergo write to a file with the desired extension first, then open it in TM as ‘untitled’ and finally remove the temporary file.

Option -t for mate doesn’t work either for me.

-Hans


More information about the textmate mailing list