This file contains 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 ksh | |
typeset -T Record=( | |
integer uid | |
integer date=0 | |
typeset description | |
) | |
typeset -T Log=( | |
Record -h '(internal) Array of log records.' -a records |
This file contains 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
NAME | |
cksum,md5sum,sum - print file checksum and block count | |
SYNOPSIS | |
cksum,md5sum,sum [ options ] [ file ... ] | |
DESCRIPTION | |
sum lists the checksum, and for most methods the block count, for each file | |
argument. The standard input is read if there are no file arguments. getconf | |
UNIVERSE determines the default sum method: att for the att universe, bsd |
This file contains 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
(ins)root@ormaaj-laptop (162321) ~ # /mnt/ormaaj-laptop/ksh93 -c 'typeset -p .sh; print -v .sh; builtin -l' | |
namespace sh | |
{ | |
typeset -l -i lineno=0 | |
math='' | |
op_astbin=/opt/ast/bin | |
typeset -i pwdfd=10 | |
typeset -C sig=() | |
typeset -C stats=() | |
typeset -s -i subshell=0 |
This file contains 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
bash -o monitor -O lastpipe /dev/fd/3 3<<\EOF | |
typeset -A j jobs | |
n=0 | |
while ((n++ < 3)); do | |
{ set -m; trap "exit \$n" exit; suspend; } & | |
jobs+=([$!]=) | |
done | |
{ for x in "${!jobs[@]}"; do sleep .2; kill -CONT "$x"; done; } & | |
until wait -fnp jid "${!jobs[@]}" | |
(( (${jobs[$jid]+j[\$jid] = }$?) == 0)); do |
This file contains 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 bash | |
# Debugging function for colored display of argv. | |
function args { | |
{ BASH_XTRACEFD=3 command eval "$(</dev/fd/0)"; } <<-'EOF' 3>/dev/null | |
case $- in *x*) | |
typeset +x BASH_XTRACEFD | |
set +x | |
trap 'trap RETURN; set -x' RETURN | |
esac |
This file contains 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 | |
# Dan Douglas <ormaaj@gmail.com> | |
#set -x | |
unalias -a | |
shopt -s extglob lastpipe expand_aliases | |
function libinit { | |
alias libinit='\unalias -a | |
\shopt -s extglob lastpipe expand_aliases; \libinit' |
This file contains 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/ksh | |
typeset -T PollEvent=( | |
_Bool poll{in,out,pri,err,hup,nval,{rd,wr}{norm,band}}=false | |
) | |
typeset -T PollFD=( | |
integer fd | |
PollEvent events revents | |
) |
This file contains 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 | |
shopt -s expand_aliases extglob | |
alias \[='x=${BASH_COMMAND#"${BASH_ALIASES[\[]} "} command eval eval \"[[ \$x]\" \#' | |
set -x | |
[ ormaaj == or+([ma])j ] | |
echo "$?" |
This file contains 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
1 | |
1 | |
2 | |
6 | |
24 | |
120 | |
720 | |
5040 |
This file contains 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
Verifying my Blockstack ID is secured with the address 1JGNdApmYocuG1HTmDdhvhSQ78UizP4R3Z https://explorer.blockstack.org/address/1JGNdApmYocuG1HTmDdhvhSQ78UizP4R3Z |