How to use Markdown plugin for Sublime Text 2? - sublimetext2

I'm going to learn the language Markdown to quickly and easily write articles for my website under Wordpress.
To do this, I installed under the Sublime Text 2 plugin Markdown Editing. All delivered normally. Then I create a new document in the editor and assign it a syntax Markdown.
But what to do next? How should I save this file? What do I need to compile the file from the markdown in html? I have not found a good description of how to work with this plugin and how to get ready html-file from the file markup markdown.
Tell me, please.

Apps
For learning Markdown I think Sublime Text may be overkill; it's powerful but adds a lot of complexity. It's a great tool but it isn't where I would start.
Instead I would recommend learning Markdown with simpler writing app like Byword or Mou for Mac, MarkPad for Windows or Editorially for the web.
Still want to use Sublime Text? I'd highly recommend checking out Federico Viticci's article on Sublime Text and Markdown, some of it is Mac specific but since Sublime Text is a cross-platform tool most of what he mentions is as well, it will definitely help you get started.
One of the key things to note is that Markdown Editing isn't an all-in-one tool, it's mostly focused on writing and editing Markdown (See my update below). It's still best to pair it with other Markdown related tools for doing things like converting to HTML.
There's also a little more information on Markdown Editing on Brett Terpstra's site (Brett created it). Here's the introduction post, Brett's pretty responsive so if you have any questions try leaving a comment or contacting him directly.
Saving
Regardless of the editor you use you have a lot of options for saving. Markdown is just plain text so you can save the file as .txt or just about whatever you want. The most popular conventions are .txt, .md, and .markdown. I use .md most of the time.
Converting to HTML
Here again you have a ton of choices. Most text editors that have been designed for Markdown will let you copy or export what you've written as HTML. I usually use the fantastic Marked 2 app which is editor agnostic but it's Mac only. In Sublime Text there are plenty of Markdown converters out there, just search Package Control for Markdown.
If you want the most flexibility possible Pandoc does a whole lot more than just HTML. I use the Pandoc Sublime Text extension.
Another alternative would be to use a Markdown plugin in WordPress so you don't even need to convert it to HTML, just copy and paste it into your WordPress post editor. I haven't used WordPress recently enough to recommend one specifically but I know there are some very solid options there.
Finally, Byword has an optional WordPress extension you can buy if that appeals to you.
Learning Markdown
One last note, there are some great resources out there for learning the language itself. The spec is certainly comprehensive but can be a little intimidating. Lifehacker has a decent introduction but the resource I always recommend is the book Markdown by David Sparks & Eddie Smith. It does focus on Mac and iOS tools but the language is the same everywhere, still if Apple tools and screenshots are a problem best to try something else.
I hope that helps!
Update: MarkdownEditing
Looks like my information was a bit out of date regarding the MarkdownEditing package. It does do a little more than just improving markdown writing or editing now and it's development path is now to make it a fully comprehensive Markdown package.
Thanks to Brett for making it a community project and Ali Ayas heading up the project now. Further details on Brett's blog here.

Related

A Better Way to Edit Tumblr Blogs in HTML?

I'm writing blogs on Tumblr using HTML (I use HTML in order to control the content of my blogs flexibly and precisely) and I'm coding with Tumblr's own HTML editor, which is not so bad and I can continue writing in this way. However, there're some points I don't like, e.g.:
I can't adjust the width of the editor window and so the view looks a little compact.
After posting (or saving as draft), the source code will be automatically rearranged, pretty differently from my original version. That includes the line breaks, automatic adding of HTML tags (like </p>), and converting of special characters, like > to > and   to   (displayed as a dot).
My ideal wish is that I can use my own editor (namely Visual Studio Code) to manage my blogs. I could get a more familiar and comfortable working environment, together with useful functions like auto-complete. But there's still a conflict here - Very often I need to use the "Preview on Blog" feature (so that I can check the actual result).
To explain the situation, I describe an odd plan as example here. I could edit the source code using VS Code, during this I copy everything to Tumblr's editor when I need to "Preview on Blog", until posting. And whenever I need to update blogs I do the same work. That is, to keep a synchronous update of my blogs as local HTML files and online on Tumblr. But this way is not pretty convenient.
Is there a magical way to achieve a connection between the local editor and the website? Or, in general, how can I get a more comfortable workspace to write blogs on Tumblr using HTML?
Thanks a lot!
EDIT:
I'm not blogging on Tumblr anymore, I started to set up my own blogging platform using GitHub Pages and Jekyll.
(BTW, the code editor I use has changed from Visual Studio Code to NeoVim.)

