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
Vladislav
eepm
Commits
c8bae544
Commit
c8bae544
authored
Oct 29, 2013
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Plain Diff
backported to p7 as 1.4.5-alt0.M70P.1 (with rpmbph script)
parents
efc1a899
0944371e
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
64 additions
and
16 deletions
+64
-16
epm
bin/epm
+5
-1
epm-autoremove
bin/epm-autoremove
+20
-0
epm-filelist
bin/epm-filelist
+3
-4
epm-provides
bin/epm-provides
+1
-1
epm-query_package
bin/epm-query_package
+2
-1
epm-requires
bin/epm-requires
+1
-1
epm-search
bin/epm-search
+2
-1
epm-sh-functions
bin/epm-sh-functions
+20
-5
eepm.spec
eepm.spec
+10
-2
No files found.
bin/epm
View file @
c8bae544
...
...
@@ -303,14 +303,18 @@ check_filenames()
quoted_args
=
"
$quoted_args
\"
$opt
\"
"
}
FLAGENDOPTS
=
for
opt
in
"
$@
"
;
do
[
"
$opt
"
=
"--"
]
&&
FLAGENDOPTS
=
1
&&
continue
if
[
-z
"
$FLAGENDOPTS
"
]
;
then
check_command
$opt
&&
continue
check_option
$opt
&&
continue
fi
check_filenames
$opt
done
# if input is not console, get pkg from it too
if
!
tty
-s
;
then
if
!
inputisatty
;
then
for
opt
in
$(
cat
)
;
do
check_filenames
$opt
done
...
...
bin/epm-autoremove
View file @
c8bae544
...
...
@@ -17,12 +17,32 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
__epm_autoremove_altrpm
()
{
local
pkg
local
flag
=
load_helper epm-packages
echo
echo
"Just remove all non -devel libs packages not need by anything"
for
pkg
in
$(
short
=
1
pkg_filenames
=
epm_packages |
grep
--
"^lib"
|
grep
-v
--
"-devel$"
|
grep
-v
--
^libreoffice
)
;
do
sudocmd rpm
-v
-e
$pkg
&&
flag
=
1
done
# call again for next cycle until all libs will removed
[
-n
"
$flag
"
]
&&
__epm_autoremove_altrpm
return
0
}
epm_autoremove
()
{
case
$PMTYPE
in
apt-rpm
)
assure_exists remove-old-kernels
# ALT Linux only
__epm_autoremove_altrpm
# ALT Linux only
sudocmd remove-old-kernels
;;
apt-dpkg
)
...
...
bin/epm-filelist
View file @
c8bae544
...
...
@@ -78,8 +78,7 @@ __epm_filelist_file()
;;
esac
# TODO: add less
docmd
$CMD
$@
docmd
$CMD
$@
| less
}
__epm_filelist_name
()
...
...
@@ -108,7 +107,7 @@ __epm_filelist_name()
CMD
=
"conary query --ls"
;;
pacman
)
docmd pacman
-Ql
$pkg_names
|
sed
-e
"s|.* ||g"
docmd pacman
-Ql
$pkg_names
|
sed
-e
"s|.* ||g"
| less
return
;;
emerge
)
...
...
@@ -117,7 +116,7 @@ __epm_filelist_name()
;;
slackpkg
)
is_installed
$pkg_names
||
fatal
"Query filelist for non installed packages does not realized"
docmd
awk
'BEGIN{desk=1}{if(/^FILE LIST:$/){desk=0} else if (desk==0) {print}}'
/var/log/packages/
${
pkg_filenames
}*
docmd
awk
'BEGIN{desk=1}{if(/^FILE LIST:$/){desk=0} else if (desk==0) {print}}'
/var/log/packages/
${
pkg_filenames
}*
| less
return
;;
*
)
...
...
bin/epm-provides
View file @
c8bae544
...
...
@@ -25,7 +25,7 @@ epm_provides_files()
case
$(
get_package_type
$pkg_files
)
in
rpm
)
docmd
"rpm -q --provides -p"
docmd
rpm
-q
--provides
-p
$pkg_files
;;
deb
)
# FIXME: will we provide ourself?
...
...
bin/epm-query_package
View file @
c8bae544
...
...
@@ -24,7 +24,8 @@ epm_query_package()
{
[
-n
"
$pkg_filenames
"
]
||
fatal
"Please, use search with some argument or run epmqa for get all packages."
# FIXME: do it better
local
MGS
=
$(
eval
__epm_search_make_grep
$quoted_args
)
local
MGS
MGS
=
$(
eval
__epm_search_make_grep
$quoted_args
)
EXTRA_SHOWDOCMD
=
$MGS
eval
"pkg_filenames= epm_packages
\"
$(
eval
get_firstarg
$quoted_args
)
\"
$MGS
"
}
bin/epm-requires
View file @
c8bae544
...
...
@@ -25,7 +25,7 @@ epm_requires_files()
case
$(
get_package_type
$pkg_files
)
in
rpm
)
docmd
"rpm -q --requires -p"
docmd
rpm
-q
--requires
-p
$pkg_files
;;
deb
)
a
=
docmd dpkg
-I
$pkg_files
|
grep
"^ *Depends:"
|
sed
"s|^ *Depends:||g"
...
...
bin/epm-search
View file @
c8bae544
...
...
@@ -131,7 +131,8 @@ epm_search()
{
[
-n
"
$pkg_filenames
"
]
||
fatal
"Please, use search with some argument"
# FIXME: do it better
local
MGS
=
$(
eval
__epm_search_make_grep
$quoted_args
)
local
MGS
MGS
=
$(
eval
__epm_search_make_grep
$quoted_args
)
EXTRA_SHOWDOCMD
=
"
$MGS
"
eval
"__epm_search_output
\"
$(
eval
get_firstarg
$quoted_args
)
\"
$MGS
"
}
bin/epm-sh-functions
View file @
c8bae544
...
...
@@ -18,18 +18,33 @@
#
# copied from /etc/init.d/outformat (ALT Linux)
inputisatty
()
{
# check stdin
tty
-s
}
isatty
()
{
# Set a sane TERM required for tput
[
-n
"
$TERM
"
]
||
TERM
=
dumb
export
TERM
# check stdout
test
-t
1
}
isatty2
()
{
# check stderr
test
-t
2
}
check_tty
()
{
isatty
||
return
isatty2
||
return
# Set a sane TERM required for tput
[
-n
"
$TERM
"
]
||
TERM
=
dumb
export
TERM
which tput
>
/dev/null 2>/dev/null
||
return
# FreeBSD does not support tput -S
echo
| tput
-S
>
/dev/null 2>/dev/null
||
return
...
...
@@ -230,7 +245,7 @@ set_eatmydata()
# use if possible
which eatmydata
>
/dev/null 2>/dev/null
||
return
SUDO
=
"
$SUDO
eatmydata"
tty
-s
&&
echo
"Uwaga! eatmydata is installed, we will use it for disable all sync operations."
>
&2
isatty
&&
echo
"Uwaga! eatmydata is installed, we will use it for disable all sync operations."
>
&2
return
0
}
...
...
eepm.spec
View file @
c8bae544
# This spec is backported to ALTLinux p7 automatically by rpmbph script. Do not edit it.
#
Name: eepm
Version: 1.4.
4
Version: 1.4.
5
Release: alt0.M70P.1
Summary: Etersoft EPM package manager
...
...
@@ -63,9 +63,17 @@ chmod a+x %buildroot%_datadir/%name/{serv-,epm-}*
%_sysconfdir/bash_completion.d/cerv
%changelog
* Tue Oct 2
2 2013 Vitaly Lipatov <lav@altlinux.ru> 1.4.4
-alt0.M70P.1
* Tue Oct 2
9 2013 Vitaly Lipatov <lav@altlinux.ru> 1.4.5
-alt0.M70P.1
- backport to ALTLinux p7 (by rpmbph script)
* Tue Oct 29 2013 Vitaly Lipatov <lav@altlinux.ru> 1.4.5-alt1
- epm: check for -- after options
- fix bashisms
- epm provides/requires: fix for rpm files
- separate check input and output
- epm-filelist: add less
- realize autoremove orphaned packages (unused libs*)
* Tue Oct 22 2013 Vitaly Lipatov <lav@altlinux.ru> 1.4.4-alt1
- epm: get package names from stdin if it is pipe
- fix stderr issues
...
...
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