diff --git a/.github/workflows/build-pip-wheels.yml b/.github/workflows/build-pip-wheels.yml index 315f29aba4..9370c56a19 100644 --- a/.github/workflows/build-pip-wheels.yml +++ b/.github/workflows/build-pip-wheels.yml @@ -12,7 +12,7 @@ on: jobs: get_timestamp: - name: Prep VERSION + name: Prep pyproject.toml runs-on: ubuntu-latest steps: @@ -20,13 +20,13 @@ jobs: uses: actions/checkout@v3 with: submodules: recursive - - name: Create unique VERSION + - name: Create unique version in pyproject.toml if: startsWith(github.ref, 'refs/tags/v') == false - run: python3 -c 'import time;f=open("VERSION","r+");content = f.readlines();f.seek(0);f.write(content[0].strip()+time.strftime("%Y%m%d%H%I%S"))' + run: python3 -c 'import time;f=open("pyproject.toml","r+");c = f.readlines();d=[i.split("#")[0].strip()[:-1]+time.strftime("%Y%m%d%H%I%S")+"\"\n" if i.startswith("version") else i for i in c];f.seek(0);f.writelines(d);f.truncate()' - uses: actions/upload-artifact@v3 with: name: arbver - path: ${{ github.workspace }}/VERSION + path: ${{ github.workspace }}/pyproject.toml build_binary_wheels: name: Build wheels on ${{ matrix.os }} @@ -41,14 +41,14 @@ jobs: uses: actions/checkout@v3 with: submodules: recursive - - name: Delete VERSION - run: rm -f VERSION - - name: Get VERSION + - name: Delete pyproject.toml + run: rm -f pyproject.toml + - name: Get pyproject.toml uses: actions/download-artifact@v3 with: name: arbver - - name: Check VERSION - run: cat VERSION + - name: Check pyproject.toml + run: cat pyproject.toml - name: Install cibuildwheel run: python3 -m pip install cibuildwheel - name: Build wheels @@ -72,14 +72,14 @@ jobs: uses: actions/checkout@v3 with: submodules: recursive - - name: Delete VERSION - run: rm -f VERSION - - name: Get VERSION + - name: Delete pyproject.toml + run: rm -f pyproject.toml + - name: Get pyproject.toml uses: actions/download-artifact@v3 with: name: arbver - - name: Check VERSION - run: cat VERSION + - name: Check pyproject.toml + run: cat pyproject.toml - name: Make sdist run: python3 -m build -s - name: Install sdist