Compare commits

..

No commits in common. "e161cef4882fa5354712d877f2e51de0d13b10b6" and "e2041d12888a6d03736ab8a1a1810c2ba752b883" have entirely different histories.

3 changed files with 3 additions and 85 deletions

View File

@ -1,34 +0,0 @@
From 09116bb68bb76c9f6432511f5a0f054a2e3b92e0 Mon Sep 17 00:00:00 2001
From: caodongxia <315816521@qq.com>
Date: Tue, 12 Oct 2021 19:47:01 +0800
Subject: [PATCH] add -h option to scl-command
---
src/scl.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/scl.c b/src/scl.c
index df8111a..1c7854a 100644
--- a/src/scl.c
+++ b/src/scl.c
@@ -25,7 +25,7 @@ static void print_usage( const char *name ) {
fprintf(stderr, " %s load|unload [<collection>...]\n", basename(name));
fprintf(stderr, " %s list-collections\n", basename(name));
fprintf(stderr, " %s list-packages|man|register|deregister <collection>\n", basename(name));
- fprintf(stderr, " %s --help\n\n", basename(name));
+ fprintf(stderr, " %s -h|--help\n\n", basename(name));
fprintf(stderr,
"description:\n"
@@ -36,7 +36,7 @@ static void print_usage( const char *name ) {
" list-packages list packages in Software Collection\n"
" man show manual page about Software Collection\n"
" register|deregister register/deregister Software Collection\n"
- " --help show this help\n"
+ " -h|--help show this help\n"
"\nUse '-' as <command> to read the command from standard input.\n");
}
--
2.27.0

View File

@ -1,33 +0,0 @@
From 54ca3bd3293bd9815712d7d8aaf1fe45f13e5d5e Mon Sep 17 00:00:00 2001
From: Pavel Raiskup <praiskup@redhat.com>
Date: Fri, 11 Oct 2019 12:41:11 +0200
Subject: [PATCH] fix direct 'scl_source --help' output
Wrap everything into 'if then else fi' statement, so we don't actually need 'return' statement. Without this wrapping hack, we'd need either 'exit' statement (if executed by /usr/bin/scl_source) or 'return' for 'source scl_source'. For more info see #20.
---
shell/scl_source | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/shell/scl_source b/shell/scl_source
index b0036bd..294740f 100755
--- a/shell/scl_source
+++ b/shell/scl_source
@@ -9,8 +9,7 @@ Options:
if [ $# -eq 0 -o $1 = "-h" -o $1 = "--help" ]; then
echo "$_scl_source_help"
- return 0
-fi
+else # main operation mode
if [ -z "$_recursion" ]; then
@@ -73,3 +72,5 @@ if [ $_recursion == "false" ]; then
_scl_scriptlet_name=""
_recursion="false"
fi
+
+fi # main operation mode
--
2.23.0

View File

@ -1,10 +1,9 @@
%global __cmake_in_source_build 1
%global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)
%global vendor %{?_vendor:%{_vendor}}%{!?_vendor:openEuler}
Name: scl-utils
Epoch: 1
Version: 2.0.2
Release: 5
Release: 1
Summary: Utilities for alternative packaging
License: GPLv2+
URL: https://github.com/sclorg/scl-utils
@ -16,14 +15,12 @@ Buildrequires: rpm-devel
Requires: %{_bindir}/modulecmd
Patch1: 0003-Scl-utils-layout-patch-from-fedora-famillecollet.com.patch
Patch100: scl-utils-2.0.2-rhbz-1728450.patch
Patch101: fix-direct-scl_source-help-output.patch
Patch102: add-h-option-to-scl-command.patch
%description
Run-time utility for alternative packaging.
%package build
Summary: RPM build macros for alternative packaging
Requires: iso-codes %{vendor}-rpm-config
Requires: iso-codes redhat-rpm-config
%description build
Essential RPM build macros for alternative packaging.
@ -72,17 +69,5 @@ ln -s prefixes conf
%{_rpmconfigdir}/brp-scl-python-bytecompile
%changelog
* Thu Nov 17 2022 caodongxia <caodongxia@h-partners.com> - 1:2.0.2-5
- Replace oenEuler with the vendor macro
* Tue Mar 1 2022 yangping <yangping69@huawei.com> - 1:2.0.2-4
- Fix need config
* Tue Oct 12 2021 caodongxia <caodongxia@huawei.com> - 1:2.0.2-3
- add -h option to scl command
* Fri Oct 08 2021 wangyue <wangyue92@huawei.com> - 1:2.0.2-2
- fix direct scl_source --help output
* Tue Sep 7 2021 zhengyaohui <zhengyaohui1@huawei.com> - 1:2.0.2-1
* Tue Sep 7 2021 zhengyaohui <zhengyaohui1@huawei.com> - 2.0.2-1
- package init