Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
eepm
Commits
d37a73d7
Commit
d37a73d7
authored
Sep 18, 2012
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Plain Diff
backported to M60P as 1.0.1-alt0.M60P.1 (with rpmbph script)
parents
0fd3c487
41142488
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
125 additions
and
22 deletions
+125
-22
TODO
TODO
+1
-1
epm
bin/epm
+8
-1
epm-addrepo
bin/epm-addrepo
+4
-1
epm-check
bin/epm-check
+1
-1
epm-filelist
bin/epm-filelist
+5
-1
epm-install
bin/epm-install
+4
-4
epm-removerepo
bin/epm-removerepo
+7
-4
epm-repolist
bin/epm-repolist
+8
-4
epm-requires
bin/epm-requires
+66
-0
epm-search_file
bin/epm-search_file
+1
-0
epm-upgrade
bin/epm-upgrade
+1
-3
eepm.spec
eepm.spec
+19
-2
No files found.
TODO
View file @
d37a73d7
2. Дописать таблицу на вики на основании реализованных команд.
3. Доделать и проверить deplist|requires
bin/epm
View file @
d37a73d7
...
...
@@ -62,6 +62,7 @@ set_pm_type
verbose
=
quiet
=
nodeps
=
force
=
non_interactive
=
skip_installed
=
show_command_only
=
...
...
@@ -114,6 +115,9 @@ check_command()
-qi
|
info|show
)
# HELPCMD: print package detail info
epm_cmd
=
info
;;
requires|deplist
)
# HELPCMD: print package requires
epm_cmd
=
requires
;;
clean
)
# HELPCMD: clean local package cache
epm_cmd
=
clean
;;
...
...
@@ -156,7 +160,7 @@ check_command()
addrepo|ar
)
# HELPCMD: add package repo
epm_cmd
=
addrepo
;;
repolist|sl
)
# HELPCMD: print repo list
repolist|sl
|listrepo
)
# HELPCMD: print repo list
epm_cmd
=
repolist
;;
removerepo|rr
)
# HELPCMD: remove package repo
...
...
@@ -192,6 +196,9 @@ for opt in "$@" ; do
--nodeps
)
# HELPOPT: skip dependency check (during install/simulate and so on)
nodeps
=
"--nodeps"
;;
--force
)
# HELPOPT: force install/remove package (f.i., override)
force
=
"--force"
;;
--auto
)
# HELPOPT: non interactive mode
non_interactive
=
1
;;
...
...
bin/epm-addrepo
View file @
d37a73d7
...
...
@@ -21,7 +21,10 @@
epm_addrepo
()
{
case
$PMTYPE
in
apt-rpm|apt-dpkg
)
apt-rpm
)
docmd
$SUDO
apt-repo add
$pkg_filenames
;;
apt-dpkg
)
echo
"You need manually add repo to /etc/apt/sources.list"
;;
yum-rpm
)
...
...
bin/epm-check
View file @
d37a73d7
...
...
@@ -33,7 +33,7 @@ case $PMTYPE in
;;
yum-rpm
)
docmd package-cleanup
--leaves
package-cleanup
--leaves
| xargs yum remove
a
=
package-cleanup
--leaves
| xargs yum remove
;;
urpm-rpm
)
docmd
$SUDO
urpme
--auto-orphans
...
...
bin/epm-filelist
View file @
d37a73d7
...
...
@@ -18,6 +18,8 @@
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
#
load_helper epm-query
epm_filelist
()
{
[
-n
"
$pkg_filenames
"
]
||
fatal
"Run query without names"
...
...
@@ -46,6 +48,8 @@ case $PMTYPE in
;;
esac
docmd
$CMD
$pkg_filenames
docmd
$CMD
$pkg_filenames
&&
return
epm_query
>
/dev/null
||
fatal
"Query filelist for non installed packages does not realized"
}
bin/epm-install
View file @
d37a73d7
...
...
@@ -40,7 +40,7 @@ filter_out_installed_packages()
*
)
cat
;;
esac
|
sed
-e
"s|rpm-build-altlinux-compat||g"
| filter_strip_spaces
esac
|
sed
-e
"s|rpm-build-altlinux-compat
[^ ]
||g"
| filter_strip_spaces
}
...
...
@@ -127,7 +127,7 @@ epm_install_files()
case
$PMTYPE
in
apt-rpm|urpm-rpm
)
docmd
$SUDO
rpm
-Uvh
--
force
$nodeps
$@
&&
return
docmd
$SUDO
rpm
-Uvh
$
force
$nodeps
$@
&&
return
# use install_names
;;
apt-dpkg
)
...
...
@@ -135,8 +135,8 @@ epm_install_files()
docmd
$SUDO
apt-get
-f
install
return
;;
yum-rpm
)
docmd
$SUDO
rpm
-Uvh
--
force
$@
&&
return
docmd
$SUDO
yum
--nogpgcheck
local
install
$@
docmd
$SUDO
rpm
-Uvh
$
force
$@
&&
return
docmd
$SUDO
yum
--nogpgcheck
install
$@
return
;;
pkg_add
)
docmd
$SUDO
pkg_add
$@
...
...
bin/epm-removerepo
View file @
d37a73d7
...
...
@@ -21,20 +21,23 @@
epm_removerepo
()
{
case
$PMTYPE
in
apt-rpm|apt-dpkg
)
apt-rpm
)
docmd
$SUDO
apt-repo
rm
$pkg_filenames
;;
apt-dpkg
)
echo
"You need remove repo from /etc/apt/sources.list"
;;
yum-rpm
)
echo
"You need remove repo from /etc/yum.repos.d/"
;;
urpm-rpm
)
docmd
$SUDO
urpmi.removemedia
$pkg_names
docmd
$SUDO
urpmi.removemedia
$pkg_
file
names
;;
zypper-rpm
)
docmd
$SUDO
zypper removerepo
$pkg_names
docmd
$SUDO
zypper removerepo
$pkg_
file
names
;;
emerge
)
docmd
$SUDO
layman
-d
$pkg_names
docmd
$SUDO
layman
-d
$pkg_
file
names
;;
pacman
)
echo
"You need remove repo from /etc/pacman.conf"
...
...
bin/epm-repolist
View file @
d37a73d7
...
...
@@ -31,20 +31,24 @@ print_apt_sources_list()
epm_repolist
()
{
case
$PMTYPE
in
apt-rpm|apt-dpkg
)
docmd print_apt_sources_list /etc/apt/sources.list /etc/apt/sources.list.d/
*
apt-rpm
)
docmd apt-repo list
;;
apt-dpkg
)
showcmd
cat
/etc/apt/sources.list
*
print_apt_sources_list /etc/apt/sources.list /etc/apt/sources.list.d/
*
.list
;;
yum-rpm
)
docmd yum repolist
;;
urpm-rpm
)
docmd urpmq
--list-
media
docmd urpmq
--list-
url
;;
zypper-rpm
)
docmd zypper sl
-d
;;
emerge
)
docmd layman
-L
docmd layman
-L
;;
pacman
)
docmd
cat
/etc/pacman.conf
...
...
bin/epm-requires
0 → 100644
View file @
d37a73d7
#!/bin/sh
#
# Copyright (C) 2012 Etersoft
# Copyright (C) 2012 Vitaly Lipatov <lav@etersoft.ru>
#
# This file is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
#
load_helper epm-packages
# TODO: combine with -qa (the difference only in return status now)
epm_requires
()
{
[
-n
"
$pkg_filenames
"
]
||
fatal
"Run query without names"
# by file package
case
$PMTYPE
in
apt-rpm|urpm-rpm|zypper-rpm|yum-rpm
)
CMD
=
"rpm -q --requires -p"
;;
apt-dpkg
)
showcmd dpkg
-s
$pkg_files
a
=
dpkg
-s
$pkg_names
|
grep
"^Depends:"
|
sed
"s|^Depends:||g"
return
;;
*
)
fatal
"Do not known command for
$PMTYPE
"
;;
esac
[
-n
"
$pkg_files
"
]
&&
docmd
$CMD
$pkg_files
# by file name
case
$PMTYPE
in
apt-rpm|urpm-rpm|zypper-rpm
)
# FIXME: use hi level commands
CMD
=
"rpm -q --requires"
;;
yum-rpm
)
CMD
=
"yum deplist"
;;
apt-dpkg
)
CMD
=
"apt-cache depends"
;;
*
)
fatal
"Do not known command for
$PMTYPE
"
;;
esac
[
-n
"
$pkg_names
"
]
&&
docmd
$CMD
$pkg_names
}
bin/epm-search_file
View file @
d37a73d7
...
...
@@ -18,6 +18,7 @@
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
#
# TODO: port or rewrite apt-file
# https://bugzilla.altlinux.org/show_bug.cgi?id=14449
local_content_search
()
{
...
...
bin/epm-upgrade
View file @
d37a73d7
...
...
@@ -20,8 +20,6 @@
epm_upgrade
()
{
[
-n
"
$pkg_filenames
"
]
&&
fatal
"No need any args for upgrade command"
echo
"Run command for upgrade packages"
case
$PMTYPE
in
apt-rpm|apt-dpkg
)
...
...
@@ -55,5 +53,5 @@ epm_upgrade()
;;
esac
docmd
$SUDO
$CMD
docmd
$SUDO
$CMD
$pkg_filenames
}
eepm.spec
View file @
d37a73d7
# This spec is backported to ALTLinux p6 automatically by rpmbph script. Do not edit it.
#
Name: eepm
Version:
0.9.7
Version:
1.0.1
Release: alt0.M60P.1
Summary: Etersoft EPM package manager
...
...
@@ -22,6 +22,10 @@ Conflicts: epm
Provides: upm
%if %_vendor == "alt"
Requires: apt rpm apt-repo
%endif
%description
Etersoft EPM is the package manager for any platform
and any platform version. It provides
...
...
@@ -47,9 +51,22 @@ with various distros.
%_bindir/distr_info
%changelog
* Tue
Aug 07 2012 Vitaly Lipatov <lav@altlinux.ru> 0.9.7
-alt0.M60P.1
* Tue
Sep 18 2012 Vitaly Lipatov <lav@altlinux.ru> 1.0.1
-alt0.M60P.1
- backport to ALTLinux p6 (by rpmbph script)
* Tue Sep 18 2012 Vitaly Lipatov <lav@altlinux.ru> 1.0.1-alt1
- epm: add --force support for install
- drop extra dependencies
- introduce epm requires|deplist
- install: yum local install is obsoleted, use just yum install
* Fri Aug 17 2012 Vitaly Lipatov <lav@altlinux.ru> 1.0.0-alt1
- release 1.0
- upgrade: add support for additional options
- filelist: add error for non installed packages
- use apt-repo on ALT Linux for repo manipulation
- repolist: print url on mandriva
* Tue Aug 07 2012 Vitaly Lipatov <lav@altlinux.ru> 0.9.7-alt1
- epm: fix use epm_packages
- simulate: return 2 if have no work
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment