View find_all_unowned_and_locked_files
#!/bin/sh
exec find -E . \
! -regex './(Backups\.backupdb|\.Trashes|\.Spotlight-V100|\.fseventsd|\.disk_label(_2x)?|\.VolumeIcon\.icns|\.DS_Store)(/.*)?' \
\( \
! -user $(id -u) -o \
! -group $(id -g) -o \
-flags uchg -o \
-flags schg \
\) 2>/dev/null
View docker_cleanup
#!/bin/sh
set -e
docker image prune -f # prune dangling images, but NOT ALL images
# run fstrim now, in a privileged container
docker run \
--rm \
--no-healthcheck \
--net=host \
--pid=host \
--privileged \
View docker_trim_enable
#!/bin/sh
set -e
is_docker_running() {
pgrep -q com.docker.hyperkit
}
start_docker() {
open --background -a Docker
}
View 0.stat.1.md
STAT(1) 		  BSD General Commands Manual		       STAT(1)

NAME
     readlink, stat -- display file status

SYNOPSIS
     stat [-FLnq] [-f format | -l | -r | -s | -x] [-t timefmt] [file ...]
     readlink [-n] [file ...]
View .config
# 0. Create a 20 GB case-insensitive sparse bundle from Disk Utility somewhere called "ct-ng-scratch-build-disk"
# 1. Copy this .config to $PWD
# 2. Adjust as needed: CT_BINUTILS_VERSION, CT_LIBC_VERSION, CT_CC_GCC_VERSION, CT_GMP_VERSION, CT_MPFR_VERSION, CT_MPC_VERSION, and CT_*_V_*
# 3. brew install gcc
# 4. env CC=gcc-7 CXX=g++-7 ct-ng build # let it fail
# 5. patch -Np2 <(curl -L 'https://bugs.debian.org/cgi-bin/bugreport.cgi?att=1;bug=831142;filename=gperf-gcc-6.patch;msg=10') # into the build src dir
# 6. env CC=gcc-7 CXX=g++-7 ct-ng build
# 7. Success!
CT_CONFIGURE_has_svn=y
CT_MODULES=y
View install_grub.sh
#!/bin/sh
set -ex
GRUB_PREFIX="${GRUB_PREFIX-${PWD}/grub-bin}"
UNIFONT_VERSION='10.0.05'
brew install mtools xorriso curl git
if [ -d grub ]; then
(
View gist:ec7f54f88f6a6740f88cb344032bac56
2017-06-22 20:56:47.120036-0700 LuaService[91048:2244668] Error creating dataPath: (null)
container: ~/Library/Developer/Xcode/DerivedData/ChatSecure-fopyaptbwrotlfahtsmhbkcuusnm/Build/Products/Debug/ChatSecure.app/Contents/XPCServices/LuaService.xpc/Contents/Resources/prosody
data_dir: ~/Library/Containers/org.bmf.chatsecure.LuaService/Data/Documents/LuaService.Prosody
Generating RSA private key, 2048 bit long modulus
......................................................+++
...............+++
e is 65537 (0x10001)
Choose key size (2048): Key written to ~/Library/Containers/org.bmf.chatsecure.LuaService/Data/Documents/LuaService.Prosody/dttzkywtwj7aqmka.onion.key
Please provide details to include in the certificate config file.
Leave the field empty to use the default value or '.' to exclude the field.
View LICENSE
Copyright (C) 2011 by Colin MacKenzie IV
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
View crap_ton_of_packages
apm-beta install \
aligner \
aligner-css \
aligner-javascript \
aligner-ruby \
aligner-scss \
atom-autocomplete-erlang \
atom-beautify \
atom-clock \
atom-elixir \
View check_atom_packages.sh
#!/bin/sh
# brew install parallel || sudo apt-get install -y parallel || sudo yum install -y parallel
set -e
for D in ~/.atom/packages/*; do
[ ! -d "$D" ] && continue # skip non-directories
D="$(basename "$D")"
case "$D" in
# skip Github-only packages
autocomplete-go| \
builder-go| \