Browse code

update RELEASENOTES.md, fix .bootstrap/repositories Improvements to shell scripts try to improve versioning/release

Nat! authored on 23-05-2016 12:48:46
Showing 7 changed files
... ...
@@ -1 +1 @@
1
-gitolite.mulle-kybernetik.com:MulleFoundation
1
+#gitolite.mulle-kybernetik.com:MulleFoundation
... ...
@@ -1,6 +1,6 @@
1 1
 Pod::Spec.new do |s|
2 2
   s.name             = "MulleScion"
3
-  s.version          = '1853.2'
3
+  s.version          = '1854'
4 4
   s.summary          = "MulleScion a modern Template library for ObjC."
5 5
   s.description      = <<-DESC
6 6
                        MulleScion is indeed a modern Template library for ObjC.
... ...
@@ -1961,10 +1961,9 @@
1961 1961
 			baseConfigurationReference = 413C51611CC284CA00F62468 /* Debug.xcconfig */;
1962 1962
 			buildSettings = {
1963 1963
 				CLANG_WARN_INT_CONVERSION = YES;
1964
-				CURRENT_PROJECT_VERSION = 1853.2;
1964
+				CURRENT_PROJECT_VERSION = 1854;
1965 1965
 				DYLIB_COMPATIBILITY_VERSION = 1848.0;
1966 1966
 				DYLIB_CURRENT_VERSION = "$(CURRENT_PROJECT_VERSION)";
1967
-				GCC_ENABLE_OBJC_EXCEPTIONS = YES;
1968 1967
 				GCC_OPTIMIZATION_LEVEL = 0;
1969 1968
 				GCC_PREPROCESSOR_DEFINITIONS = (
1970 1969
 					"DEBUG=1",
... ...
@@ -1983,11 +1982,9 @@
1983 1982
 				OTHER_CFLAGS = (
1984 1983
 					"-DPROJECT_VERSION=${CURRENT_PROJECT_VERSION}",
1985 1984
 					"$(inherited)",
1986
-					"-H",
1987 1985
 				);
1988 1986
 				OTHER_LDFLAGS = "-ObjC";
1989
-				SKIP_INSTALL = YES;
1990
-				WARNING_LDFLAGS = "--trace";
1987
+				SKIP_INSTALL = NO;
1991 1988
 			};
1992 1989
 			name = Debug;
1993 1990
 		};
... ...
@@ -1996,10 +1993,9 @@
1996 1993
 			baseConfigurationReference = 413C516B1CC284CA00F62468 /* Release.xcconfig */;
1997 1994
 			buildSettings = {
1998 1995
 				CLANG_WARN_INT_CONVERSION = YES;
1999
-				CURRENT_PROJECT_VERSION = 1853.2;
1996
+				CURRENT_PROJECT_VERSION = 1854;
2000 1997
 				DYLIB_COMPATIBILITY_VERSION = 1848.0;
2001 1998
 				DYLIB_CURRENT_VERSION = "$(CURRENT_PROJECT_VERSION)";
2002
-				GCC_ENABLE_OBJC_EXCEPTIONS = YES;
2003 1999
 				GCC_PREPROCESSOR_DEFINITIONS = (
2004 2000
 					NS_BLOCK_ASSERTIONS,
2005 2001
 					NDEBUG,
... ...
@@ -2016,11 +2012,9 @@
2016 2012
 				OTHER_CFLAGS = (
2017 2013
 					"-DPROJECT_VERSION=${CURRENT_PROJECT_VERSION}",
2018 2014
 					"$(inherited)",
2019
-					"-H",
2020 2015
 				);
2021 2016
 				OTHER_LDFLAGS = "-ObjC";
2022
-				SKIP_INSTALL = YES;
2023
-				WARNING_LDFLAGS = "--trace";
2017
+				SKIP_INSTALL = NO;
2024 2018
 			};
2025 2019
 			name = Release;
2026 2020
 		};
... ...
@@ -2068,10 +2062,9 @@
2068 2062
 			baseConfigurationReference = 413C516B1CC284CA00F62468 /* Release.xcconfig */;
2069 2063
 			buildSettings = {
2070 2064
 				CLANG_WARN_INT_CONVERSION = YES;
2071
-				CURRENT_PROJECT_VERSION = 1853.2;
2065
+				CURRENT_PROJECT_VERSION = 1854;
2072 2066
 				DYLIB_COMPATIBILITY_VERSION = 1848.0;
2073 2067
 				DYLIB_CURRENT_VERSION = "$(CURRENT_PROJECT_VERSION)";
2074
-				GCC_ENABLE_OBJC_EXCEPTIONS = YES;
2075 2068
 				GCC_PREPROCESSOR_DEFINITIONS = (
2076 2069
 					NS_BLOCK_ASSERTIONS,
2077 2070
 					NDEBUG,
... ...
@@ -2089,11 +2082,9 @@
2089 2082
 				OTHER_CFLAGS = (
2090 2083
 					"-DPROJECT_VERSION=${CURRENT_PROJECT_VERSION}",
2091 2084
 					"$(inherited)",
2092
-					"-H",
2093 2085
 				);
2094 2086
 				OTHER_LDFLAGS = "-ObjC";
2095
-				SKIP_INSTALL = YES;
2096
-				WARNING_LDFLAGS = "--trace";
2087
+				SKIP_INSTALL = NO;
2097 2088
 			};
2098 2089
 			name = Profile;
2099 2090
 		};
... ...
@@ -1,29 +1,44 @@
1
-1853.2
1
+## 1854
2 2
 
3
-Experimental Travis CI integration on Github.
4
-Improvements in project structure due to better `mulle-bootstrap`
3
+* Added a podspec fix from Hannes Tribus `<hons82@...com>`
5 4
 
6
-1853.1
5
+* Fixed an obvious KVC bug, in a code path that was probably never used
6
+* Some support for MulleFoundation merged in
7
+* Added local variable __FOUNDATION__
8
+* Use a fork of google-toolbox for html escaping/unescaping
9
+* Use mulle-configuration for compilation
10
+* --version prints version and exits
7 11
 
8
-Fixed a bug, where `endfilter` did not respect the options setting of the
12
+## 1853.2
13
+
14
+* Experimental Travis CI integration on Github.
15
+* Improvements in project structure due to better `mulle-bootstrap`
16
+
17
+## 1853.1
18
+
19
+* Fixed a bug, where `endfilter` did not respect the options setting of the
9 20
 returning filter. This could create havoc on plaintext, when your filter
10 21
 just specified (output).
11 22
 
12
-1853
23
+## 1853
13 24
 
14
-Made mulle-scion brew compatible. You can now brew it. As I wanted to use
25
+* Made mulle-scion brew compatible. You can now brew it. As I wanted to use
15 26
 mulle-scion to produce brew formulae, I needed some options in the way
16 27
 mulle-scion is called.
17 28
 
18
-It is now possible to do this:
29
+** It is now possible to do this:
19 30
 
31
+```
20 32
 echo '--- {{ VALUE }} ---' | mulle-scion - keyvalue - VALUE="xxx"
33
+```
21 34
 
22 35
 which produces predicatably
23 36
 
37
+```
24 38
 --- xxx ---
39
+```
25 40
 
26
-Templates can be passed in via stdin and the replacement values can be given
41
+* Templates can be passed in via stdin and the replacement values can be given
27 42
 as key=value arguments. This makes mulle-scion even more convenient to use
28 43
 in shell scripts.
29 44
 
... ...
@@ -31,14 +46,14 @@ in shell scripts.
31 46
 brew install https://www.mulle-kybernetik.com/software/formulae/mulle-scion.rb
32 47
 ~~~
33 48
 
34
-There are now "hidden" environment variables WWW_ROOT, WWW_PORT, WWW_PLIST for
49
+* There are now "hidden" environment variables WWW_ROOT, WWW_PORT, WWW_PLIST for
35 50
 the webserver.
36 51
 
37
-The way libraries are created and headers are written has been standardized and
52
+* The way libraries are created and headers are written has been standardized and
38 53
 improved. There is some support for a future "mulle-bootstrap", in case you are
39 54
 wondering what the .bootstrap folder does.
