diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index dde4f957..279c40c2 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -77,6 +77,31 @@ jobs: name: Rare.AppImage path: Rare.AppImage + nuitka: + runs-on: "windows-latest" + steps: + - uses: actions/checkout@v2 + with: + submodules: true + - uses: actions/setup-python@v2 + with: + python-version: '3.9' + - name: Dependencies + run: | + pip3 install -r requirements.txt + pip3 install -r requirements-presence.txt + - name: Build Dependencies + run: pip3 install nuitka ordered-set PyQt5-stubs + - name: Build + run: | + python -m nuitka --assume-yes-for-downloads --follow-imports --prefer-source-code --mingw64 --lto=no --static-libpython=no --standalone --enable-plugin=anti-bloat --enable-plugin=pyqt5 --show-anti-bloat-changes --nofollow-import-to="*.tests" --nofollow-import-to="*.distutils" --include-package-data=qtawesome --include-data-dir=rare\resources\images=rare\resources\images --include-data-files=rare\resources\languages=rare\resources\languages="*.ts" --windows-icon-from-ico=rare\resources\images\Rare.ico --windows-company-name=Rare --windows-product-name=Rare --windows-file-version=1.9.0 --windows-product-version=1.9.0 --windows-disable-console rare + python -c "import shutil; shutil.make_archive('Rare-Windows-Nuitka', 'zip', 'rare.dist')" + + - uses: actions/upload-artifact@v2 + with: + name: Rare-Windows-Nuitka.zip + path: Rare-Windows-Nuitka.zip + cx_freeze: runs-on: "windows-latest" steps: diff --git a/pyproject.toml b/pyproject.toml index 45cd2e75..5f28b09e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -33,24 +33,36 @@ pywebview = [ legendary-gl = "^0.20.28" typing-extensions = "^4.3.0" - [tool.poetry.scripts] start = "rare.__main__:main" - - [tool.poetry.dev-dependencies] Nuitka = "^1.0.6" pylint = "^2.15.0" black = "^22.6.0" #[build-system] -#requires = ["setuptools>=42"z, "wheel", "nuitka", "toml"] +#requires = ["setuptools>=42", "wheel", "nuitka", "toml"] #build-backend = "nuitka.distutils.Build" - [nuitka] -show-scons = true -enable-plugin = ["pyqt5", "anti-bloat"] +assume-yes-for-downloads = true +follow-imports = true +prefer-source-code = true +mingw64 = true +lto = true +static-libpython = false +standalone = true +show-scons = false +enable-plugin = ["anti-bloat", "pyqt5"] show-anti-bloat-changes = true nofollow-import-to = ["*.tests", "*.distutils"] +include-package-data = "qtawesome" +include-data-dir = "rare/resources/images=rare/resources/images" +include-data-files = "rare/resources/languages=rare/resources/laguanges=*.qm" +windows-icon-from-ico = "rare/resources/images/Rare.ico" +windows-company-name = "Rare" +windows-product-name = "Rare" +windows-file-version = "1.9.0" +windows-product-version = "1.9.0" +windows-disable-console = true diff --git a/requirements-dev.txt b/requirements-dev.txt new file mode 100644 index 00000000..1555712b --- /dev/null +++ b/requirements-dev.txt @@ -0,0 +1,7 @@ +build +wheel +black +toml +nuitka +ordered-set +PyQt5-stubs diff --git a/setup.py b/setup.py index 21f9bfa3..69c489a8 100644 --- a/setup.py +++ b/setup.py @@ -47,5 +47,5 @@ setuptools.setup( python_requires=">=3.8", entry_points=dict(console_scripts=["rare=rare.__main__:main"]), install_requires=requirements, - extras_require=optional_reqs + extras_require=optional_reqs, )