ALT Linux Bugzilla
– Attachment 1157 Details for
Bug 8121
Support of remote repositories in hasher
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
Поддержка удалённых репозиториев в hasher - файл functions
hasher-functions-remote-repos.patch (text/plain), 1.76 KB, created by
Alexey Rusakov
on 2005-10-03 02:17:34 MSD
(
hide
)
Description:
Поддержка удалённых репозиториев в hasher - файл functions
Filename:
MIME Type:
Creator:
Alexey Rusakov
Created:
2005-10-03 02:17:34 MSD
Size:
1.76 KB
patch
obsolete
>--- functions.stock >+++ functions.my >@@ -452,8 +452,54 @@ > echo $$ >"$pidfile" > } > >+#get_packages() >+print_uris() >+{ >+ [ -n "$APT_CONFIG" ] || Fatal "APT_CONFIG undefined." >+ local out >+ if ! out="$("$prog_apt_get" -q=2 -y --print-uris install -- "$@" 2>&1)"; then >+ printf %s\\n "$out" >&2 >+ Fatal "failed to calculate package file list." >+ fi >+ local grep_pattern="^'\\(file\\|copy\\):" >+ local filenames >+ if ! filenames="$(printf %s "$out" | grep -v "$grep_pattern" | cut -d' ' -f2)"; then >+ printf %s\\n "$out" >&2 >+ Fatal "failed to filter package file list." >+ fi >+ for f in $filenames; do >+ [ -r "/var/cache/apt/archives/$f" ] && >+ cp -- "/var/cache/apt/archives/$f" \ >+ "$aptbox/var/cache/apt/archives/" && >+ continue >+ [ -r "$aptbox/../cache/archives/$f" ] && >+ cp -- "$aptbox/../cache/archives/$f" \ >+ "$aptbox/var/cache/apt/archives/" && >+ continue >+ done >+ if ! "$prog_apt_get" -y -d install -- "$@" >&2; then >+ printf %s\\n "$out" >&2 >+ Fatal "failed to download packages." >+ fi >+ mkdir -p $aptbox/../cache/archives >+ >+ local local_uris >+ local sed_pattern="'\\(file\\|copy\\):\\([^']\\+\\)' .*" >+ if ! local_uris="$(printf %s "$out" |sed -ne "s/^$sed_pattern/\\2/pg")"; then >+ printf %s\\n "$out" >&2 >+ Fatal "failed to filter package file list." >+ fi >+ >+ printf %s\\n "$local_uris" && >+ for f in $filenames; do >+ local ff="$aptbox/var/cache/apt/archives/$f" >+ cp -- $ff "$aptbox/../cache/archives/" >+ printf %s\\n "$ff" >+ done && Verbose "packages are ready to install." >+} >+ > # assumed: defined APT_CONFIG, prog_apt_get >-print_uris() >+old_print_uris() > { > [ -n "$APT_CONFIG" ] || Fatal "APT_CONFIG undefined." > local out
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 8121
: 1157