Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README and release_windows.bat for Windows #28

Merged
merged 1 commit into from
Feb 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 21 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,15 +155,31 @@ cd Printrun

### Windows

Download and install [Python 3.6](https://www.python.org/downloads/) and follow the **Python virtual environment** section above except use the following to create and activate the virtual environment and install dependencies:
First download and install [GIT for Windows](https://git-scm.com/downloads), [Python 3.10](https://www.python.org/downloads/) and a [C-compiler environment](https://wiki.python.org/moin/WindowsCompilers/).
For the next steps we need a CMD window or a PowerShell window. You can use Windows Terminal for this as well.
Create and navigate to a directory of your choice where you want to download the source files of this repository and follow the next steps:

CMD
```cmd
> py -3 -m venv venv
> venv\Scripts\activate
> python -m pip install -r requirements.txt
> python pronterface.py
> git clone https://github.com/kliment/Printrun.git
> cd Printrun
> git submodule update --init --recursive
> release_windows.bat
```

PowerShell:
```ps
> git clone https://github.com/kliment/Printrun.git
> cd Printrun
> git submodule update --init --recursive
> ./release_windows.bat
```

The script above will clone this repository and the submodule PrintrunGTK3. The script 'release_windows.bat' will install a virtual environment named v3, download all needed python libraries and compile the binaries for Pronterface.exe and Pronsole.exe.
You will find the files in the new created directory 'dist'. You will find further and more detailed information in the script release_windows.bat. Further information for the linked submodul: [PrintrunGTK3](https://github.com/DivingDuck/PrintrunGTK3)
Run Pronterface or Pronsole from the binary files or from source calling pronterface.py for the GUI version and pronsole.py for the commandline version.

Run 'release_windows.bat' when ever you make changes or updates. With each new run it will compile the binaries and update all involved libraries in the virtual environment if needed. Delete the virtual environment if you have problems with it. Use 'git submodule update --init --recursive' for updating the submodule

### macOS

Expand Down
24 changes: 13 additions & 11 deletions release_windows.bat
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ rem ** 10. Go to directory .\dist, list files and ends the activity
rem ** **
rem ** Steps, you need to do manually before running this batch: **
rem ** **
rem ** 1. Install python 64-bit (3.10.x is actually preferred version for **
rem ** Windows 10 and newer) **
rem ** https://www.python.org/downloads/release/python-379/ **
rem ** In case you use an other Python version, check line 88 and adjust **
rem ** 1. Install python 64-bit (3.10.x is actually preferred and standard version **
rem ** for Windows 10) **
rem ** https://www.python.org/downloads/release **
rem ** In case you use an other Python version, check line 91 and adjust **
rem ** the parameter accordingly to build your virtual environment. **
rem ** 2. Install C-compiler environment **
rem ** https://wiki.python.org/moin/WindowsCompilers **
Expand All @@ -40,9 +40,11 @@ rem ** Windows version, available. You can find a striped version of GTK3
rem ** with all needed DLL binary files in directory PrintrunGTK. Please run **
rem ** following git commands before you run this batch in case you don't find **
rem ** this directory in your local repository: **
rem ** git checkout master **
rem ** git submodule add https://github.com/DivingDuck/PrintrunGTK3 **
rem ** git submodule update --init --recursive **
rem ** git checkout master **
rem ** git submodule add https://github.com/DivingDuck/PrintrunGTK3 **
rem ** git submodule update --init --recursive **
rem ** In case the directory PrintrunGTK3 exist but is empty: **
rem ** git submodule update --init --recursive **
rem ** You can find a listing of all used DLL's in file VERSION as reference and **
rem ** further informations about the linked submodule here: **
rem ** https://github.com/DivingDuck/PrintrunGTK3 **
Expand All @@ -54,7 +56,7 @@ rem **
rem ** https://github.com/wxWidgets/Phoenix/commit/d3bdb14365ca754e83732cccd04e94a2ded5029f
rem ** **
rem ** **
rem ** Author: DivingDuck, 2023-01-31, Status: working **
rem ** Author: DivingDuck, 2023-02-02, Status: working **
rem ** **
rem ************************************************************************************
rem ************************************************************************************
Expand Down Expand Up @@ -123,9 +125,9 @@ echo ****** check for and update outdated modules ******
echo ****************************************************
for /F "skip=2 delims= " %%i in ('pip list --outdated') do py -m pip install --upgrade %%i

echo ****************************************************************************
echo ****** Bug on wxPython 4.1.x workaround for Python 3.x and Windows 10 ******
echo ****************************************************************************
rem echo ****************************************************************************
rem echo ****** Bug on wxPython 4.1.x workaround for Python 3.x and Windows 10 ******
rem echo ****************************************************************************
rem wxPython 4.2.0 is available. Snapshot version is not needed now. Hopefully. #2022-08-05
rem pip install -U --pre -f https://wxpython.org/Phoenix/snapshot-builds/ wxPython

Expand Down