As configured in my dotfiles.
start new:
tmux
start new with session name:
package main | |
import ( | |
"fmt" | |
"io" | |
"log" | |
"net/http" | |
"os" | |
) |
# rectangle.pyx | |
cdef extern from "Rectangle.h" namespace "shapes": | |
cdef cppclass Rectangle: | |
Rectangle(int, int, int, int) | |
int x0, y0, x1, y1 | |
int getLength() | |
int getHeight() | |
int getArea() | |
void move(int, int) |
/* | |
* Example of a singleton design pattern. | |
* Copyright (C) 2011 Radek Pazdera | |
* This program is free software: you can redistribute it and/or modify | |
* it under the terms of the GNU General Public License as published by | |
* the Free Software Foundation, either version 3 of the License, or | |
* (at your option) any later version. | |
* This program is distributed in the hope that it will be useful, |
# 0 is too far from ` ;) | |
set -g base-index 1 | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
#set -g default-terminal screen-256color | |
set -g status-keys vi | |
set -g history-limit 10000 |
# On CodeEval, test cases are read in from a file which is the first argument to your program | |
# Open the file and read in line by line. Each line represents a different test case | |
# (unless given different instructions in the challenge description) | |
import sys | |
test_cases = open(sys.argv[1], 'r') | |
for test in test_cases: | |
# ignore test if it is an empty line |
;; This are setting for nice tabbar items | |
;; to have an idea of what it looks like http://imgur.com/b0SNN | |
;; inspired by Amit Patel screenshot http://www.emacswiki.org/pics/static/NyanModeWithCustomBackground.png | |
;; Tabbar | |
(require 'tabbar) | |
;; Tabbar settings | |
(set-face-attribute | |
'tabbar-default nil | |
:background "gray20" |
import socket, traceback | |
HOST = '' | |
PORT = 51235 | |
CLRF = '\r\n' | |
class InvalidRequest(Exception): | |
pass | |
class Request(object): |
/* Read this comment first: https://gist.github.com/tonious/1377667#gistcomment-2277101 | |
* 2017-12-05 | |
* | |
* -- T. | |
*/ | |
#define _XOPEN_SOURCE 500 /* Enable certain library functions (strdup) on linux. See feature_test_macros(7) */ | |
#include <stdlib.h> | |
#include <stdio.h> |
## Example: Grab the value for the MYSQL_USER key | |
User=$( sed -n 's/.*"MYSQL_USER": "\(.*\)",/\1/p' /var/lib/credentials.json ) | |
## Example: Grab the value for the MYSQL_PASSWORD key | |
Passwd=$( sed -n 's/.*"MYSQL_PASSWORD": "\(.*\)",/\1/p' /var/lib/credentials.json ) |
As configured in my dotfiles.
start new:
tmux
start new with session name: