Automatic reload of files from disk

tunc's Avatar


23 Apr, 2014 08:54 PM

  • MultiMarkdown Composer [2.6.9 (53)]
  • OSX 10.9.2

I have a particular OSX system services workflow that takes select text in any editor and appends it to a preexisting file on disk. These are usually some generic comments, and I often need to switch quickly from the source to the newly appended document and customize some of the text that was just appended. In Sublime Text, Byword, MacVim, the changes are picked up immediately and the appended text is shown as soon as I switch to the document. MMDC doesn't automatically reload when the file is appended to, but rather provides access to the revised file through the save dialog.

It is a small issue, and the save-click-to-revert cycle isn't terribly onerous, but I've gotten quite used to the smoother workflow in the other editors. I realize that there are potential hazards to automatic reloading, so this may not be worth tackling. Is it concievable that this could be added as an option in the preferences somewhere?

Thanks for your time,


  1. Support Staff 1 Posted by Fletcher on 23 Apr, 2014 09:07 PM

    Fletcher's Avatar

    Composer uses Apple's NSDocument class, which handles all of these
    things and additionally enables iCloud access in addition to versioning
    and all that good stuff.

    If you use an app that properly works with NSDocument (such as another
    copy of Composer, or Composer running on two networked machines using an
    iCloud document, etc.), these changes are picked up appropriately.

    Modifying a document from the command line does not use the NSDocument
    control from OS X, therefore does not update the document in Composer
    since NSDocument was never notified of a change.

    I do have a new set of features I've been testing that adds some really
    interesting workflow possibilities to Composer, and could be used for
    the sort of workflow you're looking at. It's still in development, and
    I can't promise when it will be available.


  2. 2 Posted by tunc on 24 Apr, 2014 03:37 AM

    tunc's Avatar

    Thanks for the heads up. I'll wait and see what happens on this.

  3. 3 Posted by mathias on 18 Jul, 2014 07:47 AM

    mathias's Avatar

    I'm a Linux/Windows + DropBox user and recently switched to Mac just because of MultiMarkdown Composer (MMDC) - the only Markdown editor with a good support of a ToC (as far as I know).

    I just use my MacBook on the way to work/home and edit some markdown documents. Then it syncs via Dropbox as soon as I'm in the office or home WLAN.

    Unfortunately, MMDC does not recognize inbound file changes, that means a modified document synced from DropBox to the local MacBook.

    I don't know whether DropBox supports the NSDocument control or not but I really need this automatic reload feature.

    Is there any way to activate it for Dropbox or what's the reason why it does not work?

    BTW: I won't switch to iCloud. :-o


  4. Support Staff 4 Posted by Fletcher on 18 Jul, 2014 06:41 PM

    Fletcher's Avatar

    As explained above -- Dropbox doesn't support NSDocument. It makes "dumb" changes to files. Which is fine, but it means that it isn't compatible with apps that do use NSDocument.

    Options are:

    1) Use iCloud -- I get that it's not always a great option, and not an option at all for Windows/Linux
    2) Close documents in Composer when you're not using it, and then reopen when you return.
    3) Wait for the release of some stuff I'm working on -- again, I can't promise a release date.

    As an aside, it can be dangerous to rely on having applications recognize external changes to a open file and reload the file. Not all apps do this correctly, and you can end up losing data (either through poor application logic, or through collisions). In my (limited) testing, NSDocument does a decent job of resolving conflicts, but it's not perfect either.

    I know that "wait for a future product" isn't very satisfying now, but I've been working on some cool things in this area.


    PS> I agree with you about Composer's support for Markdown/MultiMarkdown being better than any other editor out there. And there are even cooler things coming.... ;)

  5. Fletcher closed this discussion on 18 Jul, 2014 06:41 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac