Use Toto to quickly create a lightweight blog

Source: Internet
Author: User
Tags custom name

ForProgramPersonnel or entrepreneurial teams, it is still necessary to have a blog of their own. WordPress once made it easy for individuals or companies to build blogs. However, we think WordPress is still a heavyweight, so we chose Toto, a very lightweight tool with only over 200 lines.Code.

Prerequisites

Toto is simple because it uses some good tools and services. To use Toto, you must understand this.

1 Ruby on Rails
Rails is the ideal development tool for internet startups. It is suitable for agile development and can quickly develop applications.

2 git
Git is an efficient version management tool. You will fall in love with her and have no choice.

3 Heroku
You need to register a Heroku account and install the Heroku tool locally.
Heroku is a rails application hosting platform. The ideal toto deployment platform is Heroku. With Heroku, you can focus on Rails application development and hand over issues such as server environment and deployment backup to Heroku.

Blog creation in one minute

After the environment is ready, we can start. Follow the Toto installation documentation to build a blog with only four commands. (Replace myblog with your custom name)

$ Git clone git: // Github.com/cloudhead/dorothy.git myblog
$ CD myblog
$ Heroku create myblog
$ Git push Heroku master

So you can access your blog: http://myblog.heroku.com.

How to update a blog?

Let's take a look at the Toto directory structure.

Each blog is a file stored in the articles directory. Creating a blog is to create a file in this directory.
Toto provides a command to help us create a blog

 
Rake new

Enter the title: Hello World
You can refer to the naming rules of a file. The generated file name is 2011-06-07-hello-world.txt. By default, Toto uses this rule to establish a link. This may be a problem in Chinese, because we generally do not want to use Chinese as the file name.
The solution is as follows. For example, if the blog is the world famous, the file name can also be hello-world.txt. You only need to add a line in the file:

 
--- Title: Hello world date: 07/06/2011 slug: hello-world # Add this line

 

Toto is defined using markdown tag syntaxArticleFormat. For detailed syntax rules, see http://en.wikipedia.org/wiki/markdown.

After the article is edited, submit it to Heroku

Rake publish

Refresh to see the update.

This is the blog http://blog.workxp.info built by Toto.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.