This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# colors for ls, etc. | |
parse_git_branch() { | |
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ \[\1\]/' | |
} | |
if [[ ${EUID} == 0 ]] ; then | |
PS1='\[\033[01;31m\]\u@\h \[\033[01;34m\]\w\[\033[01;35m\]$(parse_git_branch)\[\033[01;34m\] \$ \[\033[00m\]' | |
else | |
PS1='\[\033[01;37m\]\w\[\033[00;35m\]$(parse_git_branch)\[\033[00m\] \$ ' | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function remove_surrounding_p_tag(s) { | |
//converts '<p>xyz</p>' to 'xyz', good for showdown | |
return s.replace(/^<p>|<\/p>$/g,""); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
html,body,div,span, | |
applet,object,iframe, | |
h1,h2,h3,h4,h5,h6,p,blockquote,pre, | |
a,abbr,acronym,address,big,cite,code, | |
del,dfn,em,font,img,ins,kbd,q,s,samp, | |
small,strike,strong,sub,sup,tt,var, | |
dd,dl,dt,li,ol,ul, | |
fieldset,form,label,legend, | |
table,caption,tbody,tfoot,thead,tr,th,td { | |
margin: 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ cd | |
$ git clone http://github.com/senchalabs/connect.git | |
$ cd connect/ | |
$ sudo make install | |
cp -f docs/index.1 /usr/local/share/man/man1/connect.1 | |
cp: cannot create regular file `/usr/local/share/man/man1/connect.1': No such file or directory | |
make: *** [install-docs] Error 1 | |
$ sudo mkdir -p /usr/local/share/man/man1/ | |
$ sudo make install | |
cp -f docs/index.1 /usr/local/share/man/man1/connect.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Licensed to the Apache Software Foundation (ASF) under one or more | |
# contributor license agreements. See the NOTICE file distributed with | |
# this work for additional information regarding copyright ownership. | |
# The ASF licenses this file to You under the Apache License, Version 2.0 | |
# (the "License"); you may not use this file except in compliance with | |
# the License. You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo testing write performance | |
sync; date; time dd if=/dev/zero of=1000m bs=1024k count=5000; date | |
echo testing read performance | |
sync; date; time dd if=1000m of=/dev/null bs=1024k; date | |
rm 1000m |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
# Script to provide answer for question: | |
# http://stackoverflow.com/questions/5149872/how-to-git-remote-add-and-track-a-branch-in-the-same-filesystem | |
echo create origin | |
mkdir origin | |
cd origin/ | |
git init --bare | |
cd .. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Unix Tree / Linux Tree by Dem Pilafian | |
# http://www.centerkey.com/tree/ | |
# mirrored on https://gist.github.com/896397 | |
####################################################### | |
# UNIX TREE # | |
# Version: 2.3 # | |
# File: ~/apps/tree/tree.sh # | |
# # | |
# Displays Structure of Directory Hierarchy # |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
000 | |
001 | |
002 | |
003 | |
004 | |
005 | |
006 | |
007 | |
008 | |
009 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Note: Use the first reg-file if the cygwin dir is c:\ and the other on if cygwin is installed to c:\cygwin\ - otherwise adjust the path in the file. | |
See also https://gist.github.com/1641943 for unattended cygwin update and package install | |
---- | |
README | |
NAME: | |
Cygwin Here |
OlderNewer