After importing a module in python use the following to find out where it was imported from: import astroid astroid.__file__ '/usr/local/lib/python2.7/dist-packages/astroid/__init__.pyc' This is...
In Xubuntu 14.10 xfce-terminal (the default Terminal application) and vim it's difficult to choose a cursor colour that doesn't obscure the text: The fix is to put the following into...
If you ever find yourself with multiple PDF files that need to be combined into one single PDF you can use the following incantation on Linux: gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite...
We often need to convert objects into their string representation for nice output. To do this in python we can use the str() built-in function. However, it may not always be the best function to...
Compiling a new kernel on a Raspberry Pi itself takes a longtime. This is how to cross-compile a kernel package. An Intel i7laptop does the job in 11 minutes.I am assuming that you are using an...