It's really all I ever want to do with awk
$ echo "my name is Al" | awk '{print $4 " " $3 " " $2}'
Al is name
$ sudo dpkg -i
## Depends on gnu-find | |
# brew install findutils | |
## ~/.zshrc | |
# autoload bashcompinit | |
# bashcompinit | |
# source ~/.config/zsh/bashcompinit/npx.bash | |
_npx() { |
/Users/al/local/bin/dock |
#!/usr/bin/env bash | |
if [ -f .gitignore ] && [ "$1" = "-a" ]; then | |
echo "File .gitignore already exists. Exiting." | |
exit 1 | |
fi | |
if [ ! -d .git ]; then | |
echo "No .git directory found. Exiting." | |
exit 1 | |
fi |
#!/usr/bin/env zsh | |
# Author: Alexander Ilseman | |
# Github: @fathergoose | |
# Date: 2022-10-18 | |
# Description: This script will update neovim to the latest nightly release | |
# System: macOS | |
# Check if neovim is running | |
if ps aux | awk '{print $11}' | grep -E '^nvim$' > /dev/null ; then |
function pm() { | |
local pfile=$HOME/.projects | |
if [[ ! -f $pfile ]]; then | |
touch $pfile | |
fi | |
local usage="Usage: pm [-a|-d|-l|-h] [key] [path]" | |
# List projects | |
if [[ $1 == "-l" ]]; then |
#!/usr/bin/env zsh | |
VERSION="0.0.1" | |
DATE_STORAGE_FMT='%Y-%m-%dT%H:%M:%S' | |
if [[ $1 == "-h" || $1 == "--help" ]]; then | |
echo "Usage: $0 [options] [entry]" | |
echo "Options:" | |
echo " -h, --help Show this help message and exit" | |
echo " -v, --version Show program's version number and exit" | |
exit 0 |
git diff --name-only -z main | tr '\n' '\0' | xargs -0 rg 'console.log' |
# Save screenshots somewere else | |
defaults write com.apple.screencapture location <path_to_new_loc> | |
killall SystemUIServer | |
# Show hidden files in finder | |
defaults write com.apple.finder AppleShowAllFiles YES | |
# Keep the dock from sticking open -- not sure it worked | |
defaults write com.apple.dock autohide-delay -int 0 | |
defaults write com.apple.dock autohide-time-modifier -float 1.0 |
#!/bin/sh | |
# | |
# Check for debugger statements before commiting your code. | |
# | |
# Nodejs uses 'debugger' as a keyword statement to trigger a | |
# breakpoint. There's literally no reason to commit such a thing | |
echo "Running debugger check..." | |
RES=`git grep -n 'debugger'` |