Articles tagged bash

  1. Bash alias: Build on all CPU cores

    Linux:

    1
    
    alias makej="make -j $(cat /proc/cpuinfo | grep processor | wc | sed -r 's/^ +([0-9])+.*//')"
    

    Mac:

    1
    
    alias makej="make -j $(sysctl hw.ncpu | awk '{print $2}')"
    
    Read more
  2. bash: Home Directory Not Replaced With Tilde (~)

    After switching my computers to Arch Linux, reusing the existing home directories, I had the problem that the bash did not replace the user's home directory with the tilde character (~) in the prompt. The solutions for this problem is easy: somewhere in the bash-internals a check tests whether the output of pwd matches the contents of $HOME. $HOME

    Read more