Posts

Showing posts with the label Python

My Oh My Zsh Setup

Image
oh my zsh https://ohmyz.sh/ Oh my zsh is an open source project that allows you to customize your z shell. I use it for the following reasons: It makes my terminal look pretty It shows me what git branch I am on It shows me the status of my git repo It shows me the exit code for failed commands It shows my currently activated virtual environment It shows me my currently selected python version (via pyenv) It auto corrects my command line typos Installation Navigate to the installation page at  https://ohmyz.sh/#install , copy the curl command to perform the installation. A script will run that installs oh my zsh and modifies your ~/.zshrc file to load it. Configuration By default oh my zsh will set your theme for you and do some basic configuration. I prefer to use the powerlevel10k theme, which can be found here:  https://github.com/romkatv/powerlevel10k ....

Setup arcade for game development

Create a virtual environment called arcade using python3.8.2 % pyenv virtualenv 3.8.2 arcade Create a project directory for arcade development % mkdir -p ~/Projects/arcade Download the arcade template zip file from GitHub https://github.com/pythonarcade/template Unzip the template and move the contents to the newly created arcade project folder Set the virtual environment for the project % cd ~/Projects/arcade % pyenv local arcade Update pip (arcade) % pip install --upgrade pip Install arcade (arcade) % pip install arcade

Local Python Development

OS X Python Local Development Setup 2020 This assumes you are using ZShell and this is a brand new mac. Install homebrew Install pyenv % brew install pyenv Create a startup file for zshell and add a command to initialize pyenv % echo -e 'if command -v pyenv 1>/dev/null 2>&1; then\n  eval "$(pyenv init -)"\nfi' >> ~/.zshrc Install Xcode command line tools % xcode-select --install Install recommended packages for pyenv % brew install sqlite3 xz zlib Use pyenv to install the latest version of python 3 % pyenv install 3.8.2 Set the latest python version as the default global version % pyenv global 3.8.2 Install python virtual environment management tool % brew install pyenv-virtualenv Add these lines to the end of the ~/.zshrc file to initialize pyenv-virtualenv if which pyenv-virtualenv-init > /dev/null; then   eval "$(pyenv virtualenv-init -)" fi