diff --git a/README.md b/README.md index 48b9d7809..e06b09274 100644 --- a/README.md +++ b/README.md @@ -40,7 +40,7 @@ would be great if you can use their referral code as your support to them. :-D The following script will help you set up a config file, dotenv file: -``` +```sh bash <(curl -s https://raw.githubusercontent.com/c9s/bbgo/main/scripts/setup-grid.sh) ``` @@ -62,7 +62,7 @@ go get -u github.com/c9s/bbgo/cmd/bbgo Add your dotenv file: -``` +```sh # if you have one BINANCE_API_KEY= BINANCE_API_SECRET= @@ -82,20 +82,20 @@ Prepare your dotenv file `.env.local` and BBGO yaml config file `bbgo.yaml`. The minimal bbgo.yaml could be generated by: -```shell +```sh curl -o bbgo.yaml https://raw.githubusercontent.com/c9s/bbgo/main/config/minimal.yaml ``` To sync your own trade data: -``` +```sh bbgo sync --session max bbgo sync --session binance ``` If you want to switch to other dotenv file, you can add an `--dotenv` option or `--config`: -``` +```sh bbgo sync --dotenv .env.dev --config config/grid.yaml --session binance ``` @@ -145,14 +145,14 @@ Botfather will response your a bot token. *Keep bot token safe* Set `TELEGRAM_BOT_TOKEN` in the `.env.local` file, e.g., -```shell +```sh TELEGRAM_BOT_TOKEN=347374838:ABFTjfiweajfiawoejfiaojfeijoaef ``` For the telegram chat authentication (your bot needs to verify it's you), if you only need a fixed authentication token, you can set `TELEGRAM_AUTH_TOKEN` in the `.env.local` file, e.g., -```shell +```sh TELEGRAM_BOT_AUTH_TOKEN=itsme55667788 ``` @@ -168,7 +168,7 @@ Done! your notifications will be routed to the telegram chat. Put your slack bot token in the .env.local file: -```shell +```sh SLACK_TOKEN=xxoox ``` @@ -184,7 +184,7 @@ and asset calculation. To use MySQL database for data syncing, first you need to install your mysql server: -```shell +```sh # For Ubuntu Linux sudo apt-get install -y mysql-server ``` @@ -193,13 +193,13 @@ Or [run it in docker](https://hub.docker.com/_/mysql) Create your mysql database: -```shell +```sh mysql -uroot -e "CREATE DATABASE bbgo CHARSET utf8" ``` Then put these environment variables in your `.env.local` file: -```shell +```sh DB_DRIVER=mysql DB_DSN=root@tcp(127.0.0.1:3306)/bbgo ``` @@ -208,7 +208,7 @@ DB_DSN=root@tcp(127.0.0.1:3306)/bbgo Just put these environment variables in your `.env.local` file: -```shell +```sh DB_DRIVER=sqlite3 DB_DSN=bbgo.sqlite3 ``` @@ -316,14 +316,14 @@ import ( Create your go package, and initialize the repository with `go mod` and add bbgo as a dependency: -``` +```sh go mod init go get github.com/c9s/bbgo@main ``` Write your own strategy in the strategy file: -``` +```sh vim strategy.go ``` @@ -331,7 +331,7 @@ You can grab the skeleton strategy from