#!/usr/bin/env bash
#> Idempotently installs packages based on OS
function dots-install() {
    if [ -n "$WINDIR" ]; then
        echo "Windows detected"
        "$DOTS_LOC"/win/install.sh
        return
    fi
    if command -v apt-get &>/dev/null; then
        echo "Ubuntu detected"
        sudo "$DOTS_LOC"/ubuntu/install.sh
        return
    fi

    if command -v pacman &>/dev/null; then
        echo "Arch detected"
        "$DOTS_LOC"/arch/sync.sh "$@"
        return
    fi

    echo "Unsupported OS detected"

}
