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
c0efdeec
Commit
c0efdeec
authored
Feb 28, 2023
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add BASEDISTRNAME and use it for alt based systems
parent
8c038f47
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
58 additions
and
54 deletions
+58
-54
epm-addrepo
bin/epm-addrepo
+4
-4
epm-autoremove
bin/epm-autoremove
+2
-2
epm-checksystem
bin/epm-checksystem
+2
-2
epm-commentrepo
bin/epm-commentrepo
+2
-2
epm-dedup
bin/epm-dedup
+2
-2
epm-download
bin/epm-download
+2
-2
epm-install
bin/epm-install
+5
-5
epm-kernel_update
bin/epm-kernel_update
+2
-2
epm-mark
bin/epm-mark
+14
-14
epm-release_downgrade
bin/epm-release_downgrade
+2
-2
epm-release_upgrade
bin/epm-release_upgrade
+2
-2
epm-remove
bin/epm-remove
+1
-1
epm-remove_old_kernels
bin/epm-remove_old_kernels
+5
-2
epm-removerepo
bin/epm-removerepo
+2
-2
epm-repofix
bin/epm-repofix
+2
-2
epm-sh-functions
bin/epm-sh-functions
+1
-0
epm-sh-install
bin/epm-sh-install
+1
-1
epm-upgrade
bin/epm-upgrade
+1
-1
serv-cat
bin/serv-cat
+2
-2
serv-exists
bin/serv-exists
+2
-2
serv-log
bin/serv-log
+2
-2
No files found.
bin/epm-addrepo
View file @
c0efdeec
...
...
@@ -195,8 +195,8 @@ __epm_addkey_deb()
epm_addkey
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__epm_addkey_altlinux
"
$@
"
return
;;
...
...
@@ -265,8 +265,8 @@ epm_addrepo()
{
local
repo
=
"
$*
"
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
# Note! Don't use quotes here
__epm_addrepo_altlinux
$repo
return
...
...
bin/epm-autoremove
View file @
c0efdeec
...
...
@@ -232,8 +232,8 @@ EOF
epm_autoremove
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
if
[
"
$1
"
=
"-h"
]
||
[
"
$1
"
=
"--help"
]
||
[
"
$1
"
=
"help"
]
;
then
epm_autoremove_print_help
return
0
...
...
bin/epm-checksystem
View file @
c0efdeec
...
...
@@ -53,8 +53,8 @@ case $PMTYPE in
;;
esac
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
epm_checksystem_
$DISTRNAME
;;
*
)
...
...
bin/epm-commentrepo
View file @
c0efdeec
...
...
@@ -90,8 +90,8 @@ __epm_commentrepo_alt()
epm_commentrepo
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__epm_commentrepo_alt
"
$@
"
return
;;
...
...
bin/epm-dedup
View file @
c0efdeec
...
...
@@ -49,8 +49,8 @@ try_fix_apt_rpm_dupls()
epm_dedup
()
{
case
"
$DISTRNAME
"
in
ALTLinux|ALTServer
)
case
"
$
BASE
DISTRNAME
"
in
"alt"
)
assure_exists /usr/share/apt/scripts/dedup.lua apt-scripts
if
[
-z
"
$direct
"
]
&&
[
-f
/usr/share/apt/scripts/dedup.lua
]
;
then
info
"Check for duplicates via apt-get dedup from apt-scripts (also you can use internal EPM dedup implementation with --direct option)"
...
...
bin/epm-download
View file @
c0efdeec
...
...
@@ -190,8 +190,8 @@ epm_download()
{
local
CMD
case
$DISTRNAME
-
$PMTYPE
in
ALTLinux-apt-rpm|ALTServer-apt-rpm
)
case
"
$BASEDISTRNAME
"
in
"alt"
)
__epm_download_alt
$*
return
;;
...
...
bin/epm-install
View file @
c0efdeec
...
...
@@ -273,8 +273,8 @@ __epm_check_if_rpm_already_installed()
__handle_direct_install
()
{
case
"
$DISTRNAME
"
in
ALTLinux|ALTServer
)
case
"
$
BASE
DISTRNAME
"
in
"alt"
)
load_helper epm-download
local
pkg url
for
pkg
in
$pkg_names
;
do
...
...
@@ -311,8 +311,8 @@ epm_install_files()
# TODO: check read permissions
# sudo test -r FILE
# do not fallback to install_names if we have no permissions
case
"
$DISTRNAME
"
in
ALTLinux|ALTServer
)
case
"
$
BASE
DISTRNAME
"
in
"alt"
)
# do not use low-level for install by file path (f.i. epm install /usr/bin/git)
if
__epm_if_command_path
$files
;
then
...
...
@@ -611,7 +611,7 @@ epm_print_install_names_command()
epm_install
()
{
if
[
"
$
DISTRNAME
"
=
"ALTLinux"
]
||
[
"
$DISTRNAME
"
=
"ALTServer
"
]
;
then
if
[
"
$
BASEDISTRNAME
"
=
"alt
"
]
;
then
if
tasknumber
"
$pkg_names
"
>
/dev/null
;
then
assure_exists apt-repo
# TODO: add --auto support
...
...
bin/epm-kernel_update
View file @
c0efdeec
...
...
@@ -26,8 +26,8 @@ epm_kernel_update()
info
"Updating system kernel to the latest version..."
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
load_helper epm-query_package
if
!
__epm_query_package kernel-image
>
/dev/null
;
then
info
"No installed kernel packages, skipping update"
...
...
bin/epm-mark
View file @
c0efdeec
...
...
@@ -81,8 +81,8 @@ __dnf_assure_versionlock()
epm_mark_hold
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__alt_mark_hold
"
$@
"
exit
;;
...
...
@@ -116,8 +116,8 @@ esac
epm_mark_unhold
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__alt_mark_unhold
"
$@
"
exit
;;
...
...
@@ -151,8 +151,8 @@ esac
epm_mark_showhold
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__alt_mark_showhold
"
$@
"
exit
;;
...
...
@@ -186,8 +186,8 @@ esac
epm_mark_auto
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
sudocmd apt-mark auto
"
$@
"
exit
;;
...
...
@@ -217,8 +217,8 @@ esac
epm_mark_manual
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
sudocmd apt-mark manual
"
$@
"
exit
;;
...
...
@@ -248,8 +248,8 @@ esac
epm_mark_showauto
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
sudocmd apt-mark showauto
"
$@
"
exit
;;
...
...
@@ -272,8 +272,8 @@ esac
epm_mark_showmanual
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
sudocmd apt-mark showmanual
"
$@
"
exit
;;
...
...
bin/epm-release_downgrade
View file @
c0efdeec
...
...
@@ -60,8 +60,8 @@ epm_release_downgrade()
# TODO: it is possible eatmydata does not do his work
export
EPMNOEATMYDATA
=
1
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__epm_ru_update
||
fatal
# try to detect current release by repo
...
...
bin/epm-release_upgrade
View file @
c0efdeec
...
...
@@ -447,8 +447,8 @@ epm_release_upgrade()
# TODO: it is possible eatmydata does not do his work
export
EPMNOEATMYDATA
=
1
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__epm_ru_update
||
fatal
# TODO: remove this hack (or move it to distro_info)
...
...
bin/epm-remove
View file @
c0efdeec
...
...
@@ -294,7 +294,7 @@ epm_remove()
return
fi
if
[
"
$
DISTRNAME
"
=
"ALTLinux"
]
||
[
"
$DISTRNAME
"
=
"ALTServer
"
]
;
then
if
[
"
$
BASEDISTRNAME
"
=
"alt
"
]
;
then
load_helper epm-sh-altlinux
if
tasknumber
"
$pkg_names
"
>
/dev/null
;
then
assure_exists apt-repo
...
...
bin/epm-remove_old_kernels
View file @
c0efdeec
...
...
@@ -24,8 +24,8 @@ epm_remove_old_kernels()
warmup_bases
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
load_helper epm-query_package
if
!
__epm_query_package kernel-image
>
/dev/null
;
then
info
"No installed kernel packages, skipping cleaning"
...
...
@@ -44,6 +44,9 @@ epm_remove_old_kernels()
fi
return
;;
esac
case
$DISTRNAME
in
Ubuntu
)
load_helper epm-query_package
if
!
__epm_query_package linux-image
>
/dev/null
;
then
...
...
bin/epm-removerepo
View file @
c0efdeec
...
...
@@ -93,8 +93,8 @@ __epm_removerepo_alt()
epm_removerepo
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
__epm_removerepo_alt
"
$@
"
return
;;
...
...
bin/epm-repofix
View file @
c0efdeec
...
...
@@ -234,8 +234,8 @@ __fix_repo_to_basealt()
epm_repofix
()
{
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
assure_exists apt-repo
[
-n
"
$quiet
"
]
||
docmd apt-repo list
assure_root
...
...
bin/epm-sh-functions
View file @
c0efdeec
...
...
@@ -619,6 +619,7 @@ set_distro_info()
DISTRARCH
=
$(
$DISTRVENDOR
--distro-arch
)
fi
DISTRCONTROL
=
"
$(
$DISTRVENDOR
-y
)
"
[
-n
"
$BASEDISTRNAME
"
]
||
BASEDISTRNAME
=
$(
$DISTRVENDOR
-s
)
# TODO: improve BIGTMPDIR conception
# https://bugzilla.mozilla.org/show_bug.cgi?id=69938
...
...
bin/epm-sh-install
View file @
c0efdeec
...
...
@@ -112,7 +112,7 @@ __epm_check_vendor()
[
-n
"
$scripts$noscripts
"
]
&&
return
# only ALT
[
"
$
DISTRNAME
"
=
"ALTLinux"
]
||
[
"
$DISTRNAME
"
=
"ALTServer
"
]
||
return
[
"
$
BASEDISTRNAME
"
=
"alt
"
]
||
return
local
i
for
i
in
$*
;
do
...
...
bin/epm-upgrade
View file @
c0efdeec
...
...
@@ -29,7 +29,7 @@ epm_upgrade()
warmup_bases
if
[
"
$
DISTRNAME
"
=
"ALTLinux"
]
||
[
"
$DISTRNAME
"
=
"ALTServer
"
]
;
then
if
[
"
$
BASEDISTRNAME
"
=
"alt
"
]
;
then
load_helper epm-sh-altlinux
if
tasknumber
"
$@
"
>
/dev/null
;
then
load_helper epm-addrepo
...
...
bin/serv-cat
View file @
c0efdeec
...
...
@@ -27,8 +27,8 @@ serv_cat()
docmd systemctl
cat
"
$SERVICE
"
"
$@
"
;;
*
)
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
local
INITFILE
=
/etc/init.d/
$SERVICE
[
-r
"
$INITFILE
"
]
||
fatal
"Can't find init file
$INITFILE
"
docmd
cat
$INITFILE
...
...
bin/serv-exists
View file @
c0efdeec
...
...
@@ -28,8 +28,8 @@ serv_exists()
docmd systemctl
cat
"
$SERVICE
"
"
$@
"
>
/dev/null 2>/dev/null
;;
*
)
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
local
INITFILE
=
/etc/init.d/
$SERVICE
[
-r
"
$INITFILE
"
]
||
return
return
;;
...
...
bin/serv-log
View file @
c0efdeec
...
...
@@ -52,8 +52,8 @@ serv_log()
sudocmd journalctl
-b
-u
"
$SERVICE
"
"
$@
"
;;
*
)
case
$DISTRNAME
in
ALTLinux|ALTServer
)
case
$
BASE
DISTRNAME
in
"alt"
)
FF
=
""
;
[
"
$1
"
=
"-f"
]
&&
FF
=
"-f"
__serv_log_altlinux
"
$SERVICE
"
$FF
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