mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-22 06:53:52 +00:00
add sync doc to readme
This commit is contained in:
parent
cfc17acd20
commit
8602313230
|
@ -216,12 +216,7 @@ DB_DSN=bbgo.sqlite3
|
|||
|
||||
Once you have your database configured, you can sync your own trading data from the exchange.
|
||||
|
||||
To sync your own trade data:
|
||||
|
||||
```sh
|
||||
bbgo sync --session max
|
||||
bbgo sync --session binance
|
||||
```
|
||||
See [Configure Sync For Private Trading Data](./doc/configuration/sync.md)
|
||||
|
||||
## Using Redis to keep persistence between BBGO sessions
|
||||
|
||||
|
|
33
doc/configuration/sync.md
Normal file
33
doc/configuration/sync.md
Normal file
|
@ -0,0 +1,33 @@
|
|||
# Sync Private Trading Data
|
||||
|
||||
You can use the following configuration (add this to your bbgo.yaml) to sync your private trading data, like closed orders and trades:
|
||||
|
||||
```yaml
|
||||
sync:
|
||||
# since is the date you want to start sync
|
||||
since: 2019-11-01
|
||||
|
||||
# if you have multiple sessions defined, but you don't want to sync all sessions, you can define a list here
|
||||
sessions:
|
||||
- binance
|
||||
- max
|
||||
|
||||
# symbols is the symbol you want to sync
|
||||
# If not defined, BBGO will try to guess your symbols by your existing account balances
|
||||
symbols:
|
||||
- BTCUSDT
|
||||
- ETHUSDT
|
||||
- LINKUSDT
|
||||
```
|
||||
|
||||
Then you can start syncing by running the following command:
|
||||
|
||||
```shell
|
||||
bbgo sync --config config/bbgo.yaml
|
||||
```
|
||||
|
||||
Or just (if you have bbgo.yaml is the current working directory):
|
||||
|
||||
```shell
|
||||
bbgo sync
|
||||
```
|
Loading…
Reference in New Issue
Block a user