From 801d62a8131c3d4291d25737c144eb5e45f3f712 Mon Sep 17 00:00:00 2001 From: Mike Vink Date: Fri, 18 Jul 2025 19:04:30 +0200 Subject: macos --- .config/aerospace/aerospace.toml | 1 + .config/bash/bashrc | 2 +- .config/kitty/themes/penelope.conf | 4 +- .config/shell/aliasrc | 1 - .config/shell/profile | 30 +++++++++------ .local/bin/dmenu-ansi-escape-termcolors | 66 +++++++++++++++++++++++++++++++++ .local/bin/macos.d/kak | 2 - 7 files changed, 88 insertions(+), 18 deletions(-) create mode 100755 .local/bin/dmenu-ansi-escape-termcolors delete mode 100755 .local/bin/macos.d/kak diff --git a/.config/aerospace/aerospace.toml b/.config/aerospace/aerospace.toml index beefb1d..e70a238 100644 --- a/.config/aerospace/aerospace.toml +++ b/.config/aerospace/aerospace.toml @@ -106,6 +106,7 @@ automatically-unhide-macos-hidden-apps = true cmd-enter = ['''exec-and-forget kitty --single-instance --detach --working-directory "$HOME"'''] cmd-n = ['''exec-and-forget kitty --single-instance --detach --working-directory "$HOME" sh --login -c 'exec kn''''] cmd-e = ['''exec-and-forget kitty --single-instance --detach --working-directory "$HOME" sh --login -c 'exec neomutt''''] + cmd-r = ['''exec-and-forget kitty --single-instance --detach --working-directory "$HOME" sh --login -c 'exec htop''''] cmd-w = '''exec-and-forget osascript -e ' tell application "System Events" diff --git a/.config/bash/bashrc b/.config/bash/bashrc index 52fb13c..c7df633 100644 --- a/.config/bash/bashrc +++ b/.config/bash/bashrc @@ -10,7 +10,7 @@ fi [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/bash/local.bashrc" ] && . "${XDG_CONFIG_HOME:-$HOME/.config}/bash/local.bashrc" [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/bash/complete_alias" ] && . "${XDG_CONFIG_HOME:-$HOME/.config}/bash/complete_alias" -export PS1='\[\e]0;\w $(test "$IN_KAKOUNE_CONNECT" && printf '%s' "- $KAKOUNE_CLIENT@[$KAKOUNE_SESSION]")$(test "$TERM" && printf '%s' "- $TERM")\a\]\n\[\e[32m\]\u@\h \e[34m$(test "$IN_KAKOUNE_CONNECT" && printf '%s' "¶$KAKOUNE_SESSION") \[\e[33m\]\w\[\e[0m\]\n\[\e[1;36;1m\]λ\[\e[0m\] ' +export PS1='\[\e]0;\w $(test "$IN_KAKOUNE_CONNECT" && printf '%s' "- $KAKOUNE_CLIENT@[$KAKOUNE_SESSION]")$(test "$TERM" && printf '%s' "- $TERM")\a\]\n\[\e[32m\]\u@\h \e[34m$(test "$IN_KAKOUNE_CONNECT" && printf '%s' "¶$KAKOUNE_SESSION") \[\e[33m\]\w\[\e[0m\] \[\e[1;91m\]$(branch="$(git branch --show-current 2>/dev/null)" && test "$branch" && printf '%s' " $branch")\[\e[0m\]\n\[\e[1;36;1m\]λ\[\e[0m\] ' export PROMPT_DIRTRIM=3 export PROMPT_COMMAND='history -a' export HISTSIZE=100000 diff --git a/.config/kitty/themes/penelope.conf b/.config/kitty/themes/penelope.conf index b19c49b..bc52378 100644 --- a/.config/kitty/themes/penelope.conf +++ b/.config/kitty/themes/penelope.conf @@ -9,12 +9,12 @@ color0 #1d2021 color1 #cc241d color2 #98971a color3 #d79921 -color4 #458588 +color4 #005f87 color5 #b16286 color6 #689d6a color7 #a89984 color8 #928374 -color9 #fb4934 +color9 #ff8059 color10 #b8bb26 color11 #fabd2f color12 #83a598 diff --git a/.config/shell/aliasrc b/.config/shell/aliasrc index 3110687..a423837 100644 --- a/.config/shell/aliasrc +++ b/.config/shell/aliasrc @@ -42,7 +42,6 @@ alias \ sdn="shutdown -h now" \ e='$EDITOR' \ v='$EDITOR' \ - p="pacman" \ xi="xbps-install" \ xr="xbps-remove -R" \ xq="xbps-query" \ diff --git a/.config/shell/profile b/.config/shell/profile index 25fc794..8a299bd 100644 --- a/.config/shell/profile +++ b/.config/shell/profile @@ -1,4 +1,7 @@ +stty discard undef + export PATH="$HOME/.local/bin:$PATH" +export PATH="$PATH:$HOME/go/bin:/usr/local/go/bin" export XDG_CONFIG_HOME=$HOME/.config export XDG_CACHE_HOME=$HOME/.cache export XDG_DATA_HOME=$HOME/.local/share @@ -6,24 +9,27 @@ export XDG_STATE_HOME=$HOME/.local/state export PASSWORD_STORE_DIR=$HOME/.local/share/password-store export PASSWORD_STORE_GPG_OPTS="--no-throw-keyids" -# Starts a gpg-agents and configures it as ssh-agent. -eval $(gpg-agent --daemon 2>/dev/null) -export GPG_TTY="$(tty)" -export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket) - export TERMINAL="st" export EDITOR="kak-desktop" export BLOCKING_EDITOR="kak" export GIT_EDITOR="kak" export BROWSER="firefox" -export PATH="$PATH:$HOME/go/bin:/usr/local/go/bin" -stty discard undef -[ ! -f "$XDG_CONFIG_HOME/shell/shortcutrc" ] && setsid -f shortcuts >/dev/null 2>&1 - if [ "$(uname -s)" = "Darwin" ]; then - export PATH="/opt/homebrew/opt/findutils/libexec/gnubin:$PATH" - export PATH="$HOME/.local/bin/macos.d:$PATH" + export LANG=en_US.UTF-8 export BROWSER="open" - export SASL_PATH=/opt/homebrew/opt/cyrus-sasl/lib/sasl2:/opt/homebrew/opt/cyrus-sasl-xoauth2/lib/sasl2 + + brewpath="$(brew --prefix)" + export PATH="/usr/local/bin:$brewpath/bin:$PATH" + export PATH="$brewpath/opt/findutils/libexec/gnubin:$PATH" + export PATH="$brewpath/opt/util-linux/bin:$brewpath/opt/util-linux/sbin:$PATH" + export PATH="$HOME/.local/bin/macos.d:$PATH" + export SASL_PATH="$brewpath/opt/cyrus-sasl/lib/sasl2:$brewpath/opt/cyrus-sasl-xoauth2/lib/sasl2" fi + +# Starts a gpg-agents and configures it as ssh-agent. +eval $(gpg-agent --daemon 2>/dev/null) +export GPG_TTY="$(tty)" +export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)" + +[ ! -f "$XDG_CONFIG_HOME/shell/shortcutrc" ] && setsid -f shortcuts >/dev/null 2>&1 diff --git a/.local/bin/dmenu-ansi-escape-termcolors b/.local/bin/dmenu-ansi-escape-termcolors new file mode 100755 index 0000000..7c2d2e9 --- /dev/null +++ b/.local/bin/dmenu-ansi-escape-termcolors @@ -0,0 +1,66 @@ +#!/bin/sh +printf '\e[0;30;43mBlack Regular\e[0m \\e[0;30;43m +\e[0;31mRed Regular\e[0m \\e[0;31m +\e[0;32mGreen Regular\e[0m \\e[0;32m +\e[0;33mYello Regular\e[0m \\e[0;33m +\e[0;34mBlue Regular\e[0m \\e[0;34m +\e[0;35mPurple Regular\e[0m \\e[0;35m +\e[0;36mCyan Regular\e[0m \\e[0;36m +\e[0;37mWhite Regular\e[0m \\e[0;37m +\e[1;30;43mBlack Bold\e[0m \\e[1;30;43m +\e[1;31mRed Bold\e[0m \\e[1;31m +\e[1;32mGreen Bold\e[0m \\e[1;32m +\e[1;33mYello Bold\e[0m \\e[1;33m +\e[1;34mBlue Bold\e[0m \\e[1;34m +\e[1;35mPurple Bold\e[0m \\e[1;35m +\e[1;36mCyan Bold\e[0m \\e[1;36m +\e[1;37mWhite Bold\e[0m \\e[1;37m +\e[4;30;43mBlack Underline\e[0m \\e[4;30;43m +\e[4;31mRed Underline\e[0m \\e[4;31m +\e[4;32mGreen Underline\e[0m \\e[4;32m +\e[4;33mYello Underline\e[0m \\e[4;33m +\e[4;34mBlue Underline\e[0m \\e[4;34m +\e[4;35mPurple Underline\e[0m \\e[4;35m +\e[4;36mCyan Underline\e[0m \\e[4;36m +\e[4;37mWhite Underline\e[0m \\e[4;37m +\e[40mBlack Background\e[0m \\e[40m +\e[41mRed Background\e[0m \\e[41m +\e[42mGreen Background\e[0m \\e[42m +\e[43mYello Background\e[0m \\e[43m +\e[44mBlue Background\e[0m \\e[44m +\e[45mPurple Background\e[0m \\e[45m +\e[46mCyan Background\e[0m \\e[46m +\e[0;30;47mWhite Background\e[0m \\e[0;30;47m +\e[0;90mBlack Bright\e[0m \\e[0;90m +\e[0;91mRed Bright\e[0m \\e[0;91m +\e[0;92mGreen Bright\e[0m \\e[0;92m +\e[0;93mYello Bright\e[0m \\e[0;93m +\e[0;94mBlue Bright\e[0m \\e[0;94m +\e[0;95mPurple Bright\e[0m \\e[0;95m +\e[0;96mCyan Bright\e[0m \\e[0;96m +\e[0;97mWhite Bright\e[0m \\e[0;97m +\e[1;90mBlack Bright Bold\e[0m \\e[1;90m +\e[1;91mRed Bright Bold\e[0m \\e[1;91m +\e[1;92mGreen Bright Bold\e[0m \\e[1;92m +\e[1;93mYello Bright Bold\e[0m \\e[1;93m +\e[1;94mBlue Bright Bold\e[0m \\e[1;94m +\e[1;95mPurple Bright Bold\e[0m \\e[1;95m +\e[1;96mCyan Bright Bold\e[0m \\e[1;96m +\e[1;97mWhite Bright Bold\e[0m \\e[1;97m +\e[4;90;43mBlack Bright Underline\e[0m \\e[4;90;43m +\e[4;91mRed Bright Underline\e[0m \\e[4;91m +\e[4;92mGreen Bright Underline\e[0m \\e[4;92m +\e[4;93mYello Bright Underline\e[0m \\e[4;93m +\e[4;94mBlue Bright Underline\e[0m \\e[4;94m +\e[4;95mPurple Bright Underline\e[0m \\e[4;95m +\e[4;96mCyan Bright Underline\e[0m \\e[4;96m +\e[4;97mWhite Bright Underline\e[0m \\e[4;97m +\e[0;100mBlack Bright Background\e[0m \\e[0;100m +\e[0;101mRed Bright Background\e[0m \\e[0;101m +\e[0;102mGreen Bright Background\e[0m \\e[0;102m +\e[0;103mYello Bright Background\e[0m \\e[0;103m +\e[0;104mBlue Bright Background\e[0m \\e[0;104m +\e[0;105mPurple Bright Background\e[0m \\e[0;105m +\e[0;106mCyan Bright Background\e[0m \\e[0;106m +\e[0;30;107mWhite Bright Background\e[0m \\e[0;30;107m +\e[0mReset\e[0m \\e[0m' | dmenu -l 20 | grep -o '\\.*' | vis-clipboard --copy diff --git a/.local/bin/macos.d/kak b/.local/bin/macos.d/kak deleted file mode 100755 index b71191d..0000000 --- a/.local/bin/macos.d/kak +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/sh -eval "exec pn exec oksh -i -l -c 'PNSH_KAK_AUTOSTART=\"$@\" exec oksh -l'" -- cgit v1.2.3