there is one AUR now
This commit is contained in:
parent
a450ff9708
commit
0496e2c887
25
prm
25
prm
|
@ -6,9 +6,7 @@
|
||||||
_self="${0##*/}"
|
_self="${0##*/}"
|
||||||
|
|
||||||
cfg_workdir="$PWD"
|
cfg_workdir="$PWD"
|
||||||
|
cfg_aur_url="https://aur.archlinux.org"
|
||||||
# Version 4 by default.
|
|
||||||
cfg_aur_version='4'
|
|
||||||
|
|
||||||
err() { printf "$@" >&2; }
|
err() { printf "$@" >&2; }
|
||||||
|
|
||||||
|
@ -68,17 +66,8 @@ aur.get() {
|
||||||
read -r pkg_aur_info
|
read -r pkg_aur_info
|
||||||
|
|
||||||
# A temporary hack till AUR4 becomes the main version
|
# A temporary hack till AUR4 becomes the main version
|
||||||
if (( cfg_aur_version == 4 )); then
|
|
||||||
read -r pkg_base < <( jshon -e results -e PackageBase -u <<< "$pkg_aur_info" )
|
read -r pkg_base < <( jshon -e results -e PackageBase -u <<< "$pkg_aur_info" )
|
||||||
tarball_path="/cgit/aur.git/snapshot/${pkg_base}.tar.gz"
|
tarball_path="/cgit/aur.git/snapshot/${pkg_base}.tar.gz"
|
||||||
else
|
|
||||||
{
|
|
||||||
read -r pkg_base
|
|
||||||
read -r tarball_path
|
|
||||||
} < <(
|
|
||||||
jshon -e results -e PackageBase -u -p -e URLPath -u <<< "$pkg_aur_info"
|
|
||||||
)
|
|
||||||
fi
|
|
||||||
|
|
||||||
(( flag_force )) || {
|
(( flag_force )) || {
|
||||||
[[ -d "${cfg_workdir}/${pkg_base}" ]] && {
|
[[ -d "${cfg_workdir}/${pkg_base}" ]] && {
|
||||||
|
@ -195,10 +184,6 @@ main() {
|
||||||
action='search'
|
action='search'
|
||||||
flag_search_syncdb=1;;
|
flag_search_syncdb=1;;
|
||||||
|
|
||||||
(-V)
|
|
||||||
cfg_aur_version="$2"
|
|
||||||
shift;;
|
|
||||||
|
|
||||||
(-u)
|
(-u)
|
||||||
cfg_aur_url="$2"
|
cfg_aur_url="$2"
|
||||||
shift;;
|
shift;;
|
||||||
|
@ -232,14 +217,6 @@ main() {
|
||||||
unset flag_search_aur flag_search_syncdb
|
unset flag_search_aur flag_search_syncdb
|
||||||
}
|
}
|
||||||
|
|
||||||
if [[ -z "$cfg_aur_url" ]]; then
|
|
||||||
if (( cfg_aur_version == 3 )); then
|
|
||||||
cfg_aur_url="https://aur.archlinux.org"
|
|
||||||
else
|
|
||||||
cfg_aur_url="https://aur4.archlinux.org"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
cfg_aur_api="${cfg_aur_url}/rpc.php"
|
cfg_aur_api="${cfg_aur_url}/rpc.php"
|
||||||
|
|
||||||
[[ "$action" ]] || {
|
[[ "$action" ]] || {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user