|
|
пре 4 месеци | |
|---|---|---|
| derive | пре 1 година | |
| exchanges | пре 8 месеци | |
| global | пре 4 месеци | |
| src | пре 8 месеци | |
| standard | пре 8 месеци | |
| strategy | пре 8 месеци | |
| tests | пре 1 година | |
| .gitignore | пре 1 година | |
| Cargo.toml | пре 8 месеци | |
| README.md | пре 2 година | |
| config.toml.sample | пре 1 година | |
| test_account.toml.sample | пре 1 година |
|
├─ main // 系统入口
│
├─ exchanges // 交易所层(网络层)
│
├─ strategy // 策略层(主逻辑、风控等)
│
├─ standard // 标准化层(中间件)
│
└─ global // 一些全局变量或配置
sudo su
sudo apt update -y
sudo apt-get install build-essential -y
sudo apt-get install libssl-dev -y
sudo apt-get install pkg-config -y
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
然后先后运行这两个命令,检查rust运行环境安装成功:
source $HOME/.cargo/env
rustc --version
增加虚拟内存
sudo fallocate -l 1G /swapfile
ls -lh /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
free -h
cd /
mkdir app
cd app
git config --global credential.helper store
git clone http://git.skyfffire.com/skyfffire/as-rust.git
cd as-rust/
cp config.toml.sample config.toml
nano config.toml
使用nano文本编辑器时,ctl+s保存,ctl+x退出编辑
cargo run
git pull origin master