External Editors

As someone with and unhealthily relationship with text editors. I have just switched again, but this time to TextMate. I would like for Devonthink to support external editors. ODB Editor Suite looks to be the closest thing to being a standard on the mac for just this feature. It also looks simple to use.

Thanks for the great product.
-Jeremy

What do you mean by support?

DTPro has an “open with” toolbar item and contextual menu.

95% of what I use DTPro for is text documents and snippets. When I edit them with the “open with” menu item saves do not get reflected in DTPro.

Maybe I am doing something wrong.

I have an applescript that does this back and forth with the data, but this does not have the nice features that ODB Editor Suite does.

-Jeremy

Caution: “Open With” does not mean the same as “Edit With” – changes made to such a document will not be saved in DT Pro. Actually, if you use Save after such an edit, the document will be saved in a temporary folder that will be emptied when DT Pro is closed. If you want to edit files with an external text editor, you should use Save As to save changes, then import the altered file into DT Pro.

I can’t comment on whether your AppleScript script is actually reflecting the changes back into your database, or could be modified to do so – I don’t know what it does.

I’m assuming you are editing program code or other text with special format or structure requirements. For simple editing of text, of course, that can be done directly in DT Pro.

Version 2.0 of DT Pro will make it much easier to handle such situations, so that a document opened under another application can be edited, and text changes will be reflected in the database.

Just takes the current text copies it to a temp file, opens a Textmate session on the temp file. In the Textmate I have another applescript that replaces the text back into DBPro. The problems are I can not move around in the DBPro database. And if I forget and just save and not the applescript I lose everything :frowning: I could dive deeper into the applescript for Devonthink and make this better. In fact I think I will.

You guessed right I do write almost always in a structured format [markdown (my perferred) html, python, Cisco and Juniper cli, windows ini, many others].

Glad to hear it.

Why not just use Textmate’s global ‘Edit in Textmate…’ command. Anytime your cursor is in a Cocoa textbox you should be able to Chose Edit->Edit in Textmate… or just hit control-command E.

This will open the text in Textmate. Do your edits, then save and close. You will be returned to the window where you started with your edits you made in effect.

Maybe the Edit in TextMate input manager didn’t exist until after this post was created last November?

One thing that I like about the Aqua version of Graphviz is that it allows you to use any external editor to edit the graph source, but whenever you save the changes, the new file is relayed back to Graphviz, which acts on the new source.

I’m not sure how exactly this works, but it’s a thought. A spotlight trigger?

Just wanted to note that Edit in Textmate works great – assuming of course that your entry is plain text, and not RTF.

John