bash: export LC_ALL to attempt to fix nvim and tmux unicode shifting

This commit is contained in:
proctor committed 2026-03-26 13:39:14 -05:00
1 parent a96c155f43
commit 644e8c26d3
1 file changed
+10 -13
+10 -13
View File
@@ -7,6 +7,7 @@ PATH=$PATH:$HOME
MANPATH=$MANPATH:/usr/local/opt/erlang/lib/erlang/man MANPATH=$MANPATH:/usr/local/opt/erlang/lib/erlang/man
export XDG_CONFIG_HOME=$HOME/.config export XDG_CONFIG_HOME=$HOME/.config
export LC_ALL=en_US.UTF-8
set -o vi set -o vi
export EDITOR='nvim' export EDITOR='nvim'
@@ -18,14 +19,13 @@ if which brew 2>/dev/null && [[ -f $(brew --prefix)/etc/bash_completion ]]; then
fi fi
# came from Aaron Lasseigne (AaronLasseigne on GitHub) # came from Aaron Lasseigne (AaronLasseigne on GitHub)
battery_status() battery_status() {
{
HEART='♥ ' HEART='♥ '
NON='\[\e[0m\]' NON='\[\e[0m\]'
RED='\[\e[0;31m\]' RED='\[\e[0;31m\]'
battery_info=`ioreg -rc AppleSmartBattery` battery_info=$(ioreg -rc AppleSmartBattery)
current_charge=$(echo $battery_info | grep -o '"CurrentCapacity" = [0-9]\+' | cut -d ' ' -f 3) current_charge=$(echo $battery_info | grep -o '"CurrentCapacity" = [0-9]\+' | cut -d ' ' -f 3)
total_charge=$(echo $battery_info | grep -o '"MaxCapacity" = [0-9]\+' | cut -d ' ' -f 3) total_charge=$(echo $battery_info | grep -o '"MaxCapacity" = [0-9]\+' | cut -d ' ' -f 3)
@@ -35,11 +35,11 @@ battery_status()
fi fi
echo -n "${RED}" echo -n "${RED}"
for i in `seq 1 $charged_slots`; do echo -n "$HEART"; done for i in $(seq 1 $charged_slots); do echo -n "$HEART"; done
echo -n "${NON}" echo -n "${NON}"
if [[ $charged_slots -lt 10 ]]; then if [[ $charged_slots -lt 10 ]]; then
for i in `seq 1 $(echo "10-$charged_slots" | bc)`; do echo -n "$HEART"; done for i in $(seq 1 $(echo "10-$charged_slots" | bc)); do echo -n "$HEART"; done
fi fi
} }
@@ -57,13 +57,12 @@ safesource ~/.bash_local
export PATH="/usr/local/heroku/bin:$PATH" export PATH="/usr/local/heroku/bin:$PATH"
function repeat() { function repeat() {
local count=$1; local count=$1
shift; shift
echo "running '$@' for $count times" echo "running '$@' for $count times"
for i in $(eval echo "{1..$count}") for i in $(eval echo "{1..$count}"); do
do
$@ || break $@ || break
done done
} }
@@ -89,13 +88,11 @@ function my_git_user_name() {
git config --get user.name git config --get user.name
} }
function my_commits_for_this_past_year() function my_commits_for_this_past_year() {
{
git log --author="$(my_git_user_name)" --after="$(end_of_last_year)" origin/master git log --author="$(my_git_user_name)" --after="$(end_of_last_year)" origin/master
} }
function truncate_logs() function truncate_logs() {
{
find log -type f -name "*.log" | xargs -I {} bash -c 'echo "" > {}' find log -type f -name "*.log" | xargs -I {} bash -c 'echo "" > {}'
} }