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
bf7e4975
Commit
bf7e4975
authored
Mar 26, 2023
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
epm print: add arch
parent
678ea145
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
0 deletions
+23
-0
epm-print
bin/epm-print
+23
-0
No files found.
bin/epm-print
View file @
bf7e4975
...
...
@@ -77,6 +77,18 @@ query_package_field()
}
print_pkg_arch
()
{
case
$PMTYPE
in
*
-dpkg
)
dpkg_query_package_field
"Arch"
"
$@
"
|
sed
-e
"s|-.*||"
-e
"s|.*:||"
;;
*
-rpm
)
rpm_query_package_field
"arch"
"
$@
"
;;
esac
}
print_pkg_version
()
{
case
$PMTYPE
in
...
...
@@ -287,6 +299,7 @@ cat <<EOF
epm print version [from filename|for package] NN print only version of package name or package file
epm print release [from filename|for package] NN print only release of package name or package file
epm print version-release [from filename|for package] NN print only release-release of package name or package file
epm print arch [from filename|for package] NN print arch of package name or package file
epm print field FF for package NN print field of the package
epm print pkgname from filename NN print package name for the package file
epm print srcname from filename NN print source name for the package file
...
...
@@ -335,6 +348,16 @@ epm_print()
print_name
"
$@
"
fi
;;
"arch"
)
[
-n
"
$1
"
]
||
fatal
"Arg is missed"
if
[
-n
"
$FNFLAG
"
]
;
then
print_pkg_arch
"
$@
"
elif
[
-n
"
$PKFLAG
"
]
;
then
print_pkg_arch
"
$@
"
else
print_pkg_arch
"
$@
"
fi
;;
"version"
)
[
-n
"
$1
"
]
||
fatal
"Arg is missed"
if
[
-n
"
$FNFLAG
"
]
;
then
...
...
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