import ksc-1.12-2.git869a25c.el9
This commit is contained in:
parent
3abc453b09
commit
9e31306ccc
2
.gitignore
vendored
2
.gitignore
vendored
@ -1 +1 @@
|
|||||||
SOURCES/ksc-d4f36f3.tar.gz
|
SOURCES/ksc-869a25c.tar.gz
|
||||||
|
@ -1 +1 @@
|
|||||||
473a8fb8d620251dbd425f61a85cedf9cf165c2a SOURCES/ksc-d4f36f3.tar.gz
|
f2b282f3126447fa8fc3a65123641aa1535513f5 SOURCES/ksc-869a25c.tar.gz
|
||||||
|
93
SOURCES/0001-manpage.patch
Normal file
93
SOURCES/0001-manpage.patch
Normal file
@ -0,0 +1,93 @@
|
|||||||
|
diff --git a/data/ksc.conf b/data/ksc.conf
|
||||||
|
index 8ee4551..c4c53fc 100644
|
||||||
|
--- a/data/ksc.conf
|
||||||
|
+++ b/data/ksc.conf
|
||||||
|
@@ -1,6 +1,12 @@
|
||||||
|
+[global]
|
||||||
|
+user=user@example.com
|
||||||
|
+partner=none
|
||||||
|
+partnergroup=none
|
||||||
|
[bugzilla]
|
||||||
|
-user=user@redhat.com
|
||||||
|
-partner=partner-name
|
||||||
|
-partnergroup=partner-group
|
||||||
|
+enable=1
|
||||||
|
server=https://bugzilla.redhat.com/xmlrpc.cgi
|
||||||
|
-api_key=api_key
|
||||||
|
+api_key=API_KEY
|
||||||
|
+[mailing_list]
|
||||||
|
+enable=0
|
||||||
|
+smtp=smtp.example.com
|
||||||
|
+to=kabi-requests@redhat.com
|
||||||
|
diff --git a/ksc.1 b/ksc.1
|
||||||
|
index 078dd83..3c3ce86 100644
|
||||||
|
--- a/ksc.1
|
||||||
|
+++ b/ksc.1
|
||||||
|
@@ -139,12 +139,18 @@ partnergroup=none
|
||||||
|
.br
|
||||||
|
[bugzilla]
|
||||||
|
.br
|
||||||
|
+enable=1
|
||||||
|
+.br
|
||||||
|
server=https://bugzilla.redhat.com/xmlrpc.cgi
|
||||||
|
.br
|
||||||
|
api_key=API_KEY
|
||||||
|
.br
|
||||||
|
[mailing_list]
|
||||||
|
.br
|
||||||
|
+enable=1
|
||||||
|
+.br
|
||||||
|
+smtp=smtp.example.com
|
||||||
|
+.br
|
||||||
|
to=kabi-requests@redhat.com
|
||||||
|
|
||||||
|
Please replace the values above by your credentials.
|
||||||
|
@@ -153,7 +159,10 @@ Mandatory fields for any submission method: user, partner, partnergroup.
|
||||||
|
.br
|
||||||
|
Mandatory fields for Bugzilla submission method: server, api_key.
|
||||||
|
.br
|
||||||
|
-Mandatory fields for mailing list submission method: to.
|
||||||
|
+Mandatory fields for mailing list submission method: to, smtp.
|
||||||
|
+
|
||||||
|
+By default, Bugzilla (mailing list) submission method is auto-enabled
|
||||||
|
+(auto-disabled) and must be opted out (in).
|
||||||
|
|
||||||
|
Note that server must be a valid XML RPC Bugzilla link, user and to fields
|
||||||
|
must be valid e-mail addresses.
|
||||||
|
diff --git a/utils.py b/utils.py
|
||||||
|
index ce1a613..8038076 100644
|
||||||
|
--- a/utils.py
|
||||||
|
+++ b/utils.py
|
||||||
|
@@ -220,6 +220,7 @@ def getconfig(path='/etc/ksc.conf', mock=False, require_partner=False, verbose=T
|
||||||
|
|
||||||
|
# To be deprecated in the future:
|
||||||
|
result['bugzilla_enable'] = True
|
||||||
|
+ result['mailing_list_enable'] = False
|
||||||
|
|
||||||
|
cat = None
|
||||||
|
for line in lines:
|
||||||
|
@@ -305,10 +306,10 @@ def getconfig(path='/etc/ksc.conf', mock=False, require_partner=False, verbose=T
|
||||||
|
raise ConfigDeprecatedValueException(path, key, result[key])
|
||||||
|
|
||||||
|
if not (result['method'] & SubmissionMethod.BUGZILLA.value):
|
||||||
|
- conf["bugzilla_enable"] = False
|
||||||
|
+ result["bugzilla_enable"] = False
|
||||||
|
|
||||||
|
if not (result['method'] & SubmissionMethod.MAILING_LIST.value):
|
||||||
|
- conf["mailing_list_enable"] = False
|
||||||
|
+ result["mailing_list_enable"] = False
|
||||||
|
|
||||||
|
return result
|
||||||
|
|
||||||
|
@@ -365,6 +366,11 @@ def sendmail(filename, arch, mock, conf, releasename, module, subcomponent,
|
||||||
|
Email ksc report.
|
||||||
|
"""
|
||||||
|
|
||||||
|
+ for field in [ "smtp", "user", "to" ]:
|
||||||
|
+ if field not in conf:
|
||||||
|
+ print(f"Could not send an email, '{field}' config field is missing.")
|
||||||
|
+ return
|
||||||
|
+
|
||||||
|
major, centos = get_major_release(releasename)
|
||||||
|
if not major:
|
||||||
|
print("Invalid releasename: Mail not sent.")
|
@ -1,13 +1,13 @@
|
|||||||
%global forgeurl https://github.com/RedHatOfficial/ksc
|
%global forgeurl https://github.com/RedHatOfficial/ksc
|
||||||
%global commitdate 20220613
|
%global commitdate 20230109
|
||||||
%global commit d4f36f3cac349feb9eb346a206f2616d05f519e8
|
%global commit 869a25c7de8ed880a72f66ae4f3e8407f1aa4114
|
||||||
%global shortcommit %(c=%{commit}; echo ${c:0:7})
|
%global shortcommit %(c=%{commit}; echo ${c:0:7})
|
||||||
|
|
||||||
%{?python_enable_dependency_generator}
|
%{?python_enable_dependency_generator}
|
||||||
%forgemeta -i
|
%forgemeta -i
|
||||||
|
|
||||||
Name: ksc
|
Name: ksc
|
||||||
Version: 1.11
|
Version: 1.12
|
||||||
Release: 2%{?dist}
|
Release: 2%{?dist}
|
||||||
Summary: Kernel source code checker
|
Summary: Kernel source code checker
|
||||||
Group: Development/Tools
|
Group: Development/Tools
|
||||||
@ -22,12 +22,14 @@ Requires: python3-requests
|
|||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
BuildRequires: python3-setuptools
|
BuildRequires: python3-setuptools
|
||||||
Source0: https://github.com/RedHatOfficial/ksc/archive/%{commit}/%{name}-%{shortcommit}.tar.gz
|
Source0: https://github.com/RedHatOfficial/ksc/archive/%{commit}/%{name}-%{shortcommit}.tar.gz
|
||||||
|
Patch0: 0001-manpage.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
A kernel module source code checker to find usage of select symbols
|
A kernel module source code checker to find usage of select symbols
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%forgesetup
|
%forgesetup
|
||||||
|
%patch0 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%py3_build
|
%py3_build
|
||||||
@ -46,6 +48,12 @@ install -D ksc.1 %{buildroot}%{_mandir}/man1/ksc.1
|
|||||||
%{python3_sitelib}/ksc-%{version}*.egg-info
|
%{python3_sitelib}/ksc-%{version}*.egg-info
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Jan 23 2023 Čestmír Kalina <ckalina@redhat.com> - 1.12-2
|
||||||
|
- Resolves: #2066231 - add manpage docs
|
||||||
|
|
||||||
|
* Mon Jan 09 2023 Čestmír Kalina <ckalina@redhat.com> - 1.12-1
|
||||||
|
- Resolves: #2066231 - update to ksc 1.12
|
||||||
|
|
||||||
* Mon Jun 13 2022 Čestmír Kalina <ckalina@redhat.com> - 1.11-2
|
* Mon Jun 13 2022 Čestmír Kalina <ckalina@redhat.com> - 1.11-2
|
||||||
- Resolves: #2066228 - Explicitly require target specification
|
- Resolves: #2066228 - Explicitly require target specification
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user