wakapi/README.md

29 lines
1.5 KiB
Markdown
Raw Normal View History

2019-05-06 01:58:01 +03:00
# wakapi
## Usage
* Create an empty MySQL database
2019-05-11 21:32:35 +03:00
* Clone repository
* Copy `.env.example` to `.env` and set database credentials
2019-05-11 21:32:35 +03:00
* Install dependencies: `go get -d ./...`
* Set target port in `config.ini`
2019-05-20 21:54:18 +03:00
* Build executable: `go build`
* Run server: `./wakapi`
* Edit your local `~/.wakatime.cfg` file and add `api_url = https://your.server:someport/api/heartbeat`
**First run** (create user account): When running the server for the very first time, the database gets populated. Afterwards you have to create yourself a user account. Until proper user sign up and login is implemented, this is done via SQL, like this.
* `mysql -u yourusername -p -H your.hostname`
* `USE yourdatabasename;`
* `INSERT INTO users (id, api_key) VALUES ('your_cool_nickname', '728f084c-85e0-41de-aa2a-b6cc871200c1');` (the latter value is your api key from `~/.wakatime.cfg`)
2019-05-11 21:32:35 +03:00
## Todo
* Persisted summaries / aggregations (for performance)
2019-05-11 21:32:35 +03:00
* User sign up and log in
* Additional endpoints for retrieving statistics data
2019-05-20 21:56:27 +03:00
* Dockerize
* Unit tests
## Important note
**This is not an alternative to using WakaTime.** It is just a custom, non-commercial, self-hosted application to collect coding statistics using the already existing editor plugins provided by the WakaTime community. It was created for personal use only and with the purpose of keeping the sovereignity of your own data. However, if you like the official product, **please support the authors and buy an official WakaTime subscription!**
2019-05-06 01:58:01 +03:00
## License
GPL-v3 @ [Ferdinand Mütsch](https://muetsch.io)