Skip to content

Commit

Permalink
[Mod] 更新Ubuntu和Mac的安装脚本
Browse files Browse the repository at this point in the history
  • Loading branch information
vnpy committed Feb 16, 2023
1 parent d9939ab commit c5482fb
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 12 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
10. 修改vnpy_ctastrategy使用vnpy.trader.database中统一定义的时区来加载数据
11. 增加vnpy_ctastrategy策略模板的合约乘数查询函数get_size
12. 增加vnpy_spreadtrading回测中统计绩效时对于爆仓情况的检查

13. 增加vnpy_scripttrader基于vt_symbol和direction查询持仓数据的函数
14. 修改vt_positionid的字符串内容,增加gateway_name前缀标识

## 修复

Expand Down
7 changes: 3 additions & 4 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@ pypi_index=$2
shift 2


[[ -z $python ]] && python=python
[[ -z $pypi_index ]] && pypi_index=https://pypi.org/simple
[[ -z $python ]] && python=python3
[[ -z $pypi_index ]] && pypi_index=https://pypi.douban.com/simple

$python -m pip install --upgrade pip wheel --index $pypi_index

# Get and build ta-lib
function install-ta-lib()
{
# install numpy first
$python -m pip install numpy==1.21.5 --index $pypi_index
$python -m pip install numpy==1.23.1 --index $pypi_index

pushd /tmp
wget https://pip.vnpy.com/colletion/ta-lib-0.4.0-src.tar.gz
Expand All @@ -41,4 +41,3 @@ locale-gen zh_CN.GB18030

# Install VeighNa
$python -m pip install . --index $pypi_index

16 changes: 9 additions & 7 deletions install_osx.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
#!/usr/bin/env bash

python=$1
shift 1
pypi_index=$2
shift 2

[[ -z $python ]] && python=python
[[ -z $python ]] && python=python3
[[ -z $pypi_index ]] && pypi_index=https://pypi.douban.com/simple

$python -m pip install --upgrade pip wheel
$python -m pip install --upgrade pip wheel --index $pypi_index

# Get and build ta-lib
function install-ta-lib()
Expand All @@ -20,11 +22,11 @@ function ta-lib-exists()
ta-lib-exists || install-ta-lib

# install ta-lib
$python -m pip install numpy==1.21.5
$python -m pip install ta-lib==0.4.24
$python -m pip install numpy==1.23.1 --index $pypi_index
$python -m pip install ta-lib==0.4.24 --index $pypi_index

# Install Python Modules
$python -m pip install -r requirements.txt
$python -m pip install -r requirements.txt --index $pypi_index

# Install VeighNa
$python -m pip install . $@
$python -m pip install . --index $pypi_index

0 comments on commit c5482fb

Please sign in to comment.