2018-04-24 08:12:38 +00:00
Fathom - simple website analytics
2016-11-19 21:35:23 +00:00
==============================
2018-04-24 08:12:38 +00:00
[![Go Report Card ](https://goreportcard.com/badge/github.com/usefathom/fathom )](https://goreportcard.com/report/github.com/usefathom/fathom)
[![MIT licensed ](https://img.shields.io/badge/license-MIT-blue.svg )](https://raw.githubusercontent.com/usefathom/fathom/master/LICENSE)
2016-12-11 14:23:11 +00:00
2018-04-24 08:12:38 +00:00
This is nowhere near being usable, let alone stable. Please treat as a proof of concept while we work on getting this to a stable state. **Do not run Fathom in production yet unless you like spending time on it.** Things will keep changing for the next few months.
2016-11-24 15:49:30 +00:00
2018-04-24 16:23:24 +00:00
![Screenshot of the Fathom dashboard ](https://github.com/usefathom/fathom/blob/master/assets/dist/img/fathom.jpg?v=6 )
2016-11-25 15:03:47 +00:00
2016-12-11 09:05:29 +00:00
## Installation
2018-04-24 08:12:38 +00:00
For getting a development version of Fathom up & running, please go through the following steps.
2016-12-11 09:05:29 +00:00
2018-04-24 08:12:38 +00:00
1. get code: `go get -u github.com/usefathom/fathom` (or `git clone` repo into your `$GOPATH` )
2017-08-11 14:23:27 +00:00
1. run `npm install` (in code directory) to install all required dependencies
2016-12-11 09:05:29 +00:00
1. Rename `.env.example` to `.env` and set your database credentials.
2017-08-11 14:23:27 +00:00
1. Compile into binary: `make`
2018-04-24 08:12:38 +00:00
1. Create your user account: `fathom register <email> <password>`
2017-08-11 14:23:27 +00:00
1. Run default Gulp task to build static assets: `gulp`
2018-04-24 08:12:38 +00:00
1. Start the webserver: `fathom server --port=8080` & visit **localhost:8080** to access your analytics dashboard.
2016-12-11 09:05:29 +00:00
2018-04-24 08:12:38 +00:00
To start tracking, include the following JavaScript on your site and replace `yourfathom.com` with the URL to your Fathom instance.
2016-11-25 15:03:47 +00:00
```html
2018-04-24 08:12:38 +00:00
<!-- Fathom - simple website analytics - https://github.com/usefathom/fathom -->
2016-11-25 15:03:47 +00:00
< script >
2018-04-24 08:12:38 +00:00
(function(f, a, t, h, o, m){
a[h]=a[h]||function(){
(a[h].q=a[h].q||[]).push(arguments)
2016-11-25 15:03:47 +00:00
};
2018-04-24 08:12:38 +00:00
o=f.createElement('script'),
m=f.getElementsByTagName('script')[0];
o.async=1; o.src=t;
m.parentNode.insertBefore(o,m)
})(document, window, '//yourfathom.com/tracker.js', 'fathom');
fathom('setTrackerUrl', '//yourfathom.com/collect');
fathom('trackPageview');
2016-11-25 15:03:47 +00:00
< / script >
2018-04-24 08:12:38 +00:00
<!-- / Fathom -->
2016-11-25 15:03:47 +00:00
```
2016-12-11 09:05:29 +00:00
2018-04-24 16:24:55 +00:00
## Copyright and license
2016-12-11 09:05:29 +00:00
2018-04-24 16:24:55 +00:00
MIT licensed. Fathom and Fathom logo are trademarks of Fathom Analytics.