What blogging platforms provide tools for developer-bloggers?

I am looking for a blogging platform that has built in tools for programming-related content. For example, I've seen blogs that have line-numbers, color-coded line separation, code-formatting and tool tips for copying and pasting code-samples. Some of these are better than others. (I'm sure I'm not the only one here who gets annoyed by blog entries with posted source that you can't copy without also copying all the line numbers). So, my question is what blogging-platform does the community recommend for a developer-oriented blog?
er...none that i know of. at the moment, you have to get the bits and pieces together. for my own blog (Blogger, so i'm limited in addons), i use Highlight code converter to generate the display HTML/inline CSS, clean it up a bit (the default settings assume you're creating an entire web page from the code) by removing unnecessary markup, then using it in my blog posts.
Wordpress has the code highligthing feature using some addins, if you are going to host it yourself it will be a very good option to use Wordpress.
BlogDown is a static blogging platform, so it can be hosted on GitHub. You can write posts with markdown files, which has great support for code snippets. You can write your own themes and modules for it also. Unlike Jekkyl, BlogDown does not have a compilations step. You just swap out the markdown files, and you're good to go. It's also worth noting that BlogDown supports custom renderers.

about HTML code [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
What editor or IDE can I use to write html code?
I mean that I write my C++ code in Visual Studio, for example...
so where can I write HTML code?
Have a look at Notepad++ - it's not an IDE but a great editor with syntax highlighting for many languages (such as HTML).
I'm deploying Aptana Studio. Makes a very nice and professional cross-platform developer tool with code hinting not only for (X)HTML but JavaScript/jQuery as well. Very pleased with it.
I can't state the same about Dreamweaver though.
I would suggest using an editor such as Adobe Dreamweaver to begin. However, to answer your question you can write HTML in notepad or any text editor. Simply save the file with a .htm or .html extension, and your file will be executed with any browser.
You can write HTML with any text editor.
But you might want to have a look at Looking for a simple HTML text editor for Windows.
If you want to learn HTML, you should avoid WYSIWYG-editors such as Dreamweaver.
You could use a normal text editor. Powerful editors such as VEDIT have syntax highlighting for HTML and CSS, help entering HTML tags with specific buttons, menu items and snippets, and even have complex functionality for manipulating tables etc.
The advantage of using text editor is that you can use the same tool for all your editing, including programming, so the tool is familiar for you. (However, that may not be your case since you use Visual Studio.)
If you do not use a text editor for other purposes, the best option is to get a dedicated HTML editor, such as HTML Kit. It is a freeware editor specifically created for editing HTML, and it contains lots of useful toos, such as HTML Tidy. But you are still editing the HTML code instead of trying to do "desktop publishing" with WYSIWYG.
More HTML editors can be found from the Wikipedia page Comparison of HTML editors (but that includes WYSIWYG-editors, too).
Read http://www.w3schools.com/html/default.asp for information on HTML
You can write it in whatever texteditor you want, try Aptana Studio for instance. Just save the file with a .HTML or .HTM extension and open the file in you browser.
As Sev says, Dreamweaver is certainly a good tool for beginners.
If you just want to play around in HTML, you can also use an online WYSIWYG editor such as
http://htmledit.squarefree.com/
http://www.online-html-editor.org/
If your goal is to make a website, I would install a CMS such as Wordpress or Joomla. Then you can edit the HTML directly when it is necessary for advanced features, but you don't have to.
You can write HTML in Visual Studio, for example. However, you would usually make a web application in Visual Studio, not just a single HTML page.
I use Notepad to write single HTML pages. It has nothing special that helps you to write HTML, but on the other hand it's as simple as it gets, so nothing gets in your way.
If you write HTML code in Notepad, you have to write everything manually. If you use a software product designed for web development such as Adobe Dreamweaver and MS Expression Web, it will create code for you as you drag and drop controls. You can also look at the code file and edit it when you want.
I do all my web development in gVim. It is hands down the best syntax highlighter/autoindenter I've found, and has tons of little shortcuts that make editing text files very quick.
If you're not doing a ton of development, though, maybe you should just stick to Notepad, as it's something almost everyone is quite familiar with.
Check out w3schools.com for some great tips on getting started with HTML and all the other joyous languages you might want to learn as well.

Templated HTML Editor

I'm looking for a HTML editor that kinda supports templated editing or live snippets or something like that.
Background: I'm working on a website for a friend. As there are no specifications what the webspace/webserver can or can't do, I decided to make it a pure HTML/CSS page, or rather 10 of them. I wrote a template, copied it 10 times and edited the content. And guess what, the template has to be changed.
Therefore I'm looking for a (HTML-)editor that has some kind of live template system where I can edit the content in as it where plain text and then save the project into the 10 pure HTML/CSS files.
I thought about using PHP (the only script language I've some knowledge in), but writing the underlying template script would cost me enough time that I could change all files by hand. I'm not that familiar with AJAX to know if there's a way to load content from another file. If so, this would be an option if there already is a script. With Webdeveloper (firefox extension) I could save the generated source code as HTML/CSS.
Thanks in advance
Edit: any hints how to do this without an editor are welcome
Edit2: In my mind the tool looks like a plain old text editor like SciTe, but capable of editing multiple files simultaneously in the same text area, so it looks like editing one ordinary file, but actually it's a whole bunch of files.
Dreamweaver will do this for you, it's had HTML templating of the type your describe built in from very early versions (because from how you phrase the question I do not think you're thinking along the lines of a PHP templating engine such as Smarty, but some sort of HTML layout formating)
Although I regularly look around for Dreamweaver replacements, and I've certainly been impressed by Aptana, I still tend to use Dreamweaver in my development stack simply because whereas I can compensate for some of the more coding-orientated features it misses, I find the WYSIWYG nature of the editor invaluable.
I would have used a template engine.
I wrote a post about a dead simple script using the Dwoo template engine and mod_rewrite, where I am taking the uri and loading the forrect data and template based on that. You should be able to get it running in a few minutes.
Maybe I am way off on this, but why don't you look into an Open Source Content Management System (PHP/MYSQL)? There are MANY light systems that are not like Drupal, Joomla (if you do not want the big bulk of those CMS's).
There are even a few good ones for light web design that are flat file driven.
That would be my suggestion, at least if not for this project, look into it for future projects.
Here is an example of a great micro CMS that would seem to fit the bill for what you are doing:
http://www.mini-print.com/

