Skip to content

losedavidpb/bash-dotfiles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

46 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

My .files configuration

My personal dotfiles configuration for Unix machines.

Most of Unix command-line programs can be configured by a list of plain-text hidden files, usually referred to as dotfiles, that are located in the user's home directory. Since I usually use Linux, I decided to create this project that includes all my personal dotfiles configuration.

Structure

After the installation, all dotfiles would be stored at ~/.config/shell folder, so any modifications has to be applied there. The following list is all the content you should know in order to modify my dotfiles.

  • bash/: anything in bash/ are dotfiles for bash
  • zsh/: anything in zsh/ are dotfiles for zsh
  • aliases: includes all the aliases that would be loaded
  • exports: global variables such as PATH would be defined here
  • functions: utilities used to manage this .files or to simplify some tasks
  • old_dotfiles.tar: .files copies created if backup was done at install.sh
  • neofetch: configuration for neofetch that includes an ascii icon
  • termite: configuration for termite shell
  • hyper: configuration for hyper shell

Requirements

It is important to know that any of the following packages would be install by install.sh whether current machine has installed an available package manager. In other case, you will need to install manually.

Dependencies

Since dependencies could vary between Unix machines, install.sh only prepares some of them, so it is recommended to check what dependencies you will need for your current machine to them prepare it manually.

Shell Utilities

As it was mencioned before, functions file includes all the utilities that can be executed in order to facilitate monotonous tasks. Since .files modification could be tedious, some of these functions offer better alternatives that assures a safe and automatic management of those files. It is important to notice that simple commands are defined at aliases, so you have to check both files in order to know what are all the available shell commands.

The following table includes all the functions and aliases used to manage the dotfiles stored at this repository.

Name Type Description Syntax
reload-all-bash Function Reload all dotfiles and bash settings. It is important to notice that ZSH shell is not optimized, so
it will take a lot of time to fully load into shell. Please, use reload-bash instead whether you only
want to reload functions, aliases, or exports.
reload-all-bash
reload-bash Function Reload all dotfiles to apply any changes that was done at internal files reload-bash
shellhelp Function Show information about the passed utility whether it truly exists. If no arguments were passed,
this command would show help information for any single function.
shellhelp [NAME] [NAMES ...]
setexport Function Update value for passed global variable or add a new one which passed value. Changes would
be applied before executing reload-bash.
setexport NAME VALUE
rmexport Function Remove passed global variable whether it exists at current exports file. Changes would be applied
before executing reload-bash.
rmexport NAME
chshell Function Change current shell whether passed value it is an available and valid shell name. Changes would
be applied before executing reload-bash.
chshell NAME
set-shell-simple Function If this command is executed, next time shell runs it would only load necessary files, since performance
is most important than appearance.
set-shell-simple
set-shell-pretty Function If this command is executed, next time shell runs it would load all files, since appearance is most
important than performance.
set-shell-pretty

Installation

git clone https://github.com/losedavidpb/bash-dotfiles
cd bash-dotfiles

sudo apt update
./install.sh

rm -rf bash-dotfiles
source ~/<RC_FILE>