Skip to content

Instantly share code, notes, and snippets.

View neverkas's full-sized avatar

Emmanuel Lazarte neverkas

View GitHub Profile
@MatthewSteel
MatthewSteel / ttt.c
Created July 22, 2012 05:35
Minimax (full tree search) tic-tac-toe AI in C
//Tic-tac-toe playing AI. Exhaustive tree-search. WTFPL
//Matthew Steel 2009, www.www.repsilat.com
#include <stdio.h>
char gridChar(int i) {
switch(i) {
case -1:
return 'X';
case 0:
@digitaljhelms
digitaljhelms / gist:4287848
Last active July 19, 2024 03:32
Git/GitHub branching standards & conventions

Branching

Quick Legend

Description, Instructions, Notes
Instance Branch
@seraphyn
seraphyn / updatevirtualboxextions
Created December 20, 2012 17:42
Checks if the Extension Pack version matches the installed VirtualBox version and if not, delete the Extension Pack, downloads and installs the new one.
#! /bin/bash
#
#: Title : updateVboxExt
#: Date Created: Fri May 13 13:54:26 PDT 2011
#: Last Edit : Fri May 13 14:34:37 PDT 201
#: Author : please_try_again
#: Version : 1.0
#: Description : Install or update VirtualBox Extension pack
pkg_sit="http://download.virtualbox.org/virtualbox/"
@fernandoaleman
fernandoaleman / gist:5083680
Last active October 17, 2023 12:02
How to update VirtualBox Guest Additions with vagrant
# Start the old vagrant
$ vagrant init centos-6.3
$ vagrant up
# You should see a message like:
# [default] The guest additions on this VM do not match the install version of
# VirtualBox! This may cause things such as forwarded ports, shared
# folders, and more to not work properly. If any of those things fail on
# this machine, please update the guest additions and repackage the
# box.
@jwebcat
jwebcat / gist:5122366
Last active June 20, 2024 13:35 — forked from lemenkov/gist:1674929
Properly download from github using wget and curl
wget --no-check-certificate --content-disposition https://github.com/joyent/node/tarball/v0.7.1
# --no-check-cerftificate was necessary for me to have wget not puke about https
curl -LJO https://github.com/joyent/node/tarball/v0.7.1
@eschulte
eschulte / curry-compose.el
Last active February 26, 2022 19:52
Implementation of curry, rcurry and compose in Emacs Lisp. Including some code to make Emacs display these functions in a compact and attractive manner.
;;; Commentary
;;
;; Allows for more compact anonymous functions. The following
;; examples demonstrate the usage.
;;
;; ;; partial application with `curry'
;; (mapcar (» #'+ 2) '(1 2 3 4)) ; => (3 4 5 6)
;;
;; ;; alternate order of arguments with `rcurry'
;; (mapcar (« #'- 1) '(1 2 3 4)) ; => (0 1 2 3)
@woods
woods / gen-key-script
Last active June 26, 2024 00:37
Creating gpg keys non-interactively
Key-Type: 1
Key-Length: 2048
Subkey-Type: 1
Subkey-Length: 2048
Name-Real: Root Superuser
Name-Email: root@handbook.westarete.com
Expire-Date: 0
(ns apples.core
(:require [play-clj.core :refer :all]
[play-clj.g2d :refer :all]
[play-clj.math :refer :all]))
(declare apples main-screen)
(def speed 14)
(defn- get-direction []
(cond
@staltz
staltz / introrx.md
Last active July 22, 2024 09:31
The introduction to Reactive Programming you've been missing
@jctosta
jctosta / screen_cheatsheet.markdown
Last active July 21, 2024 23:07
Screen Cheatsheet

Screen Quick Reference

Basic

Description Command
Start a new session with session name screen -S <session_name>
List running sessions / screens screen -ls
Attach to a running session screen -x
Attach to a running session with name screen -r