From 33f0a939621e1662e84f4ec895b3b29c84062378 Mon Sep 17 00:00:00 2001 From: dingsheng Date: Tue, 26 Nov 2024 07:13:26 +0000 Subject: [PATCH] Updated to kyclassifier 2.0 --- kyclassifier.sh | 14 ++++++++++++++ kyclassifier.spec | 13 +++++++++---- 2 files changed, 23 insertions(+), 4 deletions(-) create mode 100644 kyclassifier.sh diff --git a/kyclassifier.sh b/kyclassifier.sh new file mode 100644 index 0000000..983a532 --- /dev/null +++ b/kyclassifier.sh @@ -0,0 +1,14 @@ +#!/bin/sh +# ********************************************************************************** +# Copyright (c) KylinSoft Co., Ltd. 2024.All rights reserved. +# [kyclassifier] licensed under the Mulan PSL v2. +# You can use this software according to the terms and conditions of the Mulan PSL v2. +# You may obtain a copy of Mulan PSL v2 at: +# http://license.coscl.org.cn/MulanPSL2 +# THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR +# PURPOSE. +# See the Mulan PSL v2 for more details. +# ********************************************************************************** +cmd_exec='/usr/bin/python3 /opt/kyclassifier/main.py' +$cmd_exec $@ diff --git a/kyclassifier.spec b/kyclassifier.spec index d7a332f..c76dd87 100644 --- a/kyclassifier.spec +++ b/kyclassifier.spec @@ -1,5 +1,5 @@ Name: kyclassifier -Version: 1.0 +Version: 2.0 Release: 0 Summary: Use for analyzes layers and categories information of packages in openEuler. License: Mulan PSL v2 @@ -7,7 +7,7 @@ Source0: kyclassifier-%{version}.tar.gz BuildArch: noarch BuildRequires: python3 -Requires: python3 +Requires: python3 python3-dnf python3-hawkey python3-six python3-pycdlib %description Use for analyzes layers and categories information of packages in openEuler. @@ -20,11 +20,13 @@ Use for analyzes layers and categories information of packages in openEuler. rm -rf %{buildroot}/* mkdir -p %{buildroot}/opt/kyclassifier mv main.py %{buildroot}/opt/kyclassifier +mv src/ %{buildroot}/opt/kyclassifier +install -m 755 -D kyclassifier.sh %{buildroot}/usr/bin/kyclassifier %files %doc NOTICE LICENSES -/opt/kyclassifier/main.py -%exclude /opt/kyclassifier/__pycache__ +/opt/kyclassifier/ +/usr/bin/kyclassifier %clean rm -rf %{buildroot} @@ -32,5 +34,8 @@ rm -rf %{_builddir}/* %changelog +* Tue Nov 26 2024 Sheng Ding -2.0-0 +- RPM packages can be analyzed in iso, repo, and local environments. + * Fri Aug 09 2024 Sheng Ding -1.0-0 - Initial spec. \ No newline at end of file -- Gitee