Ben Copsey

[super init] => [self init]

Tweak autoversioning script to work with v1.1.x scheme
... ... @@ -23,7 +23,7 @@
// Automatically set on build
NSString *ASIHTTPRequestVersion = @" 2010-03-25";
NSString *ASIHTTPRequestVersion = @"v1.6.1-2 2010-03-25";
NSString* const NetworkRequestErrorDomain = @"ASIHTTPRequestErrorDomain";
... ... @@ -221,7 +221,7 @@ static BOOL isiPhoneOS2;
- (id)initWithURL:(NSURL *)newURL
{
self = [super init];
self = [self init];
[self setRequestMethod:@"GET"];
[self setShouldAttemptPersistentConnection:YES];
... ...
#!/usr/bin/env ruby
require 'find'
newversion = `/opt/local/bin/git describe --tags`.match(/(v([0-9]+)\.([0-9]+)-([0-9]+))/).to_s.gsub(/[0-9]+$/){|commit| (commit.to_i + 1).to_s}+Time.now.strftime(" %Y-%m-%d")
newversion = `/opt/local/bin/git describe --tags`.match(/(v([0-9]+)(\.([0-9]+)){1,}-([0-9]+))/).to_s.gsub(/[0-9]+$/){|commit| (commit.to_i + 1).to_s}+Time.now.strftime(" %Y-%m-%d")
buffer = File.new('Classes/ASIHTTPRequest.m','r').read
if !buffer.match(/#{Regexp.quote(newversion)}/)
buffer = buffer.sub(/(NSString \*ASIHTTPRequestVersion = @\")(.*)(";)/,'\1'+newversion+'\3');
... ...