Commit 087a4856 authored by Vitaly Lipatov's avatar Vitaly Lipatov

addrepo/removerepo: fix used repo id string

parent db22b2f8
#!/bin/sh
#
# Copyright (C) 2012 Etersoft
# Copyright (C) 2012 Vitaly Lipatov <lav@etersoft.ru>
# Copyright (C) 2012, 2016 Etersoft
# Copyright (C) 2012, 2016 Vitaly Lipatov <lav@etersoft.ru>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
......@@ -19,26 +19,27 @@
epm_addrepo()
{
local repo="$(eval echo $quoted_args)"
case $PMTYPE in
apt-rpm)
assure_exists apt-repo
sudocmd apt-repo add "$pkg_filenames"
sudocmd apt-repo add "$repo"
;;
apt-dpkg|aptitude-dpkg)
info "You need manually add repo to /etc/apt/sources.list"
;;
yum-rpm)
assure_exists yum-utils
sudocmd yum-config-manager --add-repo "$pkg_filenames"
sudocmd yum-config-manager --add-repo "$repo"
;;
urpm-rpm)
sudocmd urpmi.addmedia "$pkg_filenames"
sudocmd urpmi.addmedia "$repo"
;;
zypper-rpm)
sudocmd zypper ar "$pkg_filenames"
sudocmd zypper ar "$repo"
;;
emerge)
sudocmd layman -a $"pkg_filenames"
sudocmd layman -a "$repo"
;;
pacman)
info "You need manually add repo to /etc/pacman.conf"
......@@ -46,7 +47,7 @@ case $PMTYPE in
#sudocmd repo-add $pkg_filenames
;;
npackd)
sudocmd npackdcl add-repo --url="$pkg_filenames"
sudocmd npackdcl add-repo --url="$repo"
;;
slackpkg)
info "You need manually add repo to /etc/slackpkg/mirrors"
......
#!/bin/sh
#
# Copyright (C) 2012 Etersoft
# Copyright (C) 2012 Vitaly Lipatov <lav@etersoft.ru>
# Copyright (C) 2012, 2016 Etersoft
# Copyright (C) 2012, 2016 Vitaly Lipatov <lav@etersoft.ru>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
......@@ -19,32 +19,33 @@
epm_removerepo()
{
local repo="$(eval echo $quoted_args)"
case $PMTYPE in
apt-rpm)
assure_exists apt-repo
sudocmd apt-repo rm "$quoted_args"
sudocmd apt-repo rm "$repo"
;;
apt-dpkg|aptitude-dpkg)
info "You need remove repo from /etc/apt/sources.list"
;;
yum-rpm)
assure_exists yum-utils
sudocmd yum-config-manager --disable "$pkg_filenames"
sudocmd yum-config-manager --disable "$repo"
;;
urpm-rpm)
sudocmd urpmi.removemedia "$pkg_filenames"
sudocmd urpmi.removemedia "$repo"
;;
zypper-rpm)
sudocmd zypper removerepo "$pkg_filenames"
sudocmd zypper removerepo "$repo"
;;
emerge)
sudocmd layman "-d$pkg_filenames"
sudocmd layman "-d$repo"
;;
pacman)
info "You need remove repo from /etc/pacman.conf"
;;
npackd)
sudocmd npackdcl remove-repo --url="$pkg_filenames"
sudocmd npackdcl remove-repo --url="$repo"
;;
slackpkg)
info "You need remove repo from /etc/slackpkg/mirrors"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment