dep

Package manager for embedded C libraries
git clone git://git.finwo.net/app/dep
Log | Files | Refs | README | LICENSE

commit ac823ace7fd87b6f6ebc66922c80f8257fbab320
parent 9a54ec9c715c3b27ff8107f079f339708db890db
Author: finwo <finwo@pm.me>
Date:   Tue, 14 Nov 2017 23:54:54 +0100

Added crude install script

Diffstat:
Ainstall.sh | 40++++++++++++++++++++++++++++++++++++++++
1 file changed, 40 insertions(+), 0 deletions(-)

diff --git a/install.sh b/install.sh @@ -0,0 +1,40 @@ +#!/usr/bin/env bash + +# Verify root privileges +if [[ $EUID -ne 0 ]]; then + echo "This script must be run as root" >&2 + exit 1 +fi + +# Print "logo" +echo " ,_," +echo " (v) DEP general-purpose" +echo " \\_/ dependency manager" +echo "==\"==" + +# Check if curl is present +command -v curl &>/dev/null || { + + # Check if we can install it + command -v apt-get &>/dev/null || { + echo "cUrl is missing and we're not able to install it" >&2 + exit 1 + } + + echo "Installing cUrl" + apt-get install -y -qq curl || { + echo "Unable to install cUrl" + } + +} + +# Default install directory +mkdir -p /usr/local/bin/dep + +# Main script +curl -L# https://raw.githubusercontent.com/cdeps/dep/master/dep > /usr/local/bin/dep +chmod +x /usr/local/bin/dep + +# Repository manager +curl -L# https://raw.githubusercontent.com/cdeps/dep/master/dep-repo > /usr/local/bin/dep-repo +chmod +x /usr/local/bin/dep-repo