Skip to content

Instantly share code, notes, and snippets.

View rick4470's full-sized avatar

Rick rick4470

View GitHub Profile
@rick4470
rick4470 / gist:5694382
Created June 2, 2013 18:23
HTML5: Template
<!doctype html>
<html>
<head>
<meta charset=utf-8></meta>
<title></title>
<lin rel="stylesheet" href="style.css">
</head>
<body>
<script src="" type="text/javascript">
code...
@rick4470
rick4470 / gist:5694411
Last active December 18, 2015 00:09 — forked from padolsey/gist:527683
Javascript: Detecting of IE
// ----------------------------------------------------------
// A short snippet for detecting versions of IE in JavaScript
// without resorting to user-agent sniffing
// ----------------------------------------------------------
// If you're not in IE (or IE version is less than 5) then:
// ie === undefined
// If you're in IE (>=5) then you can determine which version:
// ie === 7; // IE7
// Thus, to detect IE:
// if (ie) {}

How to change Pantheon Terminal's color scheme

Many of us spend many hours of our days using their terminal. Plus, we all have different tastes when it comes to color schemes. That's why the ability to change the color scheme of a terminal is one of its more important featuresl. Throughout this tutorial, I'll teach you how you can change the looks of your terminal, step by step.

This tutorial is aimed at elementary OS users, but it also works for any Ubuntu user. Start by installing dconf-tools:

sudo apt-get install dconf-tools

Secondly, you need to decide which theme you're going to apply. You can find dozens of terminal color schemes online, you can even design your own using this web application. Design the color scheme, hit "Get Scheme" and choose "Terminator". You'll get a raw text file with a background color, a foreground color and a palette. Those strings define your color scheme. In this tutorial, I'll post an

@rick4470
rick4470 / ror.sublime-snippet
Created November 28, 2014 04:54
ROR | Easy way to print out to .html.erb files
<snippet>
<content><![CDATA[
<%= $1 %>
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>ror</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<!-- <scope>source.html.erb</scope> -->
</snippet>
git remote add origin http://
git rm -r --cached .
git add .
git commit -m "fixing .gitignore"
#!/bin/sh
#
# chkconfig: 35 99 99
# description: Node.js init.d script /home/nodejs/sample/app.js
# see http://labs.telasocial.com/nodejs-forever-daemon/ and https://gist.github.com/nariyu/1211413
# jujhars13 2013-10-15
#
. /etc/rc.d/init.d/functions
USER="root"
# Software Requirements Specification
## For <project name>
Version 1.0 approved
Prepared by <author>
<organization>
<date created>
# Table of Contents
[Table of Contents](#example)
[Revision History](#revision-history)
@rick4470
rick4470 / gist:eeab7c068fd8fb929b52
Last active August 29, 2015 14:13
How to push an existing git repository from the command line
git remote add origin https://github.com/repo/location
git push -u origin master
@rick4470
rick4470 / Cut command
Created January 29, 2015 20:15
Cut command in Linux
grep -r word directory | cut -d ':' -f 1