File: preseed_fetch

package info (click to toggle)
preseed 1.66
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, jessie-kfreebsd-proposed-updates
  • size: 776 kB
  • sloc: sh: 390; perl: 105; makefile: 5
file content (17 lines) | stat: -rw-r--r-- 311 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

. /lib/preseed/preseed.sh

# eat options starting with a -, so we can pass them on
while expr "$1" : "-" >/dev/null; do
	OPTS="$OPTS $1"
	shift
done

src="$1"
dst="$2"

last=/var/run/preseed.last_location
url=$(make_absolute_url "$src" "$(test -r $last && cat $last)")

fetch-url $OPTS "$url" "$dst"