Skip to content

Instantly share code, notes, and snippets.

@koutoftimer
koutoftimer / die.sh
Created March 27, 2024 13:42 — forked from alexanderankin/die.sh
Bash Die Function
function die () {
local message=$1
[ -z "$message" ] && message="Died"
echo "$message (at ${BASH_SOURCE[1]}:${FUNCNAME[1]} line ${BASH_LINENO[0]}.)" >&2
exit 1
}
@koutoftimer
koutoftimer / .tmux.conf
Created January 5, 2023 11:49 — forked from william8th/.tmux.conf
Tmux open new pane in same directory
# Set the control character to Ctrl+Spacebar (instead of Ctrl+B)
set -g prefix C-space
unbind-key C-b
bind-key C-space send-prefix
# Set new panes to open in current directory
bind c new-window -c "#{pane_current_path}"
bind '"' split-window -c "#{pane_current_path}"
bind % split-window -h -c "#{pane_current_path}"
!function() {
/*
RequireJS 2.1.8 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved.
Available via the MIT or new BSD license.
see: http://github.com/jrburke/requirejs for details
*/
/**
* @license RequireJS text 2.0.10 Copyright (c) 2010-2012, The Dojo Foundation All Rights Reserved.
* Available via the MIT or new BSD license.
/**
* Create a new socket instance between client and server,
* and start use it
*
* @method mySocketChatRoom
*
* @param roomId {String} A unique string to represent a single room
* @param username {String} The username to use on this room
*/
function mySocketChatRoom(roomId, username) {