mirror of
https://github.com/spencershepard/RotorOps.git
synced 2025-11-10 15:45:30 +00:00
5.0 - pydcs library update - does not use DCS install (#56)
Prevent pydcs library from using DCS installation directory
This commit is contained in:
parent
16d67473b0
commit
f5dfcf0448
@ -1,4 +1,4 @@
|
||||
name: pre-build
|
||||
name: Lua Checks
|
||||
on: [push, pull_request]
|
||||
jobs:
|
||||
lua-linter:
|
||||
@ -12,26 +12,10 @@ jobs:
|
||||
continue-on-error: true
|
||||
with:
|
||||
args: . --no-global --no-unused --no-redefined --no-unused-args --no-max-line-length --ignore 611 612 613 614; echo "lua-lint-result=$?" >> $GITHUB_OUTPUT
|
||||
# luacheck returns exit 1 with warnings, so we continue on error and check the output in the next step
|
||||
- name: Check lua errors
|
||||
run: |
|
||||
echo "luacheck exit code was ${{ steps.luacheck-linter.outputs.lua-lint-result }}"
|
||||
if [ ${{ steps.luacheck-linter.outputs.lua-lint-result }} -eq 1 ]; then echo "Luacheck found warnings but no errors. Allowed to continue."; exit 0; fi; exit 1
|
||||
py-linter:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
python-version: [ "3.10" ]
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v3
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install -r Generator/requirements.txt
|
||||
pip install pylint
|
||||
- name: Analysing the code with pylint
|
||||
run: |
|
||||
pylint --disable=R,C $(git ls-files '*.py')
|
||||
if [ ${{ steps.luacheck-linter.outputs.lua-lint-result }} -eq 1 ]; then echo "Luacheck found warnings but no errors. Allowed to continue."; exit 0; fi;
|
||||
if [ ${{ steps.luacheck-linter.outputs.lua-lint-result }} -eq 2 ]; then echo "Luacheck found errors. Check the luacheck-linter task above for details."; exit 2; fi;
|
||||
exit 3
|
||||
2
.github/workflows/main.yml
vendored
2
.github/workflows/main.yml
vendored
@ -15,7 +15,7 @@ jobs:
|
||||
echo The PR was merged
|
||||
|
||||
deploy:
|
||||
needs: [pre-build]
|
||||
needs: [Lua Checks, Python Checks]
|
||||
runs-on: ubuntu-latest # windows-latest | macos-latest
|
||||
name: Deploy to updater if files changed
|
||||
steps:
|
||||
|
||||
35
.github/workflows/python.yml
vendored
Normal file
35
.github/workflows/python.yml
vendored
Normal file
@ -0,0 +1,35 @@
|
||||
name: Python Checks
|
||||
|
||||
on: [push, pull_request]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
python-version: ["3.8", "3.9", "3.10"]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v3
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
cd Generator
|
||||
python -m pip install --upgrade pip
|
||||
python -m pip install flake8 pytest
|
||||
pip install -r requirements.txt
|
||||
- name: Lint with flake8
|
||||
run: |
|
||||
# stop the build if there are Python syntax errors or undefined names
|
||||
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
|
||||
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
|
||||
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
|
||||
- name: Test with pytest
|
||||
run: |
|
||||
#ignore installed packages
|
||||
pytest --ignore=Generator/src
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
# Form implementation generated from reading ui file 'MissionGeneratorUI.ui'
|
||||
#
|
||||
# Created by: PyQt5 UI code generator 5.15.7
|
||||
# Created by: PyQt5 UI code generator 5.15.9
|
||||
#
|
||||
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
|
||||
# run again. Do not edit this file unless you know what you are doing.
|
||||
|
||||
Binary file not shown.
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,7 @@
|
||||
# ROTOROPS VERSION
|
||||
maj_version = 1
|
||||
minor_version = 4
|
||||
patch_version = 5
|
||||
minor_version = 5
|
||||
patch_version = 0
|
||||
|
||||
version_url = 'https://dcs-helicopters.com/app-updates/versioncheck.yaml'
|
||||
|
||||
|
||||
Binary file not shown.
6
tests/test_version.py
Normal file
6
tests/test_version.py
Normal file
@ -0,0 +1,6 @@
|
||||
import pytest
|
||||
|
||||
|
||||
def test_pass() -> None:
|
||||
assert "this is just a placeholder so pipeline succeeds" != ""
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user