Skip to content

Instantly share code, notes, and snippets.

View AndersDJohnson's full-sized avatar

Anders D. Johnson AndersDJohnson

View GitHub Profile

SVN notes

  • Show conflicted files
$ svn stat | grep -E "^C"
@AndersDJohnson
AndersDJohnson / cygwin_notes.md
Last active June 5, 2019 13:35
cygwin notes

Cygwin

PuTTYcyg

Use PuTTY as a local terminal.

Commands

watch: install procps

@AndersDJohnson
AndersDJohnson / testing.md
Last active June 5, 2019 13:35
browser / client-side testing
@AndersDJohnson
AndersDJohnson / eclipse_notes.md
Last active June 5, 2019 13:35
Eclipse notes

Eclipse notes

Useful hotkeys

Editing

Hotkey Description
Ctrl+Space Context Assist
Ctrl+/ comment/uncomment selected lines
@AndersDJohnson
AndersDJohnson / Logger.js
Last active June 5, 2019 13:35
dom logger / jsfiddle
(function(context){
// don't call until domready
var getDefaultElement = (function () {
var defaultElement;
return function () {
if (typeof defaultElement == 'undefined') {
defaultElement = document.createElement('div');
document.body.appendChild(defaultElement);
}
return defaultElement;
@AndersDJohnson
AndersDJohnson / maven.md
Last active June 5, 2019 13:34
apache maven notes
@AndersDJohnson
AndersDJohnson / install.sh
Last active June 5, 2019 13:34
installer for linux binaries
#!/bin/bash
# Copies local files and directories to root path.
# Run this from the directory of the distr
_SRCDIR="./"
_SRCDIR_SED="\\./"
_INSTALLDIR="/"
_INSTALLDIR_SED="\/"
@AndersDJohnson
AndersDJohnson / ie_classes.php
Last active June 5, 2019 13:34
IE classes for conditional HTML tags
<?php
function get_ie_classes($ie) {
$classes = array('ie');
if ($ie >= 7 && $ie <= 9) {
$classes[] = 'ie-' . $ie;
}
for ($i = 6; $i < $ie; ++$i) {
$classes[] = 'ie-gt-' . $i;
$classes[] = 'ie-gte-' . ($i + 1);
}
@AndersDJohnson
AndersDJohnson / screen.txt
Last active June 5, 2019 13:34
screen cheatsheet
# set default directory
screen -X chdir $DIR
@AndersDJohnson
AndersDJohnson / tmux.txt
Last active June 5, 2019 13:34
tmux cheatsheet
# set default path
tmux set-option default-path "$PWD"