start new:
tmux
start new with session name:
tmux new -s myname
<?php | |
/** | |
* A ZendFramework-ish filter for PHP_Beautifier | |
* | |
* This file have to go in: | |
* /path/to/pear/php/Beautifier/Filter/ | |
* | |
* Use it in conjunction with Pear() and NewLines() filters: | |
* php_beautifier --input "/path/to/your-file.php" --filter="Pear() zfish() NewLines(after=T_DOC_COMMENT)" | |
* |
import XMonad | |
import qualified XMonad.StackSet as W | |
import qualified Data.Map as M | |
import Data.List (isPrefixOf, (\\), tails) | |
import Data.Maybe (isNothing, fromMaybe, isJust, catMaybes) | |
import System.IO | |
import System.Posix.Unistd | |
import System.Posix.Files |
{-# OPTIONS_GHC -fcontext-stack=32 #-} | |
import XMonad hiding ( (|||) ) | |
import qualified XMonad.StackSet as W | |
import Control.OldException(catchDyn,try) | |
import Data.Char (toLower) | |
import Data.List (intercalate, intersperse, isSuffixOf, isPrefixOf) | |
import qualified Data.Map as M (fromList) |
CREATE OR REPLACE FUNCTION public.viewtables(viewname text) | |
RETURNS SETOF text | |
LANGUAGE plperl | |
AS $function$ | |
my $viewname = shift; | |
my $rv = spi_exec_query("explain (format yaml, verbose) SELECT * FROM $viewname"); | |
my $resp = $rv->{rows}[0]->{'QUERY PLAN'}; | |
my %tbls; | |
while ($resp =~ /Relation Name: (".*")\n\s+Schema: (".*")\n/g) | |
{ |
# Based off of http://www.haskell.org/haskellwiki/Xmonad/Using_xmonad_in_Unity_2D | |
# | |
# /usr/share/xsessions/xmonad.desktop | |
[Desktop Entry] | |
Encoding=UTF-8 | |
Name=XMonad | |
Comment=Lightweight tiling window manager | |
Exec=xmonad | |
Icon=xmonad.png |
#! /bin/sh | |
### BEGIN INIT INFO | |
# Provides: carbon-cache | |
# Required-Start: $remote_fs $syslog | |
# Required-Stop: $remote_fs $syslog | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: carbon-cache init script | |
# Description: An init script for Graphite's carbon-cache daemon. | |
### END INIT INFO |
# Bash completation for application | |
_my_application() | |
{ | |
local cur prev opts job | |
COMPREPLY=() | |
job="${COMP_WORDS[0]}" | |
cur="${COMP_WORDS[COMP_CWORD]}" | |
prev="${COMP_WORDS[COMP_CWORD-1]}" |
The problem is that some lines in the file are missing timestamps when they aren't continuations of any previous line. It's dumb, really.
The mysql query log is seriously bullshit format, but nothing logstash can't unscrew.
The main goal here is to show how we can fix the 'missing timestamp' problem.
% ruby bin/logstash agent -e '
This is a simple way to spot check that the modified image in your git index is the image you actually want without having to leave the command line.
Example: http://i.imgur.com/RUenUcM.png
img-ascii-diff
somewhere (e.g. ~/bin/img-ascii-diff
).attributes
in ~/.config/git/attributes
.~/.gitconfig
and add the lines below, pointing to wherever you put img-ascii-diff
.