Release version v1.6.1

This commit is contained in:
Qiu Yuzhou
2017-09-16 17:20:43 +08:00
5 changed files with 9 additions and 16 deletions

View File

@ -1,6 +1,6 @@
# ShadowsocksX-NG
Current version is 1.6.0
Current version is 1.6.1
[![Build Status](https://travis-ci.org/shadowsocks/ShadowsocksX-NG.svg?branch=develop)](https://travis-ci.org/shadowsocks/ShadowsocksX-NG)
@ -63,8 +63,6 @@ so that you could configure your apps to use the SOCKS5 proxy manually.
## Contributing
[![gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/ShadowsocksX-NG/Lobby)
Contributions must be available on a separately named branch based on the latest version of the main branch `develop`.
ref: [GitFlow](http://nvie.com/posts/a-successful-git-branching-model/)

View File

@ -57,7 +57,7 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserNotificationCenterDele
if attrs[FileAttributeKey.ownerAccountName] as! String != NSUserName() {
//try fileMgr.setAttributes([FileAttributeKey.ownerAccountName: NSUserName()], ofItemAtPath: dirPath)
let bashFilePath = Bundle.main.path(forResource: "fix_dir_owner.sh", ofType: nil)!
let script = "do shell script \"bash \(bashFilePath) \(NSUserName()) \" with administrator privileges"
let script = "do shell script \"bash \\\"(bashFilePath)\\\" \(NSUserName()) \" with administrator privileges"
if let appleScript = NSAppleScript(source: script) {
var err: NSDictionary? = nil
appleScript.executeAndReturnError(&err)

View File

@ -17,7 +17,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.6.0</string>
<string>1.6.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>

View File

@ -51,12 +51,12 @@ GCDWebServer *webServer =nil;
NSString *helperPath = [NSString stringWithFormat:@"%@/%@", [[NSBundle mainBundle] resourcePath], @"install_helper.sh"];
NSLog(@"run install script: %@", helperPath);
NSDictionary *error;
NSString *script = [NSString stringWithFormat:@"do shell script \"bash %@\" with administrator privileges", helperPath];
NSString *script = [NSString stringWithFormat:@"do shell script \"/bin/bash \\\"%@\\\"\" with administrator privileges", helperPath];
NSAppleScript *appleScript = [[NSAppleScript new] initWithSource:script];
if ([appleScript executeAndReturnError:&error]) {
NSLog(@"installation success");
} else {
NSLog(@"installation failure");
NSLog(@"installation failure: %@", error);
}
}
}

View File

@ -19,7 +19,7 @@
[super windowDidLoad];
// Implement this method to handle any initialization after your window controller's window has been loaded from its nib file.
[self setQRCode:self.qrCode withOverlayText:@"Shadowsocks-NG SIP002"];
[self setQRCode:self.qrCode withOverlayText:@"SIP002"];
}
- (void)setQRCode:(NSString*) qrCode withOverlayText: (NSString*) text {
@ -35,14 +35,9 @@
};
NSMutableAttributedString* attrsText = [[NSMutableAttributedString alloc] initWithString: text
attributes: attrs];
[attrsText setAttributes:@{
NSForegroundColorAttributeName: [NSColor darkGrayColor],
NSBackgroundColorAttributeName: [NSColor whiteColor],
NSFontAttributeName: [NSFont fontWithName:@"Helvetica" size:(CGFloat)16],
} range: NSMakeRange(0, 14)];
[image lockFocus];
[attrsText drawAtPoint: NSMakePoint(45, 8)];
[attrsText drawAtPoint: NSMakePoint(100, 5)];
[image unlockFocus];
}
self.imageView.image = image;
@ -108,9 +103,9 @@
- (void)flagsChanged:(NSEvent *)event {
NSUInteger modifiers = event.modifierFlags & NSDeviceIndependentModifierFlagsMask;
if (modifiers & NSAlternateKeyMask) {
[self setQRCode:self.legacyQRCode withOverlayText:@"Shadowsocks-NG Legacy"];
[self setQRCode:self.legacyQRCode withOverlayText:@"Legacy"];
} else {
[self setQRCode:self.qrCode withOverlayText:@"Shadowsocks-NG SIP002"];
[self setQRCode:self.qrCode withOverlayText:@"SIP002"];
}
}