News for hackers. Stuff that matters.
Re:Ask HN: Best things in your bash_profile/aliases? by carl-erwin on Monday January 14, 2019 @05:40AM (#18902062)
One thing I do is to put this snippet in .bashrc or .profile

  for i in ${HOME}/.bash.d/*.sh
  do
    if [ -r ${i} ] ; then
        . ${i}
    fi
  done
  
And drop some custom scripts in ${HOME}/.bash.d/ like alias.sh, env.sh

(my common .bash.d scripts are saved in a git repository)

Re:Ask HN: Best things in your bash_profile/aliases? by ob6160 on Monday January 14, 2019 @05:44AM (#18902075)
Whoa, I know someone who does exactly this. Is this a common pattern?

Unless you're him!

Re:Ask HN: Best things in your bash_profile/aliases? by nailer on Monday January 14, 2019 @09:33AM (#18903181)
.d is a common Unix include directory pattern. See cron.d, xinetrc.d, conf.d etc. Packages can just add/remove things to the include dir rather than modifying the main config.
Re:Ask HN: Best things in your bash_profile/aliases? by stevekemp on Tuesday January 15, 2019 @02:57PM (#18914391)
I do that in my dotfiles too:

The main include:

https://github.com/skx/dotfiles/blob/master/.bashrc

The actual dotfiles:

https://github.com/skx/dotfiles/

(People usually copy the literate emacs configuration ..)