From 4e4626bd8c52626ada5e796ff68d461a410bf028 Mon Sep 17 00:00:00 2001 From: JGill Date: Sat, 5 Oct 2024 13:14:14 +0930 Subject: [PATCH] Fix custom config file import issue --- .zshrc | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/.zshrc b/.zshrc index 62cc68f..260cc17 100644 --- a/.zshrc +++ b/.zshrc @@ -14,14 +14,11 @@ source "$HOME/.config/ezsh/ezshrc.zsh" # Place all of your personal configurations over there ZSH_CONFIGS_DIR="$HOME/.config/ezsh/zshrc" -if [ "$(ls -A $ZSH_CONFIGS_DIR)" ]; then - for file in "$ZSH_CONFIGS_DIR"/* "$ZSH_CONFIGS_DIR"/.*; do - # Exclude '.' and '..' from being sourced - if [ -f "$file" ]; then - source "$file" - fi - done -fi +for file in "$ZSH_CONFIGS_DIR"/*(DN); do + if [ -f "$file" ]; then + source "$file" + fi +done # Now source oh-my-zsh.sh so that any plugins added in ~/.config/ezsh/zshrc/* files also get loaded source $ZSH/oh-my-zsh.sh