Some fix
This commit is contained in:
74
.github/workflows/main.yml
vendored
74
.github/workflows/main.yml
vendored
@@ -10,21 +10,13 @@ on:
|
||||
|
||||
jobs:
|
||||
Linux:
|
||||
outputs:
|
||||
version: ${{ steps.version.outputs.VERSION }}
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
version: ${{ outputs.version }}
|
||||
|
||||
|
||||
steps:
|
||||
- id: version
|
||||
run: echo "::set-output name=VERSION::$(cat AV_Data_Capture.py | grep "version = " | tr -d "version = '")"
|
||||
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Python 3.8
|
||||
uses: actions/setup-python@v1
|
||||
- name: Setup Python 3.8
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.8
|
||||
|
||||
@@ -33,21 +25,17 @@ jobs:
|
||||
python -m pip install --upgrade pip
|
||||
pip install -r requirements.txt
|
||||
|
||||
- name: Test number_perser.get_number
|
||||
- name: Set build version
|
||||
run: |
|
||||
python number_parser.py -v
|
||||
version=$(python -c 'import AV_Data_Capture; print(AV_Data_Capture.__version__)')
|
||||
echo "::set-env name=VERSION::$version"
|
||||
|
||||
- name: Set CLOUDSCRAPER_PATH variable
|
||||
run: |
|
||||
echo "::set-env name=CLOUDSCRAPER_PATH::$(python -c 'import cloudscraper as _; print(_.__path__[0])' | tail -n 1)"
|
||||
|
||||
- name: Build with pyinstaller
|
||||
- name: Build with PyInstaller
|
||||
run: |
|
||||
pyinstaller \
|
||||
--onefile AV_Data_Capture.py \
|
||||
--hidden-import ADC_function.py \
|
||||
--hidden-import core.py \
|
||||
--add-data "$CLOUDSCRAPER_PATH:cloudscraper"
|
||||
--hidden-import core.py
|
||||
|
||||
- name: Copy config.ini
|
||||
run: |
|
||||
@@ -56,19 +44,17 @@ jobs:
|
||||
- name: Upload build artifact
|
||||
uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: AV_Data_Capture-CLI-${{ env.version }}-Linux
|
||||
name: AV_Data_Capture-CLI-${{ env.VERSION }}-Linux
|
||||
path: dist
|
||||
|
||||
|
||||
Windows:
|
||||
runs-on: windows-latest
|
||||
needs: Linux
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Python 3.8
|
||||
uses: actions/setup-python@v1
|
||||
- name: Setup Python 3.8
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.8
|
||||
|
||||
@@ -77,21 +63,17 @@ jobs:
|
||||
python -m pip install --upgrade pip
|
||||
pip install -r requirements.txt
|
||||
|
||||
- name: Test number_perser.get_number
|
||||
- name: Set build version
|
||||
run: |
|
||||
python number_parser.py -v
|
||||
$env:version=$(python -c 'import AV_Data_Capture; print(AV_Data_Capture.__version__)')
|
||||
echo "::set-env name=VERSION::$env:version"
|
||||
|
||||
- name: Set CLOUDSCRAPER_PATH variable
|
||||
run: |
|
||||
echo "::set-env name=CLOUDSCRAPER_PATH::$(python -c 'import cloudscraper as _; print(_.__path__[0])' | tail -n 1)"
|
||||
|
||||
- name: Build with pyinstaller
|
||||
- name: Build with PyInstaller
|
||||
run: |
|
||||
pyinstaller `
|
||||
--onefile AV_Data_Capture.py `
|
||||
--hidden-import ADC_function.py `
|
||||
--hidden-import core.py `
|
||||
--add-data "$env:CLOUDSCRAPER_PATH;cloudscraper"
|
||||
--hidden-import core.py
|
||||
|
||||
- name: Copy config.ini
|
||||
run: |
|
||||
@@ -100,19 +82,17 @@ jobs:
|
||||
- name: Upload build artifact
|
||||
uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: AV_Data_Capture-CLI-${{ needs.Linux.env.version }}-Windows
|
||||
name: AV_Data_Capture-CLI-${{ env.VERSION }}-Windows
|
||||
path: dist
|
||||
|
||||
|
||||
MacOS:
|
||||
needs: Linux
|
||||
runs-on: macos-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Set up Python 3.8
|
||||
uses: actions/setup-python@v1
|
||||
- name: Setup Python 3.8
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: 3.8
|
||||
|
||||
@@ -121,21 +101,17 @@ jobs:
|
||||
python -m pip install --upgrade pip
|
||||
pip install -r requirements.txt
|
||||
|
||||
- name: Test number_perser.get_number
|
||||
- name: Set build version
|
||||
run: |
|
||||
python number_parser.py -v
|
||||
version=$(python -c 'import AV_Data_Capture; print(AV_Data_Capture.__version__)')
|
||||
echo "::set-env name=VERSION::$version"
|
||||
|
||||
- name: Set CLOUDSCRAPER_PATH variable
|
||||
run: |
|
||||
echo "::set-env name=CLOUDSCRAPER_PATH::$(python -c 'import cloudscraper as _; print(_.__path__[0])' | tail -n 1)"
|
||||
|
||||
- name: Build with pyinstaller
|
||||
- name: Build with PyInstaller
|
||||
run: |
|
||||
pyinstaller \
|
||||
--onefile AV_Data_Capture.py \
|
||||
--hidden-import ADC_function.py \
|
||||
--hidden-import core.py \
|
||||
--add-data "$CLOUDSCRAPER_PATH:cloudscraper"
|
||||
--hidden-import core.py
|
||||
|
||||
- name: Copy config.ini
|
||||
run: |
|
||||
@@ -144,5 +120,5 @@ jobs:
|
||||
- name: Upload build artifact
|
||||
uses: actions/upload-artifact@v1
|
||||
with:
|
||||
name: AV_Data_Capture-CLI-${{ needs.Linux.env.version }}-MacOS
|
||||
name: AV_Data_Capture-CLI-${{ env.VERSION }}-MacOS
|
||||
path: dist
|
||||
|
||||
Reference in New Issue
Block a user