Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

christopherraa/Bashrc

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
22 Commits
 
 
 
 
 
 

Repository files navigation

Bashrc

Bash-configuration and convenience.

I use this repository by including the following at the bottom of my ~/.bashrc file:

run_scripts()
{
  for script in $1/*.sh; do
    [ -x "$script" ] || continue
    . $script
  done
}
run_scripts ~/.bashrc.d

The above piece of code has been shamelessly copied from http://www.turnkeylinux.org/blog/generic-shell-hooks .

The next step is pointing ~/.bashrc.d to ~/PATH/TO/THIS/REPO/scripts (tip: ln is your friend). After that you control which files are loaded by toggling the executable-flag on/off. If you have your own stuff you'd like to load as well then just place that in ~/bashrc.d and add the following to the bottom of the ~/.bashrc file:

run_scripts ~/PATH/TO/THIS/REPO/scripts

If there are any questions, feel free to reach out on here or on Twitter.

About

Bash-configuration and convenience

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.