Oneliner to generate a Django Secret Key
python -c “import string,random; uni=string.ascii_letters+string.digits+string.punctuation; print repr(”.join([random.SystemRandom().choice(uni) for i in range(random.randint(45,50))]))”
python -c “import string,random; uni=string.ascii_letters+string.digits+string.punctuation; print repr(”.join([random.SystemRandom().choice(uni) for i in range(random.randint(45,50))]))”
This will make sure you bypass those pesky questions, with the safest option. For when you want to do an upgrade in a script (such as from a Vagrant :shell provision) DEBIAN_FRONTEND=noninteractive apt-get -y -o Dpkg::Options::=”–force-confdef” -o Dpkg::Options::=”–force-confold” dist-upgrade
I love byobu (the awesome screen/tmux wrapper). One of my pet peeves with byobu, is it takes over the Function keys (F-keys). There is very little to no documentation on how to disable that by default. Here is how … For Tmux: echo ‘source $BYOBU_PREFIX/share/byobu/keybindings/f-keys.tmux.disable’ >> ~/.byobu/keybindings.tmux For Screen: # Enable Screen if you haven’t,…