From 892eee106f9c81aa05297d745d4542298d4bede4 Mon Sep 17 00:00:00 2001 From: GaspardCulis Date: Sat, 1 Jun 2024 03:35:15 +0200 Subject: [PATCH] shell -> bash: Reorder executions and imports to fix execution orders --- shell/bash/.bash_exec | 5 +++++ shell/bash/.bash_profile | 5 ----- shell/bash/.bashrc | 18 +++++++++--------- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/shell/bash/.bash_exec b/shell/bash/.bash_exec index d48c6e4..7294194 100644 --- a/shell/bash/.bash_exec +++ b/shell/bash/.bash_exec @@ -1,5 +1,10 @@ #!/usr/bin/bash +# Start DE if on tty1 +if [ "$(tty)" = /dev/tty1 ]; then + exec Hyprland +fi + # Start in tmux by default [[ $TERM != "screen" ]] && [ -z "$TMUX" ] && exec tmux diff --git a/shell/bash/.bash_profile b/shell/bash/.bash_profile index 0e235c5..5545f00 100644 --- a/shell/bash/.bash_profile +++ b/shell/bash/.bash_profile @@ -3,8 +3,3 @@ # [[ -f ~/.bashrc ]] && . ~/.bashrc - -# Start DE if on tty1 -if [ "$(tty)" = /dev/tty1 ]; then - exec Hyprland -fi diff --git a/shell/bash/.bashrc b/shell/bash/.bashrc index 635f052..5842e2f 100755 --- a/shell/bash/.bashrc +++ b/shell/bash/.bashrc @@ -40,6 +40,15 @@ if [ -f "$CARGO_ENV_PATH" ]; then . "$CARGO_ENV_PATH" fi +FLUTTER_PATH="/opt/flutter/bin" +if test -d "$FLUTTER_PATH"; then + export PATH="$FLUTTER_PATH:$PATH" +fi + +if [ -f ~/.bash_exec ]; then + source ~/.bash_exec +fi + if command -v starship > /dev/null; then eval "$(starship init bash)" fi @@ -47,12 +56,3 @@ fi if command -v zoxide > /dev/null; then eval "$(zoxide init --cmd cd bash)" fi - -if [ -f ~/.bash_exec ]; then - source ~/.bash_exec -fi - -FLUTTER_PATH="/opt/flutter/bin" -if test -d "$FLUTTER_PATH"; then - export PATH="$FLUTTER_PATH:$PATH" -fi