Skip to content

Commit 90145c8

Browse files
committed
1/5/2026
1 parent f2218a2 commit 90145c8

File tree

8 files changed

+115
-65
lines changed

8 files changed

+115
-65
lines changed

.20_docker.bash

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,14 @@ __docker_lazy_install() {
1010
$0 "$@"
1111
}
1212
fi
13+
14+
if ! command -v skopeo &> /dev/null && command -v brew &> /dev/null; then
15+
skopeo() {
16+
brew install skopeo
17+
unset -f "$0"
18+
$0 "$@"
19+
}
20+
fi
1321
}
1422
__docker_lazy_install
1523

.20_kubernetes.bash

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,23 @@ __kube_lazy_install() {
66
$0 "$@"
77
}
88
fi
9+
910
if ! command -v kubectl &> /dev/null && command -v brew &> /dev/null; then
11+
# Note: Docker Desktop provides kubectl, this shouldn't be necessary
1012
kubectl() {
1113
brew install kubectl
1214
unset -f "$0"
1315
$0 "$@"
1416
}
1517
fi
18+
19+
if ! command -v stern &> /dev/null && command -v brew &> /dev/null; then
20+
stern() {
21+
brew install stern
22+
unset -f "$0"
23+
$0 "$@"
24+
}
25+
fi
1626
}
1727
__kube_lazy_install
1828

.20_nodejs.bash

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
__nodejs_setup() {
2+
export PATH="$(npm get prefix --global)/bin:$PATH"
3+
}
4+
5+
16
__nodejs_volta() {
27
if [[ -d "$HOME/.volta" ]]; then
38
export VOLTA_HOME="$HOME/.volta"

.20_temporal.bash

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,45 +8,46 @@ if [[ -d "${HOME}/.temporalio/bin" ]]; then
88
fi
99

1010

11-
__temporal_completions() {
12-
# NOTE: `autoload -Uz compinit && compinit` will need to happen before sourcing any of these!
13-
14-
if command -v tctl &> /dev/null; then
11+
__temporal_lazy_install() {
12+
if ! command -v tctl &> /dev/null && command -v brew &> /dev/null; then
1513
tctl() {
14+
brew install tctl
1615
unset -f "$0"
17-
# shellcheck disable=SC1090
18-
source <(tctl completion "$(basename "${SHELL}")")
1916
$0 "$@"
2017
}
18+
fi
2119

20+
if ! command -v temporal &> /dev/null && command -v brew &> /dev/null; then
2221
temporal() {
22+
brew install temporal
2323
unset -f "$0"
24-
# shellcheck disable=SC1090
25-
source <(temporal completion "$(basename "${SHELL}")")
2624
$0 "$@"
2725
}
2826
fi
2927
}
30-
__temporal_completions
28+
__temporal_lazy_install
3129

3230

33-
__temporal_lazy_install() {
34-
if ! command -v tctl &> /dev/null && command -v brew &> /dev/null; then
31+
__temporal_completions() {
32+
# NOTE: `autoload -Uz compinit && compinit` will need to happen before sourcing any of these!
33+
34+
if command -v tctl &> /dev/null; then
3535
tctl() {
36-
brew install tctl
3736
unset -f "$0"
37+
# shellcheck disable=SC1090
38+
source <(tctl completion "$(basename "${SHELL}")")
3839
$0 "$@"
3940
}
40-
fi
41-
if ! command -v temporal &> /dev/null && command -v brew &> /dev/null; then
41+
4242
temporal() {
43-
brew install temporal
4443
unset -f "$0"
44+
# shellcheck disable=SC1090
45+
source <(temporal completion "$(basename "${SHELL}")")
4546
$0 "$@"
4647
}
4748
fi
4849
}
49-
__temporal_lazy_install
50+
__temporal_completions
5051

5152

5253
__tctl_funcs() {

.githooks/post-merge

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,11 @@ set -euo pipefail
1111
# squash merge. This hook cannot affect the outcome of git merge and is not executed, if the merge
1212
# failed due to conflicts.
1313

14-
echo -e "\033[47m↓↓↓↓↓ emmercm/dotfiles post-merge ↓↓↓↓↓\033[0m"
15-
16-
17-
echo -e "\033[47m>>>>> Running install.sh >>>>>\033[0m"
14+
echo -e "\033[7m>>>>>>>>>> Running install.sh >>>>>>>>>>\033[0m"
1815
./install.sh
1916

20-
echo -e "\033[47m>>>>> Running packages.sh >>>>>\033[0m"
17+
echo -e "\033[7m>>>>>>>>>> Running packages.sh >>>>>>>>>>\033[0m"
2118
./packages.sh
2219

23-
echo -e "\033[47m>>>>> Running settings.sh >>>>>\033[0m"
20+
echo -e "\033[7m>>>>>>>>>> Running settings.sh >>>>>>>>>>\033[0m"
2421
./settings.sh
25-
26-
27-
echo -e "\033[47m↑↑↑↑↑ emmercm/dotfiles post-merge ↑↑↑↑↑\033[0m"

install.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,10 +48,10 @@ function link() {
4848
done <<< "$(find "$1" -maxdepth 1 -name "$2" ! -name ".git" ! -name ".github" ! -name ".gitignore")"
4949

5050
# Delete broken symlinks
51-
while read -r file; do
51+
find "${HOME}" -maxdepth 1 -type l ! -exec test -e {} \; -print | while read -r file; do
5252
echo -e "\033[91mDeleting:\033[0m ${file}"
5353
rm -f "${file}"
54-
done <<< "$(find "${HOME}" -maxdepth 1 -type l ! -exec test -e {} \; -print)"
54+
done
5555
}
5656

5757

packages.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
3434
command -v wget > /dev/null || brew install wget
3535

3636
# Install Homebrew casks (only install if shell is interactive, in case of admin password prompt)
37+
brew tap emmercm/igir
38+
brew tap nahive/spotify-notify
3739
if ! sudo -n true &> /dev/null; then
3840
echo -e "\033[1;33mWARN:\033[0m you may be asked for your password to run 'brew install --cask'\n"
3941
fi
@@ -42,6 +44,7 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
4244
echo "charmstone"
4345
#echo "discord"
4446
echo "docker-desktop"
47+
echo "feedflow"
4548
echo "firefox"
4649
echo "github"
4750
echo "hiddenbar"
@@ -57,9 +60,11 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
5760
#echo "signal"
5861
#echo "slack"
5962
echo "spotify"
63+
echo "spotify-notify"
6064
#echo "steam"
6165
#echo "telegram"
6266
echo "visual-studio-code"
67+
#echo "whatsapp"
6368
echo "wine-stable"
6469
); do
6570
printf "Checking for cask '${cask}' ... "

settings.sh

Lines changed: 65 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,14 @@ fi
1111

1212
# macOS settings
1313
if [[ "${OSTYPE:-}" == "darwin"* ]]; then
14+
if ! command -v plistwatch &> /dev/null && command -v go &> /dev/null; then
15+
plistwatch() {
16+
go install github.com/catilac/plistwatch@latest
17+
unset -f "$0"
18+
$0 "$@"
19+
}
20+
fi
21+
1422
if ! sudo -n true &> /dev/null; then
1523
echo -e "\033[1;33mWARN:\033[0m you may be asked for your password to run 'pmset', 'chflags', and other utilities\n"
1624
fi
@@ -21,38 +29,41 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
2129

2230
# ***** Settings > Network *****
2331

24-
# ***** Settings > Notifications *****
25-
26-
# ***** Settings > Sound *****
27-
# Alert sound: Boop
28-
defaults write .GlobalPreferences com.apple.sound.beep.sound -string "/System/Library/Sounds/Tink.aiff"
29-
# Alert volume
30-
defaults write .GlobalPreferences com.apple.sound.beep.volume -float 0.5
31-
# Play feedback when volume is changed
32-
defaults write .GlobalPreferences com.apple.sound.beep.feedback -bool true
33-
34-
# ***** Settings > Focus *****
35-
# TODO: remove DND schedules / disable DND
32+
# ***** Settings > Battery *****
33+
# Low Power Mode: Only on Battery
34+
sudo pmset -b lowpowermode 1
35+
sudo pmset -c lowpowermode 0
36+
# Options... prevent automatic sleeping on power adapter when the display is off: on
37+
sudo pmset -c sleep 0
38+
# Options... wake for network access: only on power adapter
39+
sudo pmset -b womp 0
40+
sudo pmset -c womp 1
3641

37-
# ***** Settings > Screen Time *****
42+
# ***** Settings > Apple Intelligence & Siri *****
43+
# Siri: off
44+
defaults write com.apple.assistant.support "Assistant Enabled" -int 0
3845

3946
# ***** Settings > General > Software Update *****
4047
# sudo softwareupdate --schedule ON
4148
# sudo defaults write /Library/Preferences/com.apple.SoftwareUpdate.plist AutomaticCheckEnabled -bool YES
4249

50+
# ***** Settings > General > Date & Time *****
51+
# 24-hour time: on
52+
defaults write .GlobalPreferences AppleICUForce24HourTime -int 1
53+
54+
# ***** Settings > Accessibility *****
55+
4356
# ***** Settings > Appearance *****
4457
# NOTE: appearance change requires restart
4558
# Appearance
4659
defaults write .GlobalPreferences AppleInterfaceStyle -string "Dark"
4760
defaults write .GlobalPreferences AppleInterfaceStyleSwitchesAutomatically -bool false
48-
# Accent color: orange
61+
# Color: orange
4962
defaults write .GlobalPreferences AppleAccentColor 1
5063
# Show scroll bars: always
5164
defaults write .GlobalPreferences AppleShowScrollBars -string "Always"
5265

53-
# ***** Settings > Accessibility *****
54-
55-
# ***** Settings > Control Center *****
66+
# ***** Settings > Menu Bar *****
5667
# Bluetooth: always show in menu bar
5768
defaults -currentHost write com.apple.controlcenter Bluetooth -int 18
5869
# Sound: always show in menu bar
@@ -61,17 +72,10 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
6172
defaults -currentHost write com.apple.controlcenter BatteryShowPercentage -bool true
6273
# Clock options... show AM/PM: false
6374
defaults write com.apple.menuextra.clock Show24Hour -int 1
64-
defaults write .GlobalPreferences AppleICUForce24HourTime -int 1
6575
# Siri: don't show in menu bar
6676
defaults write com.apple.Siri StatusMenuVisible -int 0
6777
killall SystemUIServer
6878

69-
# ***** Settings > Siri & Spotlight *****
70-
# Ask Siri: false
71-
defaults write com.apple.assistant.support "Assistant Enabled" -int 0
72-
73-
# ***** Settings > Privacy & Security *****
74-
7579
# ***** Settings > Desktop & Dock *****
7680
# Size: smaller
7781
defaults write com.apple.dock tilesize -int 45
@@ -94,23 +98,40 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
9498
# TODO: True Tone off
9599
# TODO: Night Shift... schedule: sunset to sunrise
96100

101+
# ***** Settings > Spotlight *****
102+
# Disable Spotlight indexing on external volumes
103+
while read -r volume; do
104+
if mdutil -s "${volume}" | grep -xq "enabled"; then
105+
sudo mdutil -i off -d "${volume}"
106+
sudo killall DesktopServicesHelper
107+
sudo killall mds
108+
sudo killall mdsync
109+
fi
110+
if [[ ! -f "${volume}/.metadata_never_index" ]]; then
111+
touch "${volume}/.metadata_never_index" || true
112+
fi
113+
done <<< "$(find /Volumes -type d -mindepth 1 -maxdepth 1)"
114+
97115
# ***** Settings > Wallpaper *****
98116

99-
# ***** Settings > Screen Saver *****
100-
# defaults -currentHost write com.apple.screensaver idleTime -int 1800
101-
# defaults write com.apple.screensaver askForPasswordDelay -int 0
117+
# ***** Settings > Notifications *****
102118

103-
# ***** Settings > Battery *****
104-
# Low Power Mode: Only on Battery
105-
sudo pmset -b lowpowermode 1
106-
sudo pmset -c lowpowermode 0
107-
# Options... prevent automatic sleeping on power adapter when the display is off: on
108-
sudo pmset -c sleep 0
109-
# Options... wake for network access: only on power adapter
110-
sudo pmset -b womp 0
111-
sudo pmset -c womp 1
119+
# ***** Settings > Sound *****
120+
# Alert sound: Boop
121+
defaults write .GlobalPreferences com.apple.sound.beep.sound -string "/System/Library/Sounds/Tink.aiff"
122+
# Alert volume
123+
defaults write .GlobalPreferences com.apple.sound.beep.volume -float 0.5
124+
# Play feedback when volume is changed
125+
defaults write .GlobalPreferences com.apple.sound.beep.feedback -bool true
126+
127+
# ***** Settings > Focus *****
128+
# TODO: remove DND schedules / disable DND
129+
130+
# ***** Settings > Screen Time *****
112131

113132
# ***** Settings > Lock Screen *****
133+
# defaults -currentHost write com.apple.screensaver idleTime -int 1800
134+
# defaults write com.apple.screensaver askForPasswordDelay -int 0
114135
# Start screen saver when inactive for X seconds
115136
defaults -currentHost write com.apple.screensaver -int 300
116137
# Turn display off on battery when inctive for X minutes
@@ -120,16 +141,18 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
120141
# TODO: Require password after screen saver begins or display is turned off: 1min
121142
killall "System Settings" || true
122143

144+
# ***** Settings > Privacy & Security *****
145+
123146
# ***** Settings > Touch ID & Password *****
124147

125148
# ***** Settings > Users & Groups *****
126149

127-
# ***** Settings > Passwords *****
128-
129150
# ***** Settings > Internet Accounts *****
130151

131152
# ***** Settings > Game Center *****
132153

154+
# ***** Settings > Game Center *****
155+
133156
# ***** Settings > Wallet & Apple Pay *****
134157

135158
# ***** Settings > Keyboard *****
@@ -154,6 +177,10 @@ if [[ "${OSTYPE:-}" == "darwin"* ]]; then
154177
# More gestures... app exposé: swipe down with three fingers
155178
defaults write com.apple.dock showAppExposeGestureEnabled -bool true
156179

180+
# ***** Settings > Game Controllers *****
181+
182+
# ***** Settings > Printers & Scanners *****
183+
157184
# ***** Activity Monitor *****
158185
# Columns & sorting preferences
159186
defaults write com.apple.ActivityMonitor UserColumnSortPerTab "{0={direction=1;sort=Command;};1={direction=0;sort=anonymousMemory;};2={direction=0;sort=12HRPower;};3={direction=0;sort=CPUUsage;};4={direction=0;sort=txBytes;};5={direction=0;sort=Name;};6={direction=0;sort=GPUUsage;};}"

0 commit comments

Comments
 (0)