Skip to content

Instantly share code, notes, and snippets.

View tboztuna's full-sized avatar
🎯
Focusing

Tolga Boztuna tboztuna

🎯
Focusing
View GitHub Profile
@Steven-Rose
Steven-Rose / gist:3943830
Created October 24, 2012 04:27
VI: Select all + delete, select all + copy
Select all and delete (actually move to buffer)
:%d
Select all and copy to buffer
:%y
Use p to paste the buffer.
@kenpower
kenpower / gist:4018118
Created November 5, 2012 16:27
3D OpenGL Cube in SFML
////////////////////////////////////////////////////////////
// Headers
////////////////////////////////////////////////////////////
#include "stdafx.h"
#ifdef _DEBUG
#pragma comment(lib,"sfml-graphics-d.lib")
#pragma comment(lib,"sfml-audio-d.lib")
#pragma comment(lib,"sfml-system-d.lib")
#pragma comment(lib,"sfml-window-d.lib")
@ogrrd
ogrrd / dnsmasq OS X.md
Last active July 3, 2024 08:40
Setup dnsmasq on OS X

Never touch your local /etc/hosts file in OS X again

To setup your computer to work with *.test domains, e.g. project.test, awesome.test and so on, without having to add to your hosts file each time.

Requirements

Install

@staltz
staltz / introrx.md
Last active July 15, 2024 15:43
The introduction to Reactive Programming you've been missing
@saltun
saltun / gist:b4c117641461177523ef
Created July 5, 2014 12:39
Laravel validation.php Türkçe [ TR]
<?php
return array(
/*
|--------------------------------------------------------------------------
| Validation Language Lines
|--------------------------------------------------------------------------
|
| The following language lines contain the default error messages used by
| the validator class. Some of these rules have multiple versions such
@etandel
etandel / centralize.zsh
Last active January 8, 2020 02:56
Random background for i3lock
#!/bin/zsh
newname=$(echo $1 | awk -F'.' '{print $1}').png # i3lock only accepts pngs
resolution=$(xrandr | fgrep '*' | awk '{print $1}')
# if the image is too large, run the folloowing line first and then run the script again on temp.jpg:
# convert $1 -gravity Center -adaptive-resize $resolution -background black temp.jpg
convert $1 -background black -gravity center -extent $resolution -background black $newname
@roachhd
roachhd / README.md
Last active July 16, 2024 19:04
Basics of BrainFuck

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

BrainFuck Programming Tutorial by: Katie

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

INTRODUCTION

var defaults = {
number: 1,
bool: true,
magic: 'real',
animal: 'whale',
croutons: 'delicious'
};
var options = {
number: 2,
@mrosata
mrosata / flower-power.py
Last active October 7, 2023 11:08
Python Turtle Flower... Stack like recursion
#!/usr/bin/python
# Udacity exercise. Just posted the code here to help anyone who wanted to see the work behind my posted result.
__author__ = 'Michael Rosata mrosata1984@gmail.com'
__package__ = ''
from random import random
import turtle
class TurtleArtist(turtle.Turtle):
_origin = (0, 0)
#
# Sample /etc/sudoers file.
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the sudoers man page for the details on how to write a sudoers file.
##
# Override built-in defaults
##