Change fig placements in zshrc and zprofile;

Add system arch based homebrew installation chooser
This commit is contained in:
Philip Henning 2022-02-08 11:53:29 +01:00
parent 355c7bf340
commit d35ce3fbc2
2 changed files with 33 additions and 9 deletions

View file

@ -1,3 +1,10 @@
{%@@ if profile == 'VWAGWOY00349' @@%}
#### FIG ENV VARIABLES ####
# Please make sure this block is at the start of this file.
[ -s ~/.fig/shell/pre.sh ] && source ~/.fig/shell/pre.sh
#### END FIG ENV VARIABLES ####
{%@@ endif @@%}
# #
# {{@@ header() @@}} # {{@@ header() @@}}
# #
@ -28,3 +35,10 @@ export XDG_CONFIG_HOME
# Run VPN-Kit alpine VM to route traffic through Windows and if connected through VPNs # Run VPN-Kit alpine VM to route traffic through Windows and if connected through VPNs
wsl.exe -d wsl-vpnkit service wsl-vpnkit start wsl.exe -d wsl-vpnkit service wsl-vpnkit start
{%@@ endif @@%} {%@@ endif @@%}
{%@@ if profile == 'VWAGWOY00349' @@%}
#### FIG ENV VARIABLES ####
# Please make sure this block is at the end of this file.
[ -s ~/.fig/fig.sh ] && source ~/.fig/fig.sh
#### END FIG ENV VARIABLES ####
{%@@ endif @@%}

View file

@ -1,14 +1,14 @@
#
# {{@@ header() @@}}
#
{%@@ if profile == 'VWAGWOY00349' @@%} {%@@ if profile == 'VWAGWOY00349' @@%}
#### FIG ENV VARIABLES #### #### FIG ENV VARIABLES ####
# Please make sure this block is at the start of this file. # Please make sure this block is at the start of this file.
[ -s {{@@ env['HOME'] @@}}/.fig/shell/pre.sh ] && source {{@@ env['HOME'] @@}}/.fig/shell/pre.sh [ -s ~/.fig/shell/pre.sh ] && source ~/.fig/shell/pre.sh
#### END FIG ENV VARIABLES #### #### END FIG ENV VARIABLES ####
{%@@ endif @@%} {%@@ endif @@%}
#
# {{@@ header() @@}}
#
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc. # Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
# Initialization code that may require console input (password prompts, [y/n] # Initialization code that may require console input (password prompts, [y/n]
# confirmations, etc.) must go above this block; everything else may go below. # confirmations, etc.) must go above this block; everything else may go below.
@ -161,10 +161,13 @@ if [ -f "{{@@ env['HOME'] @@}}/.local/bin/pipx" ]; then
fi fi
{%@@ if profile == 'VWAGWOY00349' @@%} {%@@ if profile == 'VWAGWOY00349' @@%}
#### FIG ENV VARIABLES #### # Decide which homebrew installation (x64_86 / arm64) should be used
# Please make sure this block is at the end of this file. if [ "$(sysctl -n sysctl.proc_translated)" = "1" ]; then
[ -s {{@@ env['HOME'] @@}}/.fig/fig.sh ] && source {{@@ env['HOME'] @@}}/.fig/fig.sh local brew_path="/usr/local/homebrew/bin"
#### END FIG ENV VARIABLES #### else
local brew_path="/opt/homebrew/bin"
fi
export PATH="${brew_path}:${PATH}"
{%@@ endif @@%} {%@@ endif @@%}
# Functions (or more complex aliases) # Functions (or more complex aliases)
@ -194,3 +197,10 @@ EOF
curl http://wttr.in/${1} curl http://wttr.in/${1}
fi fi
} }
{%@@ if profile == 'VWAGWOY00349' @@%}
#### FIG ENV VARIABLES ####
# Please make sure this block is at the end of this file.
[ -s ~/.fig/fig.sh ] && source ~/.fig/fig.sh
#### END FIG ENV VARIABLES ####
{%@@ endif @@%}