Skip to content

Instantly share code, notes, and snippets.

@Voronoff
Last active August 25, 2017 21:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Voronoff/734ff481da773ba912585b2d8d282461 to your computer and use it in GitHub Desktop.
Save Voronoff/734ff481da773ba912585b2d8d282461 to your computer and use it in GitHub Desktop.
Bash on Ubuntu on Windows configuration
#additions
# For switching to mounted home easily
cd() {
if [[ $@ == "m~" ]]; then
command cd "/mnt/c/Users/david"
else
command cd "$@"
fi
}
# To start xming
xming() {
command Xming.exe :0 -clipboard -multiwindow &
}
# To open a file using Sublime, starting Xming if it isn't already running
subl () {
if [[ $(ps | grep Xming.exe) ]]; then
command subl "$@"
else
xming
command subl "$@"
fi
}
# Set the display to localhost for xming
export DISPLAY=localhost:0.0 
#disable the bell sound on backspace
set bell-style none
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment