External Editor

How do I set the External Editor in 2.01?

Right now I have hundreds of html files which need editing. The default seems to be Safari - eventhough Firefox is my defaul browser.

Safari is not a text editor and is useless. Very much a pain to have to find the file I imported, edit it, and then re-import it.

Thanks in advance,
Pif

The external editor just uses whatever program on your computer is the default for opening that file type. To change it on your system, open Finder, select a file with the extension you’re working with and “get info,” then choose your preferred application under “open with” (about halfway down) and select it to “change all.”

On the matter of your HTML files—that’s actually something I’ve never given any thought. It hasn’t even come up before. Usually everyone is completely unconcerned with format and just wants the information, so the choice is between webarchive file (which yours probably are since they are opening in Safari instead of the system default, Firefox, which can’t read webarchive files), and rich text conversion, which does its best to convert the HTML layout to RTF. There isn’t, now that I look at it, a way to import a real HTML file into Scrivener and have it stay that way—unless I’m missing something.

So the question is: do you really need the original HTML layout, or is it the text you want, and is it the text you want to edit? If so the rich text options in Import & Export might serve you better. At the moment, otherwise, it doesn’t look like Scrivener is a good storage medium for webpages. Once they are in, they can’t even be exported as HTML—at least not with the original layout.

— Well, you could copy and paste the raw HTML into a text document in Scrivener; or use a bulk rename tool to change .html to .txt before importing. If you are fluent in HTML this might not be too bad. It’s kind of—strange though.

Wikipedia has some good info on editing webarchives. It’s possible if all you need to do is edit a bit of text here and there and don’t need to maintain the original HTML markup, you could make use of one of the options discussed. en.wikipedia.org/wiki/MHTML

Yes, that’s true, I should have mentioned there are tools and ways of editing the textual content and simple styling for webarchives. It’s generally better to just leave it as HTML though, if you need mutable content. I can’t think of any advantage to using webarchive in a mutable fashion. It’s almost as clunky as editing PDFs. It is an option though.

Actually, in 2.0, you can choose the external editor for images and PDF files, so it’s a good point that there is currently no way of doing the same for web pages. I’ll look at refining this so that this feature is available for other research file types too.

Thanks,
Keith

Thanks for all your thoughts and ideas.

The editing is to eliminate distracting text color in the <body or <div elements as well as ads, scripts linking back to the original site.

Changing the meta for html files works in the Finder, but not in Scrivener (still defaults to Safari). I think this might have something to do with the changes AAPL made to how meta data is handled in Leopard/Snow Leopard.

All I want Scrivener to do is to allow the user to pick an external text editor for html files - other programs allow for this option, and NOT default to some arbitrary AAPL System Default.

KB: Here’s another problem importing plain text files:
When I paste text from a web page into a TextEdit Plus file, I always try to include the original html address. Importing this file into Scrivener results in a file with only the web address - all the text is missing.

This seems to be a Scrivener problem, not an AAPL default/meta problem. While TEP is an older app, most ALL of these files have been saved in that format. One can say the fault lies with the older app, except other current, supported, competing apps do NOT have this problem when impoting TEP files - only Scrivener.

I do not want to open hundreds of decades old files and convert them to Rich Text - which I despise - any more than I want to redo or paste all those files into Scrivener. However, It looks like there is no alternative at present.

Thanks in advance,
Pif

Providing one of these files as a sample would help.

Providing one of these files as a sample would help.

Sure. Have an address?

Oh, yes, sorry. :slight_smile: Send a sample to:

support AT literatureandlatte DOT com

I earnestly hope I’m not sticking my amateur nose into an expert discussion … but if I wish to work with text files retaining the HTML structure/markup in Scrivener, I use this simple procedure:

I use Firefox with a bookmark javascript tool called “make.text” ( homepage.mac.com/tjim/ ) which will give me a second window displaying the HTML page I’m viewing, but translated into “markdown” coding. I save this as a pure text file. It’s then extremely easy to edit to get rid of extraneous stuff I don’t want. It’s also lovely in Scrivener as the text file with Markdown coding is easily read.

That “make.text” tool preserves the original URL for easy reference, plus all the links in the original web page.

The free “TextWranger” text editor will convert the markdown text back to html with the “#!” menu dropdown to “unix filters” to run the markdown perl script in TextWranger application support.

I’ve come to regard the text files, which I usually label as “foo.md.txt” to indicate markdown format, as a universal information storage format.

One caveat: make.text does not include an HTML or XML header/footer, but that is easily added if needed.

=GB=