Skip to content

Instantly share code, notes, and snippets.

View gunzapper's full-sized avatar
🏠
Working from home

Pietro Brunetti gunzapper

🏠
Working from home
View GitHub Profile
vim --version
NVIM 0.1.7
Build type: None
Compilation: /usr/bin/x86_64-linux-gnu-gcc -g -O2 -fPIE -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -DDISABLE_LOG -Wconversion -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wvla -fstack-protector-strong -fdiagnostics-color=auto -DINCLUDE_GENERATED_DECLARATIONS -DHAVE_CONFIG_H -D_GNU_SOURCE -I/build/neovim-auam90/neovim-0.1.7/build/config -I/build/neovim-auam90/neovim-0.1.7/src -I/usr/include -I/usr/include -I/usr/include -I/usr/include -I/usr/include -I/usr/include -I/usr/include -I/build/neovim-auam90/neovim-0.1.7/build/src/nvim/auto -I/build/neovim-auam90/neovim-0.1.7/build/include
Compiled by [email protected]
Optional features included (+) or not (-): +acl +iconv +jemalloc +tui
For differences from Vim, see :help vim-differences
system vimrc file: "$VIM/sysinit.vim"
[Quickfix List]   0%  1:1
Error detected while processing function <SNR>115_OnCursorMovedNormalMode[5]..<SNR>115_OnFileReadyToParse[1]..<SNR>115_Pyeval[2]..provider#python3#Call:
line 18:
Invalid channel "1"
@gunzapper
gunzapper / gist:852e32ecea3a44527ff7
Created February 19, 2016 11:21 — forked from why-not/gist:4582705
Pandas recipe. I find pandas indexing counter intuitive, perhaps my intuitions were shaped by many years in the imperative world. I am collecting some recipes to do things quickly in pandas & to jog my memory.
"""quick way to create a data frame to try things out"""
df = pd.DataFrame(np.random.randn(5, 4), columns=['a', 'b', 'c', 'd'])
df['A'] """ will bring out a col """ df.ix[0] """will bring out a row, #0 in this case"""
"""to get an array from a data frame or a series use values, note it is not a function here, so no parans ()"""
point = df_allpoints[df_allpoints['names'] == given_point] # extract one point row.
point = point['desc'].values[0] # get its descriptor in array form.

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@gunzapper
gunzapper / tmux.md
Last active August 29, 2015 14:15 — forked from andreyvit/tmux.md

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

@gunzapper
gunzapper / force.json
Created February 25, 2014 17:55
nodes lenght
{
"directed": false,
"graph": [],
"nodes": [
{
"group": 1,
"artist": "Antony and the Johnsons",
"title": "I Am A Bird Now",
"label": "Secretly Canadian/wide",
"rate": 8,
@gunzapper
gunzapper / force.json
Created February 21, 2014 10:05
Now the color is based on the album rate
{
"directed": false,
"graph": [],
"nodes": [
{
"group": 1,
"artist": "Daniel Rossen",
"title": "Silent Hour / Golden Mile",
"label": "Warp",
"rate": 7,
@gunzapper
gunzapper / force.json
Created February 20, 2014 13:08
Network of album mined form OndaRock.it
{
"directed": false,
"graph": [],
"nodes": [
{
"title": "I Am A Bird Now",
"artist": "Antony and the Johnsons",
"group": 1,
"id": "/recensioni/2005_antony.htm",
"year": "2005"
@gunzapper
gunzapper / force.json
Last active August 29, 2015 13:56
Ondarock network, first example
{
"directed": true,
"graph": [],
"nodes": [
{
"group": 1,
"id": "Jens Lekman\nI Know What Love Isn't "
},
{
"group": 1,