blob: 8b1d5b8382062f0ed5532c0488ec1241229a9d7e (
plain)
1 #!/bin/bash
2 #
3 # Print a list of files to download; allows to either download the
4 # files required to install a package, all files (including those you
5 # already have installed) to install a package, or all files required
6 # to update your system
7 #
8 # Johannes Winkelmann <jw@tks6.net>
9
10 version=1.1
11
12 args=()
13 for a in $@; do
14 if [ $a == "--all" ]; then
15 ALL="yes"
16 elif [ $a == "--diff" ]; then
17 DIFF="yes"
18 else
19 args=(${args[*]} $a)
20 fi
21 done
22
23 if [ "$args" = "" ] && [ ! "$DIFF" = "yes" ]; then
24 echo "Usage: `basename $0` <port1> [<port2> ...]"
25 echo " `basename $0` --all <port1> [<port2> ...]"
26 echo " `basename $0` --diff"
27 exit -1
28 fi
29
30
31
32 if [ "$DIFF" = "yes" ]; then
33 list=(`prt-get quickdiff`)
34 elif [ "$ALL" = "yes" ]; then
35 list=(`prt-get quickdep $@`)
36 else
37 list=(`prt-get depends ${args[*]}|grep "\[ "|awk '{print $3}'`)
38 fi
39
40 for p in ${list[*]}; do
41 . `prt-get path $p`/Pkgfile
42 for s in ${source[*]}; do
43 echo $s|grep tp:
44 done
45 done
|