Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions config/atuin/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,26 @@ sync_address = "https://api.atuin.sh"

# Search behavior
search_mode = "fuzzy"
search_mode_shell_up_key_binding = "prefix"
filter_mode = "global"
filter_mode_shell_up_key_binding = "host"
filter_mode_shell_up_key_binding = "workspace"
workspaces = true

# UI
style = "auto"
show_preview = true
enter_accept = true
command_chaining = true

# Ctrl+R: fullscreen search. Up arrow: ~10 visible results.
style = "auto"
inline_height = 0
inline_height_shell_up_key_binding = 16

# Security: filter secrets from history
secrets_filter = true

[search]
filters = ["directory", "workspace", "session", "session-preload", "host", "global"]

[sync]
records = true
6 changes: 2 additions & 4 deletions platforms/macos/bundles/core/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,11 @@ if command -v atuin &>/dev/null && [[ ! -f "$HOME/.local/share/atuin/key" ]]; th
echo ""
echo "Importing existing shell history..."
atuin import auto
atuin sync
echo " Sync starts on your next shell session."
;;
l|L|login)
atuin login
echo ""
echo "Syncing history from server..."
atuin sync
echo " Sync starts on your next shell session."
;;
*)
echo " Skipped. Run 'atuin register' or 'atuin login' later."
Expand Down
25 changes: 0 additions & 25 deletions platforms/macos/bundles/work/config/atuin/config.toml

This file was deleted.

10 changes: 4 additions & 6 deletions platforms/macos/bundles/work/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,10 @@ install_brewfile "$BUNDLE_DIR/Brewfile"
# Kill apps that auto-launch after installation
killall "zoom.us" 2>/dev/null || true

## Bundle-specific config overrides
if [[ -d "$BUNDLE_DIR/config" ]]; then
echo ""
echo "Applying work config overrides..."
apply_config_overrides "$BUNDLE_DIR"
fi
## Bundle-specific config tweaks
echo ""
echo "Applying work-specific config overrides..."
"$BUNDLE_DIR/tweak.sh"

echo ""
echo "Work setup complete!"
41 changes: 41 additions & 0 deletions platforms/macos/bundles/work/tweak.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
#!/usr/bin/env bash

# Work-specific config overrides.
# Patches base configs in-place for values that need to differ at work.
#
# Idempotent: each section skips if its changes are already applied.
#
# TODO: Replace with bidirectional config sync (see TODO.md) so bundle-specific
# overrides don't need per-tool tweak scripts.

set -e

DOTFILES_DIR="${DOTFILES_DIR:-$(cd "$(dirname "$0")/../../../.." && pwd)}"
source "$DOTFILES_DIR/scripts/lib/common.sh"

ATUIN_CONFIG="$HOME/.config/atuin/config.toml"
BASE_CONFIG="$DOTFILES_DIR/config/atuin/config.toml"

if [[ ! -f "$BASE_CONFIG" ]]; then
echo " No base atuin config found, skipping work tweaks"
return 0 2>/dev/null || exit 0
fi

if [[ -L "$ATUIN_CONFIG" ]]; then
cp -L "$ATUIN_CONFIG" "$ATUIN_CONFIG.tmp"
rm "$ATUIN_CONFIG"
mv "$ATUIN_CONFIG.tmp" "$ATUIN_CONFIG"
echo " Copied base atuin config for work customization"
fi

# Tweak: filter_mode = "host" (instead of "global")
if grep -q '^filter_mode = "global"' "$ATUIN_CONFIG" 2>/dev/null; then
sed -i '' 's/^filter_mode = "global"/filter_mode = "host"/' "$ATUIN_CONFIG"
echo " Set filter_mode to host"
fi

# Tweak: drop "global" from the search filters array
if grep -q '"global"' "$ATUIN_CONFIG" 2>/dev/null; then
sed -i '' 's/, "global"//g; s/"global", //g; s/"global"//g' "$ATUIN_CONFIG"
echo " Removed global from search filters"
fi
Loading