copy from unzip rpm diractory and system file to compatility diractory

This commit is contained in:
xuezhixin 2024-11-07 19:55:20 +08:00
parent 32aa59bb80
commit c7bb32e381
2 changed files with 44 additions and 2 deletions

View File

@ -0,0 +1,39 @@
From e4bfbc6e0d5ecf6768a24e8ae173c0bd39b667b1 Mon Sep 17 00:00:00 2001
From: xuezhixin <xuezhixin@uniontech.com>
Date: Mon, 13 Nov 2023 14:11:10 +0800
Subject: [PATCH] =?UTF-8?q?=E5=A4=8D=E5=88=B6=E8=A7=A3=E5=8E=8B=E7=9A=84rp?=
=?UTF-8?q?m=E6=96=87=E4=BB=B6=E5=88=B0=E5=92=8C=E7=B3=BB=E7=BB=9F?=
=?UTF-8?q?=E6=96=87=E4=BB=B6=E5=88=B0=E5=AF=B9=E6=AF=94=E7=9B=AE=E5=BD=95?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
sysmig_agent/Abisystmcompchk.py | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/sysmig_agent/Abisystmcompchk.py b/sysmig_agent/Abisystmcompchk.py
index d14581b..cf34c87 100644
--- a/sysmig_agent/Abisystmcompchk.py
+++ b/sysmig_agent/Abisystmcompchk.py
@@ -628,3 +628,17 @@ def get_cur_sys_info_list():
fpbsi.write('13|1|' + str(sum_num) + '\n')
return list_info
+
+
+def mycopyfile(srcfile, dstfile, logger):
+ if not os.path.exists(srcfile):
+ logger.info("Please check!!!! src file not exit:" + srcfile)
+ return False
+ else:
+ fpath,fname=os.path.split(dstfile)
+ if not os.path.exists(fpath):
+ os.makedirs(fpath)
+ copyfile(srcfile,dstfile)
+
+ return dstfile
+
--
2.20.1

View File

@ -1,6 +1,6 @@
Name: migration-tools
Version: 1.0.2
Release: 76
Release: 77
License: MulanPSL-2.0
Summary: A tool to help users migrate the Centos system to the UOS system and openEuler system
Source0: %{name}-%{version}.tar.gz
@ -83,7 +83,7 @@ Patch73: 0073-get-os-version-and-os-id.patch
Patch74: 0074-detection-basic-system-information.patch
Patch75: 0075-detection-basic-information-and-format-abi-compatibility-information-to-report.patch
Patch76: 0076-detection-storage-interface.patch
Patch77: 0077-copy-from-unzip-rpm-diractory-and-system-file-to-compatility-diractory.patch
BuildArch: noarch
@ -183,6 +183,9 @@ rm -rf /usr/bin/migration-tools
%endif
%changelog
* Tue Nov 5 2024 xuezhixin <xuezhixin@uniontech.com> - 1.0.2-77
- 0077-copy-from-unzip-rpm-diractory-and-system-file-to-compatility-diractory.patch
* Tue Nov 5 2024 xuezhixin <xuezhixin@uniontech.com> - 1.0.2-76
- 0076-detection-storage-interface.patch