Skip to content

Commit

Permalink
Updated for swift 4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
OrkhanAlikhanov committed Sep 24, 2017

Unverified

This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
1 parent f9f6630 commit 423e4bc
Showing 6 changed files with 32 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .swift-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.1
4.0
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -8,21 +8,21 @@ matrix:
script: swift test

- os: osx
osx_image: xcode8.3
osx_image: xcode9
dist: trusty
sudo: required
env: ACTION=test PLATFORM=Mac DESTINATION='platform=OS X'
script: set -o pipefail && xcodebuild -scheme SocketSwift -destination "$DESTINATION" $ACTION | xcpretty

- os: osx
osx_image: xcode8.3
osx_image: xcode9
dist: trusty
sudo: required
env: ACTION=test PLATFORM=iOS DESTINATION='platform=iOS Simulator,name=iPhone 6S'
script: set -o pipefail && xcodebuild -scheme SocketSwift -destination "$DESTINATION" $ACTION | xcpretty

- os: osx
osx_image: xcode8.3
osx_image: xcode9
dist: trusty
sudo: required
env: ACTION=test PLATFORM=tvOS DESTINATION='platform=tvOS Simulator,name=Apple TV 1080p'
2 changes: 1 addition & 1 deletion Socket.swift.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'Socket.swift'
s.version = '1.3'
s.version = '2.0.0'
s.summary = 'A POSIX socket wrapper written in swift.'
s.homepage = 'https://github.com/BiAtoms/Socket.swift'
s.license = { :type => 'MIT', :file => 'LICENSE' }
29 changes: 23 additions & 6 deletions SocketSwift.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
@@ -172,18 +172,19 @@
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0830;
LastUpgradeCheck = 0830;
LastUpgradeCheck = 0900;
ORGANIZATIONNAME = BiAtoms;
TargetAttributes = {
9DF8834A1F0CCAB60060C11F = {
CreatedOnToolsVersion = 8.3.2;
DevelopmentTeam = SLC8XA65WS;
LastSwiftMigration = 0830;
LastSwiftMigration = 0900;
ProvisioningStyle = Automatic;
};
9DF883531F0CCAB60060C11F = {
CreatedOnToolsVersion = 8.3.2;
DevelopmentTeam = SLC8XA65WS;
LastSwiftMigration = 0900;
ProvisioningStyle = Automatic;
};
};
@@ -267,15 +268,21 @@
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
@@ -324,15 +331,21 @@
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
@@ -383,7 +396,8 @@
SKIP_INSTALL = YES;
SUPPORTED_PLATFORMS = "iphonesimulator iphoneos appletvos macosx appletvsimulator";
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.0;
VALID_ARCHS = "arm64 armv7 armv7s i386 x86_64";
};
name = Debug;
@@ -406,7 +420,8 @@
SDKROOT = "";
SKIP_INSTALL = YES;
SUPPORTED_PLATFORMS = "iphonesimulator iphoneos appletvos macosx appletvsimulator";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.0;
VALID_ARCHS = "arm64 armv7 armv7s i386 x86_64";
};
name = Release;
@@ -420,7 +435,8 @@
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks @executable_path/../Frameworks @loader_path/../Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.biatoms.SocketSwiftTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.0;
};
name = Debug;
};
@@ -433,7 +449,8 @@
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks @executable_path/../Frameworks @loader_path/../Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.biatoms.SocketSwiftTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_VERSION = 3.0;
SWIFT_SWIFT3_OBJC_INFERENCE = Default;
SWIFT_VERSION = 4.0;
};
name = Release;
};
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0830"
LastUpgradeVersion = "0900"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
@@ -26,6 +26,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
@@ -55,6 +56,7 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
language = ""
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
2 changes: 1 addition & 1 deletion Tests/SocketSwiftTests/SocketSwiftTests.swift
Original file line number Diff line number Diff line change
@@ -35,7 +35,7 @@ class SocketSwiftTests: XCTestCase {

func testError() {
do {
let socket = try Socket.tcpListening(port: 80)
_ = try Socket.tcpListening(port: 80)
} catch let error where (error as! Socket.Error) == Socket.Error.aa {
print(error)
} catch {

0 comments on commit 423e4bc

Please sign in to comment.