Skip to content

Instantly share code, notes, and snippets.

View Cvetomird91's full-sized avatar

Cvetomir Denchev Cvetomird91

  • Plovdiv, Bulgaria
View GitHub Profile
@alefteris
alefteris / smartgit.desktop
Created April 30, 2012 18:52
Smartgit desktop file for use with Ubuntu Unity launcher
#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
StartupNotify=true
Name=Smartgit
Exec=env SMARTGIT_JAVA_HOME=/opt/apps/jre7/ /opt/apps/smartgit/bin/smartgit.sh
Icon=/opt/apps/smartgit/bin/smartgit-64.png
@tsterker
tsterker / gist:2408855
Created April 17, 2012 20:40
[js] argument unpacking
// Taken from:
// http://readystate4.com/2008/08/17/javascript-argument-unpacking-converting-an-array-into-a-list-of-arguments/
var item1 = ['Jack', '39', 'Panda'];
function hi(name, age, type){
console.log('Hi ' + name + '! You are ' + age + ' and a ' + type + '!');
}
@dafrancis
dafrancis / color.h
Created November 14, 2011 21:29
"Zed's Awesome Debug Macros" from Exercise 20 of "Learn C the Hard Way" (http://c.learncodethehardway.org/). Now with added colours! (Yes I know I use "color" in the code)
#ifndef __color_h__
#define __color_h__
/*
* I got some of the colour codes (as well as having the idea of putting them in a macro) from here:
* http://stackoverflow.com/questions/3506504/c-code-changes-terminal-text-color-how-to-restore-defaults-linux
*/
#define RED "\e[31m"
#define GREEN "\e[32m"