[packages/adapter: 376/631] - BR, R: shortcuts for faster typing

glen glen at pld-linux.org
Mon Sep 12 20:05:58 CEST 2016


commit 23ddcab10b241dbe5ff84bd65f5919be8bbee8fb
Author: Elan Ruusamäe <glen at pld-linux.org>
Date:   Fri Aug 31 20:28:46 2007 +0000

    - BR, R: shortcuts for faster typing
    
    Changed files:
        adapter.awk -> 1.362

 adapter.awk | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
---
diff --git a/adapter.awk b/adapter.awk
index a6ad078..80433e1 100644
--- a/adapter.awk
+++ b/adapter.awk
@@ -29,7 +29,7 @@ BEGIN {
 	RPM_SECTIONS = "package|build|changelog|clean|description|install|post|posttrans|postun|pre|prep|pretrans|preun|triggerin|triggerpostun|triggerun|verifyscript|check"
 	SECTIONS = "^%(" RPM_SECTIONS ")"
 
-	PREAMBLE_TAGS = "(Summary|Name|Version|Release|Epoch|License|Group|URL|BuildArch|BuildRoot|Obsoletes|Conflicts|Provides|ExclusiveArch|ExcludeArch|Pre[Rr]eq|(Build)?Requires)"
+	PREAMBLE_TAGS = "(R|BR|Summary|Name|Version|Release|Epoch|License|Group|URL|BuildArch|BuildRoot|Obsoletes|Conflicts|Provides|ExclusiveArch|ExcludeArch|Pre[Rr]eq|(Build)?Requires)"
 
 	preamble = 1	# Is it part of preamble? Default - yes
 	boc = 4			# Beginning of %changelog
@@ -962,6 +962,12 @@ ENVIRON["SKIP_SORTBR"] != 1 && preamble == 1 && $0 ~ PREAMBLE_TAGS, $0 ~ PREAMBL
 	if ($1 ~ /Pre[Rr]eq:/) {
 		sub(/Pre[Rr]eq:/, "Requires:", $1);
 	}
+	if ($1 == "BR:" ) {
+		$1 = "BuildRequires:"
+	}
+	if ($1 == "R:" ) {
+		$1 = "Requires:"
+	}
 	format_preamble()
 #	kill_preamble_macros(); # breaks tabbing
 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/adapter.git/commitdiff/6ca0126d4d0c8c79feb7db10b0a0fade0f3b8885



More information about the pld-cvs-commit mailing list