[packages/adapter: 4/631] version 0.3+ - removed buggy descriptions formatting (maybe later I will do it correct) - fixed bug
glen
glen at pld-linux.org
Mon Sep 12 19:34:48 CEST 2016
commit 309775e2f77cd2dac81782da127230f36eb7f182
Author: kura <kura at pld-linux.org>
Date: Tue Nov 23 15:10:44 1999 +0000
version 0.3+
- removed buggy descriptions formatting (maybe later I will do it correct)
- fixed bug in CVS keywords substitution
Changed files:
adapter.awk -> 1.4
adapter.awk | 34 ++--------------------------------
1 file changed, 2 insertions(+), 32 deletions(-)
---
diff --git a/adapter.awk b/adapter.awk
index d150da5..d4e08cc 100644
--- a/adapter.awk
+++ b/adapter.awk
@@ -1,19 +1,18 @@
#!/bin/awk -f
#
-# This is adapter v0.3. Adapter adapts .spec files for PLD.
+# This is adapter v0.3+. Adapter adapts .spec files for PLD.
# Copyright (C) 1999 Micha� Kuratczyk <kura at pld.org.pl>
BEGIN {
preamble = 1;
bof = 1; # Beggining of file
boc = 2; # Beggining of %changelog
- tw = 77; # Descriptions width
}
# There should be a comment with CVS keywords on the first line of file.
bof == 1 {
if (!/# \$Revision:/)
- print "# $Revision$, $Date$";
+ print "# $" "Revision:$, " "$" "Date:$";
bof = 0;
}
@@ -27,35 +26,6 @@ bof == 1 {
print "%define\t\t_mandir\t\t%{_prefix}/man\n";
x11 == 2;
}
-
- # Collect whole text of description
- if (description == 1 && !/^%[a-z]+/ && !/%description/) {
- description_text = description_text $0 " ";
- noprint = 1;
- }
-
- # Formt description to the length of tw (default == 77)
- if (/^%[a-z]+/ && !/%description/) {
- n = split(description_text, dt, / /);
- for (i = 1; i <= n; i++) {
- if (length(line) + length(dt[i]) + 1 < tw) {
- line = line dt[i] " ";
- } else {
- print line;
- line = "";
- i--;
- }
- }
-
- print line "\n";
- line = "";
- delete dt;
- description_text = "";
-
- description = 0;
- } else {
- description = 1;
- }
}
# %prep section:
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/adapter.git/commitdiff/6ca0126d4d0c8c79feb7db10b0a0fade0f3b8885
More information about the pld-cvs-commit
mailing list