Commit 2fec847a authored by Vitaly Lipatov's avatar Vitaly Lipatov

commit packed 3.18.3

parent 89b1ce1a
...@@ -452,21 +452,6 @@ assure_exists() ...@@ -452,21 +452,6 @@ assure_exists()
( direct='' epm_assure "$1" $package $3 ) || fatal "Can't assure in '$1' command from $package$textpackage package" ( direct='' epm_assure "$1" $package $3 ) || fatal "Can't assure in '$1' command from $package$textpackage package"
} }
__set_EGET()
{
# use internal eget only if exists
if [ -s $SHAREDIR/tools_eget ] ; then
export EGET="$SHAREDIR/tools_eget"
return
fi
fatal "Internal error: missed tools_eget"
# FIXME: we need disable output here, eget can be used for get output
assure_exists eget eget 3.3 >/dev/null
# use external command, not the function
export EGET="$(which eget)" || fatal "Missed command eget from installed package eget"
}
disabled_eget() disabled_eget()
{ {
local EGET local EGET
...@@ -3757,9 +3742,8 @@ __epm_play_run() ...@@ -3757,9 +3742,8 @@ __epm_play_run()
local script="$psdir/$1.sh" local script="$psdir/$1.sh"
shift shift
# allow use EGET in the scripts # TODO: use epm print info instead of one?
__set_EGET # we will have DISTRVENDOR there
# also we will have DISTRVENDOR there
export PATH=$PROGDIR:$PATH export PATH=$PROGDIR:$PATH
set_sudo set_sudo
...@@ -8490,6 +8474,38 @@ done ...@@ -8490,6 +8474,38 @@ done
} }
# File bin/epm-tool:
epm_tool()
{
local WHAT="$1"
shift
case "$WHAT" in
"")
fatal "Use epm tool help to get help."
;;
"-h"|"--help"|"help")
cat <<EOF
Examples:
epm tool eget
epm tool estrlist
EOF
;;
"eget")
eget "$@"
;;
"estrlist")
estrlist "$@"
;;
*)
fatal "Unknown command $ epm tool $WHAT. Use epm print help for get help."
;;
esac
}
# File bin/epm-update: # File bin/epm-update:
...@@ -10628,7 +10644,7 @@ Examples: ...@@ -10628,7 +10644,7 @@ Examples:
print_version() print_version()
{ {
echo "EPM package manager version 3.18.2 https://wiki.etersoft.ru/Epm" echo "EPM package manager version 3.18.3 https://wiki.etersoft.ru/Epm"
echo "Running on $($DISTRVENDOR -e) ('$PMTYPE' package manager uses '$PKGFORMAT' package format)" echo "Running on $($DISTRVENDOR -e) ('$PMTYPE' package manager uses '$PKGFORMAT' package format)"
echo "Copyright (c) Etersoft 2012-2021" echo "Copyright (c) Etersoft 2012-2021"
echo "This program may be freely redistributed under the terms of the GNU AGPLv3." echo "This program may be freely redistributed under the terms of the GNU AGPLv3."
...@@ -10638,7 +10654,7 @@ print_version() ...@@ -10638,7 +10654,7 @@ print_version()
Usage="Usage: epm [options] <command> [package name(s), package files]..." Usage="Usage: epm [options] <command> [package name(s), package files]..."
Descr="epm - EPM package manager" Descr="epm - EPM package manager"
EPMVERSION=3.18.2 EPMVERSION=3.18.3
verbose=$EPM_VERBOSE verbose=$EPM_VERBOSE
quiet= quiet=
nodeps= nodeps=
...@@ -10914,6 +10930,10 @@ check_command() ...@@ -10914,6 +10930,10 @@ check_command()
epm_cmd=print epm_cmd=print
direct_args=1 direct_args=1
;; ;;
tool) # HELPCMD: run embedded tool (f.i., epm tool eget)
epm_cmd=tool
direct_args=1
;;
repack) # HELPCMD: repack rpm to local compatibility repack) # HELPCMD: repack rpm to local compatibility
epm_cmd=repack epm_cmd=repack
;; ;;
......
...@@ -443,21 +443,6 @@ assure_exists() ...@@ -443,21 +443,6 @@ assure_exists()
( direct='' epm_assure "$1" $package $3 ) || fatal "Can't assure in '$1' command from $package$textpackage package" ( direct='' epm_assure "$1" $package $3 ) || fatal "Can't assure in '$1' command from $package$textpackage package"
} }
__set_EGET()
{
# use internal eget only if exists
if [ -s $SHAREDIR/tools_eget ] ; then
export EGET="$SHAREDIR/tools_eget"
return
fi
fatal "Internal error: missed tools_eget"
# FIXME: we need disable output here, eget can be used for get output
assure_exists eget eget 3.3 >/dev/null
# use external command, not the function
export EGET="$(which eget)" || fatal "Missed command eget from installed package eget"
}
disabled_eget() disabled_eget()
{ {
local EGET local EGET
...@@ -3152,7 +3137,7 @@ print_version() ...@@ -3152,7 +3137,7 @@ print_version()
local on_text="(host system)" local on_text="(host system)"
local virt="$($DISTRVENDOR -i)" local virt="$($DISTRVENDOR -i)"
[ "$virt" = "(unknown)" ] || [ "$virt" = "(host system)" ] || on_text="(under $virt)" [ "$virt" = "(unknown)" ] || [ "$virt" = "(host system)" ] || on_text="(under $virt)"
echo "Service manager version 3.18.2 https://wiki.etersoft.ru/Epm" echo "Service manager version 3.18.3 https://wiki.etersoft.ru/Epm"
echo "Running on $($DISTRVENDOR -e) $on_text with $SERVICETYPE" echo "Running on $($DISTRVENDOR -e) $on_text with $SERVICETYPE"
echo "Copyright (c) Etersoft 2012-2021" echo "Copyright (c) Etersoft 2012-2021"
echo "This program may be freely redistributed under the terms of the GNU AGPLv3." echo "This program may be freely redistributed under the terms of the GNU AGPLv3."
......
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