From 02a98b6bfcca8f11dc2a047a8c3aa940daa8bd3b Mon Sep 17 00:00:00 2001 From: Argiris Deligiannidis Date: Fri, 2 Feb 2024 13:05:06 +0000 Subject: [PATCH] Update README.md --- README.md | 51 +++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 45 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 1b5a18d..d1ad90f 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # wine python windows builder -Python for windows container. +Archlinux based image with wine-staging and pyinstaller ## usage @@ -11,15 +11,54 @@ kind: pipeline type: docker name: default +workspace: + path: /drone/src + steps: - name: build - image: docker.asperti.com/paspo/python-windows-builder + image: git.argideli.com/quertex/docker-win-pyinstaller:latest pull: always commands: - # add dependancy - - wine c:/python/python.exe -m pip install cryptography # prepare output directory - mkdir -p /drone/src/out/ - # build - - wine c:/python/Scripts/pyinstaller.exe --onefile --distpath z:/drone/src/out z:/drone/src/prepara_xml.py + - mkdir -p /drone/src/dist/ + # add dependancies + - pacman -Sy --noconfirm --needed wget ... + # linux build + - cd /drone/src/ + - python -m venv --system-site-packages venv + - source venv/bin/activate + - pip3 list + - pip3 config --user set global.progress_bar off + - pip3 install --ignore-installed -r requirements.txt + - pyinstaller --onefile --name matomo-csv-util.bin --hidden-import=tkinter -y --distpath /drone/src/out/ /drone/src/main.py + - deactivate + - cp -v out/matomo-csv-util.bin dist/ + # clean up + - rm -rf venv + - rm -rf /drone/src/out + - mkdir -p /drone/src/out/ + # windows build + - wine c:/python/python.exe -m pip config --user set global.progress_bar off + - wine c:/python/python.exe -m pip install --prefer-binary -r z:/drone/src/requirements.txt + - wine c:/python/Scripts/pyinstaller.exe --onefile --name matomo-csv-util --hidden-import=tkinter -y --distpath z:/drone/src/out z:/drone/src/main.py + - cp -v out/matomo-csv-util.exe dist/ + + - name: gitea_release + image: plugins/gitea-release + settings: + base_url: https://git.argideli.com + api_key: + from_secret: gitea_token + files: /drone/src/dist/* + checksum: + - md5 + - sha256 + - crc32 + when: + allConditions: + - event: tag + +image_pull_secrets: + - docker_token ```