From a15ea17f8d38ea43cc90cd537532cfbd8dd61caf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bahattin=20=C3=87ini=C3=A7?= Date: Thu, 23 May 2024 13:25:57 +0300 Subject: [PATCH] fix: Updated readme file --- README.md | 34 +++++++++++++++++++++++----------- 1 file changed, 23 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 94a7570..c329aa8 100644 --- a/README.md +++ b/README.md @@ -2,18 +2,30 @@ Virtualize Your Strava Workouts -## How to get access token +## Build -Follow the following document to get Access token +``` +git clone git@github.com:bahattincinic/fitwave.git +cd fitwave +make +``` -https://developers.strava.com/docs/getting-started/#:~:text=Access%20tokens%20are%20required%20for,tokens%20expire%20every%20six%20hours. +## Run -Step 1: -http://www.strava.com/oauth/authorize?client_id=30980&response_type=code&redirect_uri=http://localhost/exchange_token&approval_prompt=force&scope=read,activity:read +Run project with the following command; -Step2: -curl -X POST https://www.strava.com/oauth/token \ --F client_id=30980 \ --F client_secret=d8d5256cc59c20e49d984d412377604e8dfb6052 \ --F code=fe297327dc6a6ddd5e81705e25dc248f7dda2a88 \ --F grant_type=authorization_code + ./fitwave + +If you need to override the configuration, create .env file + +## Environment Variables + +| Field Name | Type | Default | Options | +|-----------------------|---------|------------|-------------------------------------------------------------------------------------| +| ENV | string | local | - local
- testing
- production | +| LOG_LEVEL | string | debug | - debug
- info
- warn
- error
- panic
- fatal | +| LOG_OUTPUT | string | stdout | - stdout
- /foo/bar/fitwave.log | +| DATABASE_DSN | string | fitWave.db | - fitWave.db
- host=db user=postgres password=postgres dbname=fitwave port=5432 | +| DATABASE_TYPE | string | sqlite | - mysql
- postgresql
- sqlite | +| DATABASE_AUTO_MIGRATE | boolean | true | - true
- false | +| API_PORT | integer | 9000 | |