Skip to content

Instantly share code, notes, and snippets.

@vmaks
vmaks / gist:a5116361136ac3e4843f
Last active August 29, 2015 14:14
PEP 8 - Style Guide for Python Code
# link : https://www.python.org/dev/peps/pep-0008/#code-lay-out
# Indentation. Use 4 spaces
# Aligned with opening delimiter.
foo = long_function_name(var_one, var_two,
var_three, var_four)
# No extra indentation.
if (this_is_one_thing and
@vmaks
vmaks / install_gcc_g++_4.8_ubuntu_12.04.txt
Last active June 21, 2024 12:28
How to install gcc-4.8 and g++-4.8 on Ubuntu 12.04
# link: http://askubuntu.com/questions/271388/how-to-install-gcc-4-8?newreg=6c2b1c109685438c8bc7b37a87cefb21
# link to the repository: https://launchpad.net/~ubuntu-toolchain-r/+archive/ubuntu/test?field.series_filter=precise
# Open a terminal(Ctrl+Alt+t) and run the following commands:
sudo apt-get install python-software-properties
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
# install gcc
sudo apt-get install gcc-4.8
@vmaks
vmaks / PyCharm_icon_Unity_Ubuntu.txt
Last active August 29, 2015 14:14
PyCharm icon in the Unity dash board in an Ubuntu
#######################################################################
Add PyCharm Community icon in Ubuntu
#######################################################################
1) Firstly unlock an old icon for the previous PyCharm version from the Unity dash board.
2) Extract archive with a new PyCharm version (for example "pycharm-community-3.4.1.tar.gz") in the home ("user/home") folder;
3) Go to a bin folder ("/home/maks/pycharm-community-3.4.1/bin");
4) Open Terminal in the bin folder and enter the command below:
sudo ./pycharm.sh
@vmaks
vmaks / 0_reuse_code.js
Last active August 29, 2015 14:13
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console