How best to write documentation targeting both HTML and PDF? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
Latex-to-html converters I've seen in the past have been pretty awful. Editing raw html is no fun and doesn't seem to translate well to the printed page. How do others solve this problem? Links to examples (both pdf and html) would be great.
Added: Another similar question was just asked:
What formatting language should I use for project documentation
For documenting code, I also recommend Sphinx. ReStructured Text is nice because it is readable and somewhat marked up in plaintext, and can do a nice job converting to html and to pdf. I still like LaTeX for certain things. My wife and I use LaTeX to write our christmas letter, which we mail out via snail mail. The pdf version is pretty fancy, with two columns, and headers and footers. The html version is simpler. I convert with plastex. Examples here:
http://fedibblety.com/annualReports
I don't think any binary format is a good choice (Word) for any sort of document that you might like to read 10 years from now. That is one of the nice things about LaTeX.
Yes, LaTeX-to-HTML converters used to suck (you've probably tried LaTeX2HTML), but of late they've got better. Tex4ht is highly configurable, and produces nice XHTML+CSS. See also other converters.
You can also use Docbook, if you can bear to write in it. There are converters from DocBook to both HTML and LaTeX (or to PDF directly); an example of the latter is dblatex.
See this post: LaTeX vs Docbook.
After many years of anguish and several false starts, I'm about to revisit this, and I'm going to give Sphinx a try. It can generate HTML or LaTeX from ReStructured Text.
I'm hoping it will be a much "lighter" option than full DocBook, but with many of the advantages.
You could take a step back and use something like DocBook and render to PDF via LaTeX and HTML straight from the DocBook files. Alternatively, Adobe Technical Communication Suite (Framemaker) will let you single-source a document to PDF and HTML. See this posting for a rundown on various technical documentation systems.
This is a personal choice but Latex in theory is perfect however in practice it's pain-in-the-arse. I'm using VS.NET HTML editor + raw HTML edit when I need it.
So I think using an WSIWYG HTML editor is best choice. You can always use a simple tool to convert it to PDF, and you can always edit HTML when you need something advanced. Also it's easier to put online when you need.
That's how I'm managing my software documentations and works fine for me.
PlasTeX looks like a nice latex-to-html converter, though I haven't tried it myself.
My friend Rob Felty wrote a blog post extolling its virtues:
http://blog.robfelty.com/2008/03/19/finally-a-better-latex-to-html-converter/
AsciiDoc looks like an interesting possibility.
Read about EPUB format. Its e-book format. http://en.wikipedia.org/wiki/EPUB
Since the answer mentioning Asciidoc was somewhat short on examples, here are some of the things your are looking for:
A pdf generated with Asciidoc
A cheatsheet with a side by side of the Asciidoc markup and the html result.
A list of publications done using Asciidoc, including O'Reilly books and the git documentation (to see both ends of the user scale).
I'm not sure that latex is really the best tool for this. The trouble you're having with the usual latex to html converter is indicative of the problem: html is simple not as expressive as latex.
If you insist on latex to html, take care to use a limited subset that can convert reasonably.
I've used TeXinfo in the past and it does a good job. Here's an example: http://yootles.com/api. I'd prefer to stick with LaTeX though instead of use another language.
If everything else fails you could grab an LaTeX to XML converter and write a simple XSLT stylesheet to convert it to HTML, or create a CSS style sheet and attach it to the XML file directly.
We've been using WebWorks ePublisher (www.webworks.com) which offers both multiple single-source formats (we are using Word) and the ability to output to many output formats (we output to Adobe PDF and Online Help (.CHM).
We were facing this problem in an academic project that involved Eclipse software, and we used plastex to convert Latex to HTML and Eclipse Help. Getting it to work was quite difficult, but the end result looks really nice. You can see all three versions here:
http://handbook.event-b.org/
Further, as this is an open project, the code (build scripts) are available. We have a continuous build system (Jenkins) that rebuilds everything when new Latex is checked in. This is particularly nice, as contributors don't need to install the toolchain on their systems. They just check in the new Latex and check on the server whether the HTML was produced correctly. Sources:
http://sourceforge.net/p/rodin-b-sharp/svn/HEAD/tree/trunk/Handbook/org.rodinp.handbook.feature/
Best, Michael
I don't have enough points to comment, but to bolster the plastex answer, here is the updated plastex example link:
http://robfelty.com/2008/03/19/finally-a-better-latex-to-html-converter
LaTeX? Seriously? I wasn't aware anyone outside academia still used it. I'd go with HTML, which you can save as PDF from the web browser. If you really must have some advanced typographic stuff, go with Word instead - it has a way to save to HTML (probably not as clean as one would like), and you can save as PDF with a free plug-in (downloadable separately).
Oh, and I wouldn't bother using things like InDesign - they are overkill. Also, don't bother paying for Acrobat Professional - there is a zillion free solutions available.