2014-05-06 22:40:29 +08:00
## Introduction
2014-05-05 01:07:19 -07:00
2014-05-08 17:37:46 +08:00
Leanote, a cloud note. You can create your own cloud note by leanote.
2014-05-06 22:40:29 +08:00
## Features
2014-05-07 17:28:01 +08:00
* Knowledge: manage your knowledge in leanote. leanote contains tinymce editor and markdown editor, just enjoy yourself in writting.
2014-05-06 22:40:29 +08:00
* Share: share your knowledge to your friends in leanote. Well, you are not alone, you can invite your friends to join your cloud note and share your knowledge each other.
* Cooperation: collaborate with friends to improve your knowledge.
* Blog: public your knowledge and leanote be your blog.
## Why we create leanote
2014-05-07 17:28:01 +08:00
To be honest, our inspiration comes from evernote, and we use evenote to manage our knowledge everyday. But we find that:
2014-05-06 22:40:29 +08:00
* Evernote's editor can't meet our needs, it hasn't document navigation, can't put our codes(as a programmer, put codes is the basic needs), can't resize images...)
* We like markdown, but evernote don't support it.
2014-05-07 17:28:01 +08:00
* We want to public our knowledge, so we have our blog(such as wordpress) and evernote, but why can't be the one!
2014-05-06 22:40:29 +08:00
* ......
2014-05-06 22:54:05 +08:00
## How to use it
2014-05-07 17:28:01 +08:00
Leanote build with golang(revel) and mongodb. so you must install mongodb at first.
2014-05-06 22:54:05 +08:00
2014-05-06 22:56:38 +08:00
### Install mongodb
2014-05-07 17:28:01 +08:00
For more tips please go https://github.com/leanote/leanote/wiki/mongodb-in-leanote
2014-05-06 22:54:05 +08:00
2014-05-07 17:28:01 +08:00
Go http://www.mongodb.org to download and install it.
2014-05-06 22:59:52 +08:00
### Export initial mongodb data
2014-05-07 17:28:01 +08:00
The mongodb data is in path_to_leante/mongodb_backup/leanote_install_data
2014-05-06 22:59:52 +08:00
```
2014-05-09 15:12:36 +08:00
$> mongorestore -h localhost -d leanote --directoryperdb path_to_leante/mongodb_backup/leanote_install_data
2014-05-06 22:59:52 +08:00
```
2014-05-07 17:28:01 +08:00
The initial data contains two users:
2014-05-07 08:56:19 +08:00
```
user1 username: leanote, password: abc123
user2 username: admin, password: abc123
```
2014-05-06 22:59:52 +08:00
2014-05-07 13:47:12 +08:00
### Configuration
2014-05-06 22:54:05 +08:00
2014-05-07 17:28:01 +08:00
Copy path_to_leante/conf/app-default.conf to path_to_leante/conf/app.conf, the options contains:
2014-05-06 22:54:05 +08:00
2014-05-07 17:28:01 +08:00
``mongodb` ` **required**
2014-05-06 22:54:05 +08:00
2014-05-06 22:56:38 +08:00
```Shell
2014-05-06 22:54:05 +08:00
db.host=localhost
db.port=27017
2014-05-09 15:09:28 +08:00
db.dbname=leanote
db.username=
db.password=
2014-05-06 22:54:05 +08:00
```
``http.port` `
2014-05-07 17:28:01 +08:00
Default is 80
2014-05-06 22:54:05 +08:00
2014-05-07 15:58:58 +08:00
``site.url` `
2014-05-07 17:28:01 +08:00
Default is http://localhost, you must config it when your domain isn't it, it is used when upload images.
``email` `
for find password
2014-05-07 15:58:58 +08:00
2014-05-06 22:54:05 +08:00
``adminUsername` `
2014-05-07 17:28:01 +08:00
Default is admin. The index site is the adminUsername's blog
2014-05-06 22:54:05 +08:00
2014-05-07 17:28:01 +08:00
For more infomation please see app/app.conf and revel manuals http://revel.github.io
2014-05-06 22:54:05 +08:00
2014-05-06 22:56:38 +08:00
### Run leanote
2014-05-07 17:28:01 +08:00
2014-05-07 11:55:08 +08:00
```
2014-05-09 15:12:36 +08:00
$> cd path_to_leanote/bin
2014-05-09 15:13:12 +08:00
$> sudo sh run.sh
2014-05-06 22:56:38 +08:00
```
## How to develop leanote
2014-05-06 22:54:05 +08:00
2014-05-07 17:28:01 +08:00
For more tips please go https://github.com/leanote/leanote/wiki/How-to-develop-leanote
2014-05-07 15:32:08 +08:00
2014-05-07 17:28:01 +08:00
Leanote is a app based on revel(http://revel.github.io), so if you want to develop leanote as you want, you must be familar with revel.
2014-05-07 15:32:08 +08:00
2014-05-07 17:28:01 +08:00
### Install golang
2014-05-07 15:32:08 +08:00
2014-05-07 17:28:01 +08:00
Install golang and set GOPATH
2014-05-07 15:32:08 +08:00
2014-05-07 17:28:01 +08:00
### Install revel
```
go get github.com/revel/revel
go get github.com/revel/cmd/revel
```
2014-05-07 15:32:08 +08:00
2014-05-07 17:28:01 +08:00
### Get leanote
2014-05-07 15:32:08 +08:00
```
2014-05-07 17:28:01 +08:00
go get github.com/leanote/leanote/app
2014-05-07 15:32:08 +08:00
```
2014-05-07 17:28:01 +08:00
### Build/Run leanote via revel
2014-05-09 15:09:49 +08:00
2014-05-09 15:09:28 +08:00
cp conf/routes-default to conf/routes
2014-05-07 17:28:01 +08:00
Now you can modify leanote source and build/run with revel
2014-05-07 15:32:08 +08:00
2014-05-07 17:28:01 +08:00
```
revel run github.com/leanote/leanote
```
2014-05-07 15:32:08 +08:00
2014-05-07 18:05:46 +08:00
Welcome to join with us and contribute your code to leanote! Thanks.