Created
September 14, 2013 00:45
-
-
Save marioplumbarius/6557777 to your computer and use it in GitHub Desktop.
Shell scripts to check if certain dpkg packages are installed on linux systems.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
## npm | |
is_npm_installed=$(dpkg -l | grep -i npm | awk '{print $2}') | |
if [ '$is_npm_installed' == 'npm' ] | |
then | |
is_npm_installed=true | |
else | |
is_npm_installed=false | |
fi | |
echo npm is installed $is_npm_installed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment