浏览代码

Fix mkvenv - freeze with outdated not supported

84582af
Dirk Alders 1年前
父节点
当前提交
69f4203d60
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2
    2
      mkvenv

+ 2
- 2
mkvenv 查看文件

1
 if [ ! -e venv ];then
1
 if [ ! -e venv ];then
2
-    virtualenv venv
2
+    python3 -m venv venv
3
     if venv/bin/pip -V | grep `pwd -P`; then
3
     if venv/bin/pip -V | grep `pwd -P`; then
4
         venv/bin/pip install --upgrade pip
4
         venv/bin/pip install --upgrade pip
5
         find . -name requirements.txt | xargs -L 1 venv/bin/pip install -r
5
         find . -name requirements.txt | xargs -L 1 venv/bin/pip install -r
6
-        venv/bin/pip list --outdated --format=freeze | grep -v '^\-e' | cut -d = -f 1 | xargs -n1 venv/bin/pip install -U
6
+        venv/bin/pip list --outdated --format=json | jq -r '.[] | .name'|xargs -n1 venv/bin/pip install -U
7
     else
7
     else
8
         echo Not running in the venv!
8
         echo Not running in the venv!
9
     fi
9
     fi

正在加载...
取消
保存