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
Nurlan
eepm
Commits
54396ffe
Commit
54396ffe
authored
Aug 18, 2022
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "fix quotes in format strings"
This reverts commit
c32b74d3
.
parent
bcce1fdf
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
14 deletions
+14
-14
epm-packages
bin/epm-packages
+6
-6
epm-print
bin/epm-print
+2
-2
epm-query
bin/epm-query
+6
-6
No files found.
bin/epm-packages
View file @
54396ffe
...
...
@@ -26,11 +26,11 @@ case $PMTYPE in
*
-rpm
)
# FIXME: space with quotes problems, use point instead
warmup_rpmbase
docmd rpm
-qa
--queryformat
'%{size}@%{name}-%{version}-%{release}\\n'
$pkg_filenames
|
sed
-e
"s|@| |g"
|
sort
-n
-k1
docmd rpm
-qa
--queryformat
"%{size}@%{name}-%{version}-%{release}
\n
"
$pkg_filenames
|
sed
-e
"s|@| |g"
|
sort
-n
-k1
;;
*
-dpkg
)
warmup_dpkgbase
docmd dpkg-query
-W
--showformat
=
'\${Installed-Size}@\${Package}-\${Version}:\${Architecture}\\n'
$pkg_filenames
|
sed
-e
"s|@| |g"
|
sort
-n
-k1
docmd dpkg-query
-W
--showformat
=
"
\$
{Installed-Size}@
\$
{Package}-
\$
{Version}:
\$
{Architecture}
\n
"
$pkg_filenames
|
sed
-e
"s|@| |g"
|
sort
-n
-k1
;;
*
)
fatal
"Sorted package list function is not implemented for
$PMTYPE
"
...
...
@@ -61,17 +61,17 @@ case $PMTYPE in
warmup_dpkgbase
# FIXME: strong equal
#CMD="dpkg -l $pkg_filenames"
CMD
=
"dpkg-query -W --showformat=
\$
{db:Status-Abbrev}
\$
{Package}-
\$
{Version}:
\$
{Architecture}
\
\
n
$pkg_filenames
"
CMD
=
"dpkg-query -W --showformat=
\$
{db:Status-Abbrev}
\$
{Package}-
\$
{Version}:
\$
{Architecture}
\n
$pkg_filenames
"
# TODO: ${Architecture}
[
-n
"
$short
"
]
&&
CMD
=
"dpkg-query -W --showformat=
\$
{db:Status-Abbrev}
\$
{Package}
\
\
n
$pkg_filenames
"
showcmd
"
$CMD
"
[
-n
"
$short
"
]
&&
CMD
=
"dpkg-query -W --showformat=
\$
{db:Status-Abbrev}
\$
{Package}
\n
$pkg_filenames
"
showcmd
$CMD
$CMD
|
grep
"^i"
|
sed
-e
"s|.* ||g"
| __fo_pfn
return
;;
*
-rpm
)
warmup_rpmbase
# FIXME: strong equal
CMD
=
"rpm -qa
$pkg_filenames
"
[
-n
"
$short
"
]
&&
CMD
=
"rpm -qa --queryformat
'%{name}
\\
n'
$pkg_filenames
"
[
-n
"
$short
"
]
&&
CMD
=
"rpm -qa --queryformat
%{name}
\n
$pkg_filenames
"
docmd
$CMD
return
;;
packagekit
)
...
...
bin/epm-print
View file @
54396ffe
...
...
@@ -44,10 +44,10 @@ dpkg_query_package_format_field()
local
field
=
"
$1
"
shift
if
[
-f
"
$1
"
]
;
then
a
=
dpkg-deb
--show
--showformat
=
"
$field
\
\\
n
"
"
$@
"
a
=
dpkg-deb
--show
--showformat
=
"
$field
\n
"
"
$@
"
else
#a= dpkg -s "$1" | grep "^$field: " | sed -e "s|^$field: ||"
a
=
dpkg-query
-W
--showformat
=
"
$field
\
\\
n
"
--
"
$@
"
a
=
dpkg-query
-W
--showformat
=
"
$field
\n
"
--
"
$@
"
fi
}
...
...
bin/epm-query
View file @
54396ffe
...
...
@@ -190,8 +190,8 @@ __epm_query_file()
[
-n
"
$short
"
]
&&
CMD
=
"rpm -qp --queryformat %{name}
\n
"
;;
*
-dpkg
)
CMD
=
"dpkg-deb --show --showformat=
'
\$
{Package}-
\$
{Version}
\\
n'
"
[
-n
"
$short
"
]
&&
CMD
=
"dpkg-query --show --showformat=
'
\$
{Package}
\\
n'
"
CMD
=
"dpkg-deb --show --showformat=
\$
{Package}-
\$
{Version}
\n
"
[
-n
"
$short
"
]
&&
CMD
=
"dpkg-query --show --showformat=
\$
{Package}
\n
"
;;
*
)
fatal
"Do not know command for query file package"
...
...
@@ -223,8 +223,8 @@ __epm_query_name()
;;
*
-dpkg
)
#docmd dpkg -l $@ | grep "^ii"
#CMD="dpkg-query -W --showformat=\${Package}-\${Version}\
\\
n"
docmd dpkg-query
-W
"--showformat=
'
\$
{Package}-
\$
{Version}
\\
n'
"
--
$@
||
return
#CMD="dpkg-query -W --showformat=\${Package}-\${Version}\n"
docmd dpkg-query
-W
"--showformat=
\$
{Package}-
\$
{Version}
\n
"
--
$@
||
return
__epm_query_dpkg_check
$@
||
return
return
;;
...
...
@@ -275,8 +275,8 @@ __epm_query_shortname()
return
;;
*
-dpkg
)
#CMD="dpkg-query -W --showformat=\${Package}\
\\
n"
docmd dpkg-query
-W
--showformat
=
'\${Package}\\n'
--
$@
||
return
#CMD="dpkg-query -W --showformat=\${Package}\n"
docmd dpkg-query
-W
"--showformat=
\$
{Package}
\n
"
--
$@
||
return
__epm_query_dpkg_check
$@
||
return
return
;;
...
...
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