40 55
 
41
-1852
56
+## 1852
42 57
 
43 58
 ### API change
44 59
 
... ...
@@ -58,7 +73,7 @@ harmless in my opinion, but results may vary.
58 73
 
59 74
 
60 75
 
61
-1851.0
76
+## 1851.0
62 77
 
63 78
 *** BIG CHANGE!!! FILTER REDESIGNED ***
64 79
 
... ...
@@ -82,22 +97,22 @@ To keep in sync with the archive version, the version nr. has been bumped to
82 97
 1851.
83 98
 
84 99
 
85
-Improved the dependencyTable generation, by ignoring syntax errors.
100
+* Improved the dependencyTable generation, by ignoring syntax errors.
86 101
 
87
-The documentation is now in markdown format. With some hacking effort
102
+* The documentation is now in markdown format. With some hacking effort
88 103
 the builtin webserver can now show the "Results" much nicer.
89 104
 
90
-Stole a CSS to make it look more nicey, nicey.
105
+* Stole a CSS to make it look more nicey, nicey.
91 106
 
92
-Improved the LICENSE detail.
107
+* Improved the LICENSE detail.
93 108
 
94
-Made it more possible to call a macro from a macro, which failed in some cases.
109
+* Made it more possible to call a macro from a macro, which failed in some cases.
95 110
 
96
-There is now a hidden convert feature on includes, which allows to preprocess
111
+* There is now a hidden convert feature on includes, which allows to preprocess
97 112
 the data. convert > parse > print > filter
98 113
 
99 114
 
100
-1848.11
115
+## 1848.11
101 116
 
102 117
 *** This can break archived templates on iOS, regenerate them ***
103 118
 
... ...
@@ -105,6 +120,7 @@ the data. convert > parse > print > filter
105 120
 I found out, that when I use NSKeyedArchiver it's actually slower than parsing
106 121
 plain text and uses more space - even compressed.
107 122
 
123
+```
108 124
 Compile plaintext * 100
109 125
 -rw-r--r--  1 nat  _lpoperator  198016 Oct  9 17:00 big.scion
110 126
 
... ...
@@ -117,17 +133,18 @@ real	0m8.680s
117 133
 Compile keyed * 100
118 134
 -rw-r--r--  1 nat  wheel  750347 Oct  9 17:25 /tmp/keyed.scionz
119 135
 real	0m25.497s
136
+```
120 137
 
121
-If you are on iOS it's most likely better to not use archives and caching!
138
+* If you are on iOS it's most likely better to not use archives and caching!
122 139
 
123
-Fix erroneous trace output, which was always happening.
140
+* Fix erroneous trace output, which was always happening.
124 141
 
125
-Fix bug, where "for i in nil" would iterate once
142
+* Fix bug, where "for i in nil" would iterate once
126 143
 
127
-Fix bug, where MulleScionNull was passed as invocation argument
144
+* Fix bug, where MulleScionNull was passed as invocation argument
128 145
 
129 146
 
130
-1848.10
147
+## 1848.10
131 148
 
132 149
 *** This can break currently working templates, that contain unnoticed
133 150
     syntax errors! ***
... ...
@@ -146,12 +163,12 @@ iOS
146 163
 functions
147 164
 
148 165
 
149
-1848.9
166
+## 1848.9
150 167
 
151 168
 * added a podspec
152 169
 
153 170
 
154
-1848.8
171
+## 1848.8
155 172
 
156 173
 * allow # comments within {% %}
157 174
 
... ...
@@ -173,7 +190,7 @@ it "felt right"
173 190
 * updated documentation a bit regarding multi-line commands
174 191
 
175 192
 
176
-v1848.7
193
+## v1848.7
177 194
 
178 195
 * outsourced NSObject+MulleGraphviz because I need it in other code
179 196
 too and the dependency on MulleScion was annoying.
... ...
@@ -181,13 +198,13 @@ too and the dependency on MulleScion was annoying.
181 198
 * fixed some bad code in commandline tool, that reads the property list
182 199
 
183 200
 
184
-v1848.6
201
+## v1848.6
185 202
 
