This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /etc/apt/preferences.d/nosnap-firefox.pref | |
Package: firefox | |
Pin: release o=Ubuntu | |
Pin-Priority: -10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pip install 'python-language-server[flake8,mccabe,pycodestyle,pydocstyle,pyflakes,pylint,rope]' pyls-mypy pyls-black django-stubs djangorestframework-stubs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from subprocess import run | |
from tempfile import TemporaryDirectory | |
if __name__ == '__main__': | |
with TemporaryDirectory() as tempdir: | |
run([ | |
'google-chrome', | |
'--user-data-dir==' + tempdir, | |
'--incognito', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# From https://github.com/yarnpkg/yarn/issues/1776#issuecomment-269539948 | |
# The approach that has worked for me so far is this: | |
git rebase origin/master | |
# When the first conflict arises, I checkout the yarn.lock then re-perform the installation | |
git checkout origin/master -- yarn.lock | |
yarn install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Author: Andrew Howard | |
# This script will copy an server image from one region to another. | |
# BE AWARE: This will incur charges for the customer. These charges | |
# can be minimized by using ServiceNet for the download and by choosing | |
# to auto-delete the Cloud Files content once the transfer is complete. | |
# Even with these precautions, the customer will be charged for storage | |
# fees in Cloud Files (for a single month) and Cloud Images (destination). | |
# Note: To use ServiceNet, this script MUST be run on a Cloud Server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
start on startup | |
setuid itslocal | |
exec /path/to/the/python-lib/or/virtualenv/bin/sentry --config=/path/to/my/sentry.conf.py start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
""" | |
Some custom field types | |
""" | |
import re | |
from django.conf import settings | |
from django.db import models |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Vertical centering with Flexbox + margin fallback | |
* Lea Verou & David Storey | |
*/ | |
html, body { height: 100%; } | |
body { | |
width: 100%; /* needed for FF */ | |
margin: 0; |