mirror of
https://github.com/isledecomp/isle.git
synced 2025-12-10 08:03:13 +00:00
Python Linting and Code Formatting (#298)
* Create common print_diff function * Add pylint and black * Fix linting, move classes to utils * Add black/pylint to github actions * Fix linting * Move Bin and SymInfo into their own files * Split out format * Tidy up workdlows and pip, add readme * Lint tests, add tests to readme
This commit is contained in:
19
.github/workflows/build.yml
vendored
19
.github/workflows/build.yml
vendored
@@ -38,7 +38,7 @@ jobs:
|
||||
build/ISLE.PDB
|
||||
build/LEGO1.DLL
|
||||
build/LEGO1.PDB
|
||||
|
||||
|
||||
compare:
|
||||
needs: build
|
||||
runs-on: windows-latest
|
||||
@@ -70,15 +70,14 @@ jobs:
|
||||
path: legobin
|
||||
key: legobin
|
||||
|
||||
- name: Build isledecomp library
|
||||
- name: Install python packages
|
||||
shell: bash
|
||||
run: |
|
||||
pip install tools/isledecomp
|
||||
pip install -r tools/requirements.txt
|
||||
|
||||
- name: Summarize Accuracy
|
||||
shell: bash
|
||||
run: |
|
||||
pip install -r tools/reccmp/requirements.txt
|
||||
python3 tools/reccmp/reccmp.py -S ISLEPROGRESS.SVG --svg-icon tools/reccmp/isle.png -H ISLEPROGRESS.HTML legobin/ISLE.EXE build/ISLE.EXE build/ISLE.PDB . | tee ISLEPROGRESS.TXT
|
||||
python3 tools/reccmp/reccmp.py -S LEGO1PROGRESS.SVG -T 1929 --svg-icon tools/reccmp/lego1.png -H LEGO1PROGRESS.HTML legobin/LEGO1.DLL build/LEGO1.DLL build/LEGO1.PDB . | tee LEGO1PROGRESS.TXT
|
||||
|
||||
@@ -96,7 +95,7 @@ jobs:
|
||||
shell: bash
|
||||
run: |
|
||||
python3 tools/verexp/verexp.py legobin/LEGO1.DLL build/LEGO1.DLL
|
||||
|
||||
|
||||
- name: Upload Artifact
|
||||
uses: actions/upload-artifact@master
|
||||
with:
|
||||
@@ -104,7 +103,7 @@ jobs:
|
||||
path: |
|
||||
ISLEPROGRESS.*
|
||||
LEGO1PROGRESS.*
|
||||
|
||||
|
||||
upload:
|
||||
needs: [build, compare]
|
||||
runs-on: ubuntu-latest
|
||||
@@ -113,16 +112,16 @@ jobs:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
repository: 'probonopd/uploadtool'
|
||||
|
||||
|
||||
- uses: actions/download-artifact@master
|
||||
with:
|
||||
name: Win32
|
||||
path: build
|
||||
|
||||
|
||||
- uses: actions/download-artifact@master
|
||||
with:
|
||||
name: Accuracy Report
|
||||
|
||||
|
||||
- name: Upload Continuous Release
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
@@ -133,6 +132,6 @@ jobs:
|
||||
build/LEGO1.DLL \
|
||||
ISLEPROGRESS.* \
|
||||
LEGO1PROGRESS.*
|
||||
|
||||
|
||||
curl -X POST -F key=$UPLOAD_KEY -F 'file=@ISLEPROGRESS.SVG' https://legoisland.org/progress/
|
||||
curl -X POST -F key=$UPLOAD_KEY -F 'file=@LEGO1PROGRESS.SVG' https://legoisland.org/progress/
|
||||
|
||||
Reference in New Issue
Block a user