After another hour of resolving issues with pyenv and a personal project that requires Python 3.7 I thought it best to note the steps I used to install Python 3.7.1 on OpenSUSE Tumbleweed:
# Install requirements for compiling Python
sudo zypper in zlib-devel bzip2 libbz2-devel libffi-devel libopenssl-devel readline-devel sqlite3 sqlite3-devel xz xz-devel
# Compile Python
tar xf Python-3.7.1.tar.xz
# AltInstall ensures 3.7.1 is installed alongside your system python
sudo make altinstall
# Fix dynamic library loading
sudo ln -s /usr/local/lib64/python3.7/lib-dynload /usr/local/lib/python3.7/lib-dynload
I’ve updated the Common build problems · pyenv/pyenv Wiki page to reflect the updated required packages. Thanks to Andrew Cooke for the dynamic library fix
Ubuntu 17.10 comes with python3 3.6.3 installed by default but not pip and pipenv. We can install install pip systemwide and pipenv into the user local bin so we can use all the convenience when working with our python projects:
wget https://bootstrap.pypa.io/get-pip.py -O /tmp/get-pip.py
sudo python3 /tmp/get-pip.py
pip3 install --user pipenv
echo "PATH=$HOME/.local/bin:$PATH" >> ~/.profile
Sources: Installing Python 3 on Linux; pip installation; Installing pipenv; How to permanently set PATH on Linux
Update 9 Nov 2017: replaced curl with wget, thanks Peter
Two technologies that I have can really recommend you try out – Lektor and Cloud9 – can be used together to start a static site or blog in a matter of minutes. If you want to try out the power of Lektor without leaving a trace on your machine then follow this quick setup.
Continue Reading »
I wrote this little script and thought it might be useful for others. WorkLog.py allows you to keep track of what you are working on by writing a timestamped message to a CSV file.
It turns out it helps me stay in tack during a long day of work.
Continue Reading »