Last change
on this file since 29697 was 29697, checked in by Jeremy Symon, 9 years ago |
Addded ReadMe files containing setup instructions for all package managers
|
File size:
1.1 KB
|
Line | |
---|
1 | origin="Greenstone"
|
---|
2 | label="greenstone"
|
---|
3 | codename="greenstone"
|
---|
4 | domain="greenstone.org"
|
---|
5 | arch="i386 amd64 source"
|
---|
6 | description="Apt repository for Greenstone packages"
|
---|
7 | base=$(dirname $0)
|
---|
8 | repos=$base/repos
|
---|
9 | setup_cmd_instruction="To use this repository, run the following commands in a terminal as root:"
|
---|
10 | install_cmd_instruction="You should now be able to install greenstone packages with:"
|
---|
11 |
|
---|
12 | y() {
|
---|
13 | echo "$@? [y|n]..." >&2
|
---|
14 | echo -n "> " >&2
|
---|
15 | read cho
|
---|
16 | test "$cho" = "y" -o "$cho" = "Y"
|
---|
17 | return $?
|
---|
18 | }
|
---|
19 |
|
---|
20 | get() {
|
---|
21 | echo "$1? [$2]..." >&2
|
---|
22 | echo -n "> " >&2
|
---|
23 | read cho
|
---|
24 | test -z $cho && {
|
---|
25 | cho=$2
|
---|
26 | echo "Set to default '$cho'" >&2
|
---|
27 | }
|
---|
28 | echo $cho
|
---|
29 | }
|
---|
30 |
|
---|
31 | write() {
|
---|
32 | file=$1
|
---|
33 | if touch $file 2>/dev/null; then
|
---|
34 | cat - > $file
|
---|
35 | else
|
---|
36 | cat - | sudo tee $file
|
---|
37 | fi
|
---|
38 | }
|
---|
39 |
|
---|
40 | get_gpg() {
|
---|
41 | if test -f $base/gpg.key.id; then
|
---|
42 | keyid=$(cat $base/gpg.key.id)
|
---|
43 | else
|
---|
44 | gpg --list-keys >&2
|
---|
45 | echo "Enter the keyid of the GPG key to use:" >&2
|
---|
46 | while test -z $keyid; do
|
---|
47 | echo -n "> " >&2
|
---|
48 | read keyid
|
---|
49 | done
|
---|
50 | echo $keyid > $base/gpg.key.id
|
---|
51 | echo >&2
|
---|
52 | fi
|
---|
53 | echo $keyid
|
---|
54 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.