From d18693d621bd84db2aee1e833f1968d138905d50 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Sat, 28 Nov 2020 21:11:05 -0300 Subject: Feat: possible support for rc.d and profile.d --- profile.dot.link | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/profile.dot.link b/profile.dot.link index 3c83dbb..bd13750 100644 --- a/profile.dot.link +++ b/profile.dot.link @@ -389,12 +389,30 @@ fi # Make sure we start at the startup folder, defaulting to home cd $STARTUP_FOLDER -# Run startup commands -#if [ ! -z "$STARTUP" ]; then -# $STARTUP +# Include other profiles +if [ -d "$HOME/.profile.d" ]; then + scripts="`find $HOME/.profile.d -type f`" + + for script in $scripts; do + include $script + done +fi + +# Include custom profiles +#if [ -d "$HOME/.custom/profile.d" ]; then +# scripts="`find $HOME/.custom/profile.d -type f`" +# +# for script in $scripts; do +# include $script +# done #fi # Run startup scripts -#if [ -d "$HOME/.custom/profile.d" ]; -# run-parts $HOME/.custom/profile.d +#if [ -d "$HOME/.custom/rc.d" ]; then +# run-parts $HOME/.custom/rc.d +#fi + +# Run startup commands +#if [ ! -z "$STARTUP" ]; then +# $STARTUP #fi -- cgit v1.2.3