PyZ is meant to be a custom shell for python. Contains a customizable shell, a .rc file and perhaps more coming soon! The shell's main inspiration is zsh, an alternative shell to bash. Except instead of being an entire different programming language, it's an alternative shell!
This being a Python app, it's able to work on basically anything that can run a python intrepreter. So
- Windows
- MacOS
- Linux
- Free/OpenBSD
and probably many more.
- Head over to the release tab and select the desired release
-
Then choose the version of PyZ you want:
- Windows users will want to download the .exe
- Debian Linux users will want to download the .deb
- Any Linux users will want to download the binary with no extension
-
Download it and install it.
-
Debian:
sudo apt install ./pyz_v1.0.0_amd64.deb
-
Linux binary:
Open a terminal in the executable's directory and run
cp pyz-1.0.0-x64 $HOME/.local/bin/pyz
-
Windows .exe:
Open a terminal in the .exe's directory and run
New-Item -Path "$Env:AppData\Roaming" -Name "PyZ" -ItemType "directory" && Copy-Item -Path ".\pyz-v1.0.0-x64.exe" -Destination "$Env:AppData\Roaming\PyZ\PyZ.exe" && $Env:PATH += ";$Env:USERPROFILE\AppData\Roaming\PyZ"
-
- Clone the repository
git clone https://github.com/CodyMarkix/PyZ-Shell
- Then enter the cloned git repository and run the make script.
.\make.ps1 build
./make build
- The generated binary will either be in
bin/Linux
orbin\Windows
.
- Cd into the repository and run
./make help
or
.\make.ps1 help
-
This will show the possible actions in the make script. On Linux, it's currently possible to:
- Install a normal Linux binary to
~/.local/bin/
-./make install
- Make a deb package (manual apt installation required) -
./make package deb
- Make an AppImage -
./make package appimage
- Install a normal Linux binary to
-
On Windows, it's currently possible to:
- Install a normal Windows binary to
%USERPROFILE%\AppData\Roaming\PyZ\
-.\make.ps1 install
- Install a normal Windows binary to
- Tested with Python 3.8.x (Theoretically should support up to 3.10.x)
- Termcolor
- Pyinstaller (for creating a binary!)
- AppImageTool (for creating an AppImage!)
- There's 3 ways to run the shell.
- Open up a terminal and run
pyz
. - If you downloaded the AppImage and used something like AppImageLauncher to register it into your DE's menu, open that menu and click on "PyZ".
- Open the Start Menu and select PyZ.
This is where a lot of the magic happens, customization-wise. In the default .rc file, there's a prompt decleration and some notes. You'll want to keep some sort of prompt.
By default, PyZ uses the Termcolor module, which is hard-imported, along with some others in the standard modules. But you can add whatever prompts you want.
As you may notice, the .pyzrc file is basically a script that is went through and is executed line-by-line when an instance of the shell is opened. Meaning you can have various prompts. Some examples include:
Bourpy (default):
global prompt; prompt = "[ "+ termcolor.colored(os.getcwd(), "green") + " ]"+ termcolor.colored(" >", "blue")
Which produces:
Classic:
global prompt; prompt = "PyZ >>>"
Which produces:
- Nested multi-line code is not supported
- Complete make.ps1
- Fix building from source
- Fix multi-line code bug