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
165fc06f
Commit
165fc06f
authored
May 10, 2025
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
epm downgrade: add archive YYYY-MM-DD support before packages
parent
414ad9d6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
epm-downgrade
bin/epm-downgrade
+14
-0
No files found.
bin/epm-downgrade
View file @
165fc06f
...
@@ -21,6 +21,7 @@ load_helper epm-check_updated_repo
...
@@ -21,6 +21,7 @@ load_helper epm-check_updated_repo
__epm_add_alt_apt_downgrade_preferences
()
__epm_add_alt_apt_downgrade_preferences
()
{
{
set_sudo
[
-r
/etc/apt/preferences
]
&&
fatal
"/etc/apt/preferences already exists"
[
-r
/etc/apt/preferences
]
&&
fatal
"/etc/apt/preferences already exists"
cat
<<
EOF
| sudocmd tee /etc/apt/preferences
cat
<<
EOF
| sudocmd tee /etc/apt/preferences
# classic repo
# classic repo
...
@@ -48,6 +49,7 @@ EOF
...
@@ -48,6 +49,7 @@ EOF
# See https://wiki.debian.org/ru/AptPreferences
# See https://wiki.debian.org/ru/AptPreferences
__epm_add_deb_apt_downgrade_preferences
()
__epm_add_deb_apt_downgrade_preferences
()
{
{
set_sudo
[
-r
/etc/apt/preferences
]
&&
fatal
"/etc/apt/preferences already exists"
[
-r
/etc/apt/preferences
]
&&
fatal
"/etc/apt/preferences already exists"
info
"Running with /etc/apt/preferences:"
info
"Running with /etc/apt/preferences:"
cat
<<
EOF
| sudorun tee /etc/apt/preferences
cat
<<
EOF
| sudorun tee /etc/apt/preferences
...
@@ -72,6 +74,7 @@ __epm_remove_apt_downgrade_preferences()
...
@@ -72,6 +74,7 @@ __epm_remove_apt_downgrade_preferences()
epm_downgrade
()
epm_downgrade
()
{
{
arg
=
"
$1
"
local
CMD
local
CMD
# it is useful for first time running
# it is useful for first time running
...
@@ -88,6 +91,17 @@ epm_downgrade()
...
@@ -88,6 +91,17 @@ epm_downgrade()
case
$BASEDISTRNAME
in
case
$BASEDISTRNAME
in
alt
)
alt
)
if
[
"
$arg
"
=
"archive"
]
;
then
__epm_add_alt_apt_downgrade_preferences
||
return
docmd epm repo save
docmd epm repo
set
archive
"
$2
"
load_helper epm-Upgrade
shift
2
epm_Upgrade
"
$2
"
docmd epm repo restore
__epm_remove_apt_downgrade_preferences
return
fi
# pass pkg_filenames too
# pass pkg_filenames too
if
[
-n
"
$pkg_names
"
]
;
then
if
[
-n
"
$pkg_names
"
]
;
then
__epm_add_alt_apt_downgrade_preferences
||
return
__epm_add_alt_apt_downgrade_preferences
||
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