diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2017-10-27 15:54:53 -0200 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2017-10-27 15:54:53 -0200 |
commit | 44ac47660dbd6dd27a0d17d5d0ea27a5d3b53e4d (patch) | |
tree | 4f407ca2b2172c4f8f9cc50ce64c20bd12fa68c8 /profile.dot.link | |
parent | c03b504445d8a63d0828bd6d9c792600772a2bfc (diff) | |
download | profile-44ac47660dbd6dd27a0d17d5d0ea27a5d3b53e4d.tar.gz profile-44ac47660dbd6dd27a0d17d5d0ea27a5d3b53e4d.tar.bz2 |
Detect kvmx VM instance
Diffstat (limited to 'profile.dot.link')
-rw-r--r-- | profile.dot.link | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/profile.dot.link b/profile.dot.link index a2a4ddd..93f80eb 100644 --- a/profile.dot.link +++ b/profile.dot.link @@ -43,6 +43,11 @@ if [ -d "/vagrant/bin" ]; then PATH="$PATH:/vagrant/bin" fi +# Add /srv into PATH, useful if we're inside a virtual machine +if [ -d "/srv/bin" ]; then + PATH="$PATH:/srv/bin" +fi + # Add composer into PATH if [ -d "$HOME/.composer/vendor/bin" ]; then PATH="$PATH:$HOME/.composer/vendor/bin:$PATH" @@ -244,6 +249,11 @@ if [ -z "$STARTUP_FOLDER" ] && [ -d "/vagrant" ]; then STARTUP_FOLDER="/vagrant" fi +# Detect if we're inside a kvmx VM +if [ -z "$STARTUP_FOLDER" ] && [ -f "/srv/kvmxfile" ]; then + STARTUP_FOLDER="/srv" +fi + # Make sure we start at the startup folder, defaulting to home cd $STARTUP_FOLDER |