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
#cs | |
Copyright (C) March 30, 2015, Andrew Domaszek | |
(MIT License) | |
#ce | |
;#include <MsgBoxConstants.au3> | |
TraySetIcon ("Shell32.dll", 28) | |
TraySetToolTip ("Miggle" & @CRLF & "De-idle.") | |
Func _GetTicksFromGLII() |
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
#include <stdio.h> | |
#include <iso646.h> | |
int main() { | |
if (1 == 1 and 1 not_eq 2) { | |
printf("It's nice that it got here, but it still compiled.\n"); | |
} else { | |
printf("Everything is awful, forever\n"); | |
} | |
return 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
#include <stdio.h> | |
#include <stdarg.h> | |
#include <unistd.h> | |
#include <time.h> | |
#define printfTS(msg, ...) fprintfTS(stdout, msg, ## __VA_ARGS__) | |
// This is *not* threadsafe (localtime & strftime) | |
int fprintfTS(FILE * stream, const char * const msg, ...) | |
{ |
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
#!/usr/bin/env python | |
import sys | |
def printstatus(): | |
ij=0 | |
for i in range(printstatus.interject_len, 0, -1): | |
if printstatus.counter > 0 and (printstatus.counter % (len(printstatus.statline) * 3 ** i)) == 0: | |
print "\n%s" % printstatus.interject[i-1] | |
printstatus.lastmod=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
find . -exec zsh -c "getfattr -n 'user.taint' \"\$@\" 2>/dev/null | gawk 'BEGIN{fname=\"\";} /^#/{fname=gensub(/^[^:]*: /,\"\",1,\$0)} /^[^#]/{print fname \" :: \" \$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/sh | |
# Bandwidth flow controller. Should decrease overall latency. | |
: <<'EOF' | |
Copyright (C) February 30, 2006, Andrew Domaszek | |
(MIT License) | |
Update history: | |
May 30, 2014 - add internal flow limit |
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
if [ ! -z "$PS1" ] && [ -z "$STY" ] && which screen 2>&1 > /dev/null | |
then | |
old=$IFS | |
IFS=$'\n' | |
screens=($(screen -ls | egrep -iv '\(.*dead.*\)' | grep -e '(.*)' | awk '{print $1}')) | |
IFS=$old | |
if [ ${#screens[@]} -ge 1 ]; then | |
# pre-existing session, reattach to the first, leaving no bash parent behind. | |
exec screen -x "${screens[0]}" | |
else |
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
DECLARE | |
FUNCTION date_if_possible(v1 IN VARCHAR2) | |
RETURN DATE AS | |
dte_corrected DATE; | |
BEGIN | |
dte_corrected = to_date( | |
to_char(to_number(regexp_substr(v1,'[^,]+', 15, 1)) - 100) || | |
lpad(to_char(to_number(regexp_substr(v1,'[^,]+', 15, 2)) - 100),2,'0') || | |
lpad(regexp_substr(v1,'[^,]+', 15, 3),2,'0') || | |
lpad(regexp_substr(v1,'[^,]+', 15, 4),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
######## DO SETUP ######## | |
e=accD | |
pre=UD | |
jildir=$DATDIR/../jil | |
for file in "`ls -1 \"$jildir\"`" | |
do | |
ostr=`grep delete_box $file | gawk -v s=$pre '{if (NR>1) {exit(0)};gsub(/\\\$S/,s,$2);print $2}'` | |
echo $ostr | |
stat=`jr $ostr | egrep '^'$ostr | sed -e 's@.* \([A-Z][A-Z]\) .*@\1@'` | |
echo $ostr $stat |
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 | |
function contains() { | |
local n=$# | |
local value=${!n} | |
for ((i=1;i < $#;i++)) { | |
if [ "${!i}" == "${value}" ]; then | |
return 0 | |
fi | |
} |