Skip to content

Karantan's blog

  • Home
  • Contact
  • About me
Jayden Steward
October 11, 2019October 11, 2019Comments count 0

Nix package manager

Few good articles: Domen’s article Getting started with Nix package manager. Nix and Python. Nix and Python user guide. Nix – The Purely Functional Package Manager for Linux. Nix for…

Continue reading
Jayden Steward
September 3, 2019October 17, 2019Comments count 0

Allow root access without password

First add a user: $ sudo adduser ubuntu $ sudo usermod -aG sudo ubuntu Edit sudoser file with visudo (edit the sudoers file in a safe fashion). $ sudo visudo…

Continue reading
Jayden Steward
August 22, 2019August 22, 2019Comments count 0

Install Apache & Set Up Virtual Hosts

This is just a quick step by step guide taken from DigitalOcean’s tutorial (see the references at the bottom). The main difference is that it has less explanation – so…

Continue reading
Jayden Steward
April 25, 2018July 16, 2018Comments count 0

Pipenv: basic overview

Pipenv essentially acts as a replacement for pip. It introduces 2 “new” files: Pipfile (“replacement” for requirements.txt) and Pipfile.lock which ensures that builds are deterministic. Pipenv uses pip and virtualenv under the…

Continue reading
Jayden Steward
November 9, 2017Comments count 0

Conda cheat sheet

Create new environment: conda create –name sandbox python=3.5 Create the environment from the environment.yml file: conda env create -f environment.yml Activate specific environment: source activate sandbox Export your active environment to a…

Continue reading
Jayden Steward
November 9, 2017March 3, 2020Comments count 0

tmux cheatsheet

My personal tmux cheat sheet Create a new session: tmux new -s myname Attach: tmux a Attach to a specific named session: tmux a -t myname List of sessions: tmux…

Continue reading
Jayden Steward
December 13, 2016Comments count 0

Python3 strings

A bit of background on unicode and UTF-8: Unicode has a different way of thinking about characters. In Unicode, the letter “A“ is a platonic ideal. It’s just floating in…

Continue reading
Jayden Steward
November 14, 2016Comments count 0

Python PDB

Last month I attended PyMunich conference and in this blog post I want to highlight a talk by Philip Bauer (“Debug like a pro. How to become a better programmer through…

Continue reading
Jayden Steward
September 28, 2016September 28, 2016Comments count 0

Releasing Python Packages

When you need to fix a bug, add feature or change existing functionality in a library that you are using there are several ways to do this. Here I will…

Continue reading
Jayden Steward
September 9, 2016Comments count 0

How to mock ‘open’ built-in function

Here is a code snippet on how to test open built-in function: Code to test: def my_function(self, id: int) -> None: file_path = ‘path/to/files/{}.txt’.format(id) with open(file_path, ‘w’) as f: f.write(‘< My data…

Continue reading

Posts navigation

Older posts
Newer posts


Archives

Tag Cloud

conda Git Go Lessons learned logs Magento Mock Mongodb nix nixops nixos PostgreSQL Python Python3 Rsync systemd tmux Unit testing
Proudly powered by WordPress | Theme: Gently by MusterThemes.