summaryrefslogtreecommitdiff
path: root/src/xi.sh
blob: aaad140504558598efd0aab5b90e4f4775dde05f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/bin/bash

[ -z "${LIBDIR}" ] && LIBDIR=/usr/lib/xipkg
. ${LIBDIR}/profile.sh
. ${LIBDIR}/sync.sh
. ${LIBDIR}/get.sh

export SYSROOT=/
export CONF_FILE="/etc/xipkg.conf"
export VERBOSE=false
export RESOLVE_DEPS=true
export DO_SYNC=true
export UNSAFE=false
export NOCONFIRM=false

while getopts ":r:c:nluyv" opt; do
    case "${opt}" in
        r)
            SYSROOT="${OPTARG}"
            ;;
        c)
            CONF_FILE="${OPTARG}"
            ;;
        n)
            RESOLVE_DEPS=false
            ;;
        l)
            DO_SYNC=false
            ;;
        u)
            UNSAFE=true
            ;;
        y)
            NOCONFIRM=true
            ;;
        v)
            VERBOSE=true
            ;;
    esac
done

shift $((OPTIND-1))

download $@