186 203
 * add __ARGV__ parsage to mulle-scion. Now you can use mulle-scion as an awk
187 204
 replacement in other shell scripts, if you so desire.
188 205
 
189 206
 
190
-v1848.5
207
+## v1848.5
191 208
 
192 209
 * bunch of fixes. Added an example how to write a non-plist datasource, in this
193 210
 case using CoreData.
... ...
@@ -196,7 +213,7 @@ case using CoreData.
196 213
 script (experimental)
197 214
 
198 215
 
199
-v1848.4
216
+## v1848.4
200 217
 
201 218
 * renamed to MulleScion, because now it's more than just a template engine, it's
202 219
 also somewhat useful as a little standalone Obj-C interpreter. Also
... ...
@@ -222,7 +239,7 @@ github: https://github.com/mulle-nat/MulleScionTemplates/
222 239
 </blockquote>
223 240
 
224 241
 
225
-v1848.3  !!**massive changes**!!
242
+## v1848.3  !!**massive changes**!!
226 243
 
227 244
 * your compiled scionz files are incompatible now. Throw them away
228 245
 and rebuild your caches
... ...
@@ -240,7 +257,7 @@ a simple shellscript that runs the tests
240 257
 * lots of smaller fixes, whose content one might glean from the git comments
241 258
 
242 259
 
243
-v1848.2
260
+## v1848.2
244 261
 
245 262
 * your scionz files are incompatible now. Throw them away
246 263
 and rebuild the caches
... ...
@@ -1,32 +1,35 @@
1
-#! /bin/sh
1
+#! /bin/sh -x
2 2
 #
3 3
 # Generate a formula for mulle-scion stand alone
4 4
 #
5 5
 PROJECT=MulleScion
6 6
 TARGET=mulle-scion
7
+
7 8
 HOMEPAGE="https://www.mulle-kybernetik.com/software/git/${PROJECT}"
8
-DESC="creates text from templates and a data-source using Objective-C"
9
+DESC="Templating Engine in Objective-C"
10
+
9 11
 VERSION="$1"
10
-shift
11
-ARCHIVEURL="$1"
12
-shift
12
+[ $# -eq 0 ] || shift
13
+ARCHIVEURL="${1:-https://www.mulle-kybernetik.com/software/git/${PROJECT}/tarball/$VERSION}"
14
+[ $# -eq 0 ] || shift
15
+CURLOPTIONS="-s -L"  # -k broken on OS X
13 16
 
14 17
 usage()
15 18
 {
16
-   echo "generate-brew-formuala.sh VERSION ARCHIVEURL" >&2
19
+   echo "generate-brew-formula.sh VERSION ARCHIVEURL" >&2
17 20
    exit 1
18 21
 }
19 22
 
20 23
 
21
-[ "$VERSION" = "" ] && usage
22
-[ "$ARCHIVEURL" = "" ] && usage
24
+[ ! -z "$VERSION"     ] || usage
25
+[ ! -z "$ARCHIVEURL"  ] || usage
23 26
 
24 27
 
25 28
 TMPARCHIVE="/tmp/${PROJECT}-${VERSION}-archive"
26 29
 
27
-if [ ! -f  "${TMPARCHIVE}" ]
30
+if [ ! -f "${TMPARCHIVE}" ]
28 31
 then
29
-   curl -s -L -o "${TMPARCHIVE}" "${ARCHIVEURL}"
32
+   curl ${CURLOPTIONS} -o "${TMPARCHIVE}" "${ARCHIVEURL}"
30 33
    if [ $? -ne 0 -o ! -f "${TMPARCHIVE}" ]
31 34
    then
32 35
       echo "Download failed" >&2
... ...
@@ -39,7 +42,7 @@ fi
39 42
 #
40 43
 # anything less than 17 KB is wrong
41 44
 #
42
-size=`du -k "${TMPARCHIVE}" | awk '{ print $ 1}'`
45
+size="`du -k "${TMPARCHIVE}" | awk '{ print $ 1}'`"
43 46
 if [ $size -lt 17 ]
44 47
 then
45 48
    echo "Archive truncated or missing" >&2
... ...
@@ -48,7 +51,7 @@ then
48 51
    exit 1
49 52
 fi
50 53
 
51
-HASH=`shasum -p -a 256 "${TMPARCHIVE}" | awk '{ print $1 }'`
54
+HASH="`shasum -p -a 256 "${TMPARCHIVE}" | awk '{ print $1 }'`"
52 55
 
53 56
 cat <<EOF
54 57
 class ${PROJECT} < Formula
55 58
new file mode 100755
... ...
@@ -0,0 +1,59 @@
1
+#! /bin/sh
2
+
3
+
4
+get_version()
5
+{
6
+   if [ -x "./build/Products/Debug/mulle-scion" ]
7
+   then
8
+     ./build/Products/Debug/mulle-scion --version
9
+   fi
10
+}
11
+
12
+
13
+PROJECT="mulle-scion"
14
+TAG="${1:-`get_version`}"
15
+
16
+[ -z "${TAG}" ] && exit 1
17
+
18
+
19
+
20
+git_must_be_clean()
21
+{
22
+   local name
23
+   local clean
24
+
25
+   name="${1:-${PWD}}"
26
+
27
+   if [ ! -d .git ]
28
+   then
29
+      echo "\"${name}\" is not a git repository" >&2
30
+      exit 1
31
+   fi
32
+
33
+   clean=`git status -s`
34
+   if [ "${clean}" != "" ]
35
+   then
36
+      echo "repository \"${name}\" is tainted" >&2
37
+      exit 1
38
+   fi
39
+}
40
+
41
+
42
+set -e
43
+
44
+git_must_be_clean
45
+git push public master
46
+
47
+# seperate step, as it's tedious to remove tag when
48
+# previous push fails
49
+
50
+git tag "${TAG}"
51
+git push public master --tags
52
+
53
+./generate-brew-formula.sh "${VERSION}" > "../homebrew-software/${PROJECT}.rb"
54
+(
55
+	cd ../homebrew-software ; \
56
+ 	git commit -m "${TAG} release of ${PROJECT}" "${PROJECT}.rb" ; \
57
+ 	git push origin master
58
+)
59
+
... ...
@@ -421,24 +421,72 @@ static int   _archive_main( int argc, const char * argv[], int keyed)
421 421
 }
422 422
 
423 423
 
424
+
425
+/*
426
+ *
427
+ */
428
+#ifndef DONT_HAVE_WEBSERVER
429
+
430
+ static char    *default_options[] =
431
+{
432
+   "document_root",   "/tmp/MulleScionDox",
433
+   "listening_ports", "127.0.0.1:18048",
434
+   "num_threads", "1",
435
+   "index_files", "index.scion,index.html,index.htm,index.cgi,index.shtml,index.php,index.lp",
436
+   NULL
437
+};
438
+
439
+
440
+static int   main_www( int argc, const char * argv[])
441
+{
442
+   id         plist;
443
+   char       *s;
444
+   NSString   *path;
445
+
446
+   loadBundles();
447
+
448
+   // hack to get something else going
449
+   s = getenv( "MulleScionServerRoot");
450
+   if( s)
451
+      default_options[ 1] = s;
452
+
453
+   s = getenv( "MulleScionServerPort");
454
+   if( s)
455
+      default_options[ 3] = s;
456
+
457
+   path = @"/tmp/MulleScionDox/properties.plist";
458
+   s = getenv( "MulleScionServerPlist");
459
+   if( s)
460
+      path = [NSString stringWithCString:s];
461
+
462
+   plist = acquirePropertyListOrDataSourceFromBundle( path);
463
+   if( ! plist)
464
+      plist = [NSDictionary dictionary];
465
+
466
+   mulle_mongoose_main( plist, default_options);
467
+   return( 0);
468
+}
469
+#endif
470
+
471
+
424 472
 static int   _main(int argc, const char * argv[])
425 473
 {
426 474
    NSDictionary         *info;
427 475
    NSFileHandle         *stream;
428 476
    MulleScionTemplate   *template;
429
-
477
+   
430 478
    info = getInfoFromArguments();
431 479
    if( ! info)
432 480
       return( -3);
433
-
481
+   
434 482
    template = acquireTemplateFromPath( [info objectForKey:@"MulleScionRootTemplate"]);
435 483
    if( ! template)
436 484
       return( -1);
437
-
485
+   
438 486
    stream = outputStreamWithInfo( info);
439 487
    if( ! stream)
440 488
       return( -2);
441
-
489
+   
442 490
    [template writeToOutput:stream
443 491
                 dataSource:[info objectForKey:@"dataSource"]
444 492
             localVariables:localVariablesFromInfo( info)];
... ...
@@ -450,38 +498,42 @@ int main( int argc, const char * argv[])
450 498
 {
451 499
    NSAutoreleasePool   *pool;
452 500
    int                 rval;
453
-
501
+   
454 502
    if( argc > 1)
455 503
    {
504
+      if( ! strcmp( argv[ 1], "--version"))
505
+      {
506
+         printf( "%s\n", MulleScionFrameworkVersion);
507
+         return( 0);
508
+      }
509
+
510
+      if( ! strcmp( argv[ 1], "-h") || ! strcmp( argv[ 1], "--help"))
511
+      {
512
+         usage();
513
+         return( 0);
514
+      }
515
+
456 516
 #ifndef DONT_HAVE_WEBSERVER
457 517
       if( ! strcmp( argv[ 1], "-w"))
458 518
       {
459
-         int   main_www( int argc, const char * argv[]);
460
-
461 519
          return( main_www( argc, argv));
462 520
       }
463 521
 #endif
464
-
522
+      
465 523
       if( ! strcmp( argv[ 1], "-z"))
466 524
          return( _archive_main( argc, argv, NO));
467
-
525
+      
468 526
       if( ! strcmp( argv[ 1], "-Z"))
469 527
          return( _archive_main( argc, argv, YES));
470
-
471
-      if( ! strcmp( argv[ 1], "-h") || ! strcmp( argv[ 1], "--help"))
472
-      {
473
-         usage();
474
-         return( 0);
475
-      }
476 528
    }
477
-
529
+   
478 530
    pool = [NSAutoreleasePool new];
479
-NS_DURING
531
+   NS_DURING
480 532
    rval = _main( argc, argv);
481
-NS_HANDLER
533
+   NS_HANDLER
482 534
    NSLog( @"%@", localException);
483 535
    rval = -4;
484
-NS_ENDHANDLER
536
+   NS_ENDHANDLER
485 537
 #if defined( DEBUG) || defined( PROFILE)
486 538
    [pool release];
487 539
 #endif
... ...
@@ -492,52 +544,3 @@ NS_ENDHANDLER
492 544
    return( rval);
493 545
 }
494 546
 
495
-
496
-/*
497
- *
498
- */
499
-#ifndef DONT_HAVE_WEBSERVER
500
-
501
- static char    *default_options[] =
502
-{
503
-   "document_root",   "/tmp/MulleScionDox",
504
-   "listening_ports", "127.0.0.1:18048",
505
-   "num_threads", "1",
506
-   "index_files", "index.scion,index.html,index.htm,index.cgi,index.shtml,index.php,index.lp",
507
-   NULL
508
-};
509
-
510
-
511
-int   main_www( int argc, const char * argv[])
512
-{
513
-   id         plist;
514
-   char       *s;
515
-   NSString   *path;
516
-
517
-   loadBundles();
518
-
519
-   // hack to get something else going
520
-   s = getenv( "MulleScionServerRoot");
521
-   if( s)
522
-      default_options[ 1] = s;
523
-
524
-   s = getenv( "MulleScionServerPort");
525
-   if( s)
526
-      default_options[ 3] = s;
527
-
528
-   path = @"/tmp/MulleScionDox/properties.plist";
529
-   s = getenv( "MulleScionServerPlist");
530
-   if( s)
531
-      path = [NSString stringWithCString:s];
532
-
533
-   plist = acquirePropertyListOrDataSourceFromBundle( path);
534
-   if( ! plist)
535
-      plist = [NSDictionary dictionary];
536
-
537
-   mulle_mongoose_main( plist, default_options);
538
-   return( 0);
539
-}
540
-#endif
541
-
542
-
543
-