提交 ea4c2901 编写于 作者: Huan (李卓桓)'s avatar Huan (李卓桓)

doc

上级 19521a3d
......@@ -5,20 +5,19 @@ Connecting ChatBots.
Wechaty is a Bot Framework for Wechat **Personal** Account.
> Easy creating personal wechat bot in 7 lines of javascript code.
> Easy creating personal wechat bot in 9 lines of code.
It supports [linux](https://travis-ci.org/zixia/wechaty), [win32](https://ci.appveyor.com/project/zixia/wechaty) and [darwin(OSX/Mac)](https://travis-ci.org/zixia/wechaty).
[![Join the chat at https://gitter.im/zixia/wechaty](https://badges.gitter.im/zixia/wechaty.svg)](https://gitter.im/zixia/wechaty?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![Coverage Status](https://coveralls.io/repos/github/zixia/wechaty/badge.svg?branch=master)](https://coveralls.io/github/zixia/wechaty?branch=master)
[![Repo Size](https://reposs.herokuapp.com/?path=zixia/wechaty)]()
[![node](https://img.shields.io/node/v/wechaty.svg?maxAge=2592000)](https://nodejs.org/)
[![Coverage Status](https://coveralls.io/repos/github/zixia/wechaty/badge.svg?branch=master)](https://coveralls.io/github/zixia/wechaty?branch=master)
[![npm version](https://badge.fury.io/js/wechaty.svg)](https://badge.fury.io/js/wechaty)
[![dependency status][dependency-image]][dependency-url]
[![dev dependency status][dev-dependency-image]][dev-dependency-url]
[![npm version](https://badge.fury.io/js/wechaty.svg)](https://badge.fury.io/js/wechaty)
[![Repo Size](https://reposs.herokuapp.com/?path=zixia/wechaty)]()
[![Downloads][downloads-image]][downloads-url]
[![Docker Pulls](https://img.shields.io/docker/pulls/zixia/wechaty.svg)](https://hub.docker.com/r/zixia/wechaty/)
[![Docker Stars](https://img.shields.io/docker/stars/zixia/wechaty.svg?maxAge=2592000)](https://hub.docker.com/r/zixia/wechaty/)
# Voice of the Developer
......@@ -33,11 +32,12 @@ It supports [linux](https://travis-ci.org/zixia/wechaty), [win32](https://ci.app
Wechaty is dead easy to use: 7 lines javascript for your 1st wechat bot.
## 1. Basic: 7 lines
The following 7 lines of code implement a bot log all message to console:
The following 7 lines of code implement a bot who can log all message to console:
```javascript
const Wechaty = require('wechaty')
const bot = new Wechaty()
bot
.on('scan', ({url, code}) => console.log(`Scan QrCode to login: ${code}\n${url}`))
.on('login', user => console.log(`User ${user} logined`))
......@@ -59,23 +59,16 @@ Natual Language Understanding enabled by [api.AI](https://api.ai), you can get y
# Deploy
## Deploy with Docker
Wechaty is fully dockerized. So it will be very easy to be deployed as a MicroService.
```shell
$ export TOKEN="your token here"
## Deploy with Heroku
$ docker run -e WECHATY_TOKEN="$TOKEN" zixia/wechaty
```
TBD
`WECHATY_TOKEN` is required here, because you need this key to manage wechaty on the chatbot cloud manager: https://www.wechaty.io
~~Follow [these instructions](https://wechaty.readme.io/docs). Then, [![Deploy to Heroku](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)~~
## Deploy with Heroku
## Deploy with Docker
To Be Fix
TBD
~~Follow [these instructions](https://wechaty.readme.io/docs). Then, [![Deploy to Heroku](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)~~
# Installation
......@@ -457,9 +450,10 @@ Know more about TAP: [Why I use Tape Instead of Mocha & So Should You](https://m
# Version History
## v0.3.0 (master)
## v0.3.2 (master)
1. Managed by Cloud Manager: https://app.wechaty.io
1. Dockerized & Published to docker hub as: [zixia/wechaty](https://hub.docker.com/r/zixia/wechaty/)
1. add `reset` & `shutdown` to IO Event
2. support be managed by https://app.wechaty.io
## v0.2.3 (2016/7/28)
1. add wechaty.io cloud management support: set environment variable `WECHATY_TOKEN` to enable io support
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册