GithubHelp home page GithubHelp logo

bash-config's Introduction

bash-config

Unix/Linux environment configuration scripts for interactive and non-interactive shell startup varying by operating system and host.

Configurations are included for Bash, Git, HTop, Java, Python, Tmux, and Vim.

Installation

These files can be installed automatically with the setup.sh script. It automatically backs up files that it is replacing.

$ ./setup.sh

Differences between these files and the current system configuration can be found using the diff.sh script.

$ ./diff.sh

Java Configuration

Java configurations often vary by host and JDK version, so these are likely to never exactly match the base in this project.

So to configure individual systems.

  1. Create or update the ~/.java-JDK*.cfg scripts to reflect the local JDK location.
  2. Modify the appropriate local copy of ~/.java-X.cfg to point the ~/.java-JDK*.cfg script.

Bash Startup Notes

The bash startup sequence on login is:

  1. Execute /etc/profile.
  2. Execute the first file found of ~/.bash_profile, ~/.bash_login, or ~/.profile.

The behaviors included here are:

  1. ~/.bash_profile will run ~/.bashrc.
  2. ~/.bashrc will run ~/.bashrc.OS and ~/.bashrc.HOSTNAME.

Reference

From "man bash"

When bash is invoked as an interactive login shell, or as a non-interactive shell with the --login option, it first reads and executes commands from the file /etc/profile, if that file exists. After reading that file, it looks for ~/.bash_profile, ~/.bash_login, and ~/.profile, in that order, and reads and executes commands from the first one that exists and is readable. The --nopro‐file option may be used when the shell is started to inhibit this behavior.

When a login shell exits, bash reads and executes commands from the file ~/.bash_logout, if it exists.

When an interactive shell that is not a login shell is started, bash reads and executes commands from /etc/bash.bashrc and ~/.bashrc, if these files exist. This may be inhibited by using the --norc option. The --rcfile file option will force bash to read and execute commands from file instead of /etc/bash.bashrc and ~/.bashrc.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.