Procházet zdrojové kódy

Also move the Simple example into `Sources/`.

Daniel Alm před 7 roky
rodič
revize
05890b5054

+ 1 - 1
.travis.yml

@@ -42,4 +42,4 @@ script:
   - export LD_LIBRARY_PATH=$HOME/local/lib
   - make test
   - make test-plugin
-  - make test-examples
+  - make test-echo

+ 0 - 8
Examples/Simple/PackageManager/Makefile

@@ -1,8 +0,0 @@
-
-all:
-	swift build
-
-clean :
-	rm -rf Packages
-	rm -rf .build
-	rm -rf Package.pins Package.resolved

+ 0 - 33
Examples/Simple/PackageManager/Package.swift

@@ -1,33 +0,0 @@
-// swift-tools-version:4.0
-
-/*
- * Copyright 2017, gRPC Authors All rights reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-import PackageDescription
-
-let package = Package(
-  name: "Simple",
-  dependencies: [
-    .package(url: "../../..", .branch("HEAD")),
-    .package(url: "https://github.com/kylef/Commander.git", from: "0.8.0")
-  ],
-  targets: [
-    .target(name: "Simple",
-            dependencies: [
-              "SwiftGRPC",
-              "Commander"
-            ],
-	    path: ".")
-  ])

+ 0 - 0
Examples/Simple/Xcode/README.md → Examples/SimpleXcode/README.md


+ 0 - 0
Examples/Simple/Xcode/Simple.xcodeproj/project.pbxproj → Examples/SimpleXcode/Simple.xcodeproj/project.pbxproj


+ 0 - 0
Examples/Simple/Xcode/Simple/AppDelegate.swift → Examples/SimpleXcode/Simple/AppDelegate.swift


+ 0 - 0
Examples/Simple/Xcode/Simple/Assets.xcassets/AppIcon.appiconset/Contents.json → Examples/SimpleXcode/Simple/Assets.xcassets/AppIcon.appiconset/Contents.json


+ 0 - 0
Examples/Simple/Xcode/Simple/Base.lproj/Document.xib → Examples/SimpleXcode/Simple/Base.lproj/Document.xib


+ 0 - 0
Examples/Simple/Xcode/Simple/Base.lproj/MainMenu.xib → Examples/SimpleXcode/Simple/Base.lproj/MainMenu.xib


+ 0 - 0
Examples/Simple/Xcode/Simple/Document.swift → Examples/SimpleXcode/Simple/Document.swift


+ 0 - 0
Examples/Simple/Xcode/Simple/Info.plist → Examples/SimpleXcode/Simple/Info.plist


+ 0 - 3
Makefile

@@ -22,9 +22,6 @@ test-echo:	all
 	kill -9 `cat echo.pid`
 	diff -u test.out Sources/EchoExample/test.gold
 
-test-examples: test-echo
-	cd Examples/Simple/PackageManager; make
-
 test-plugin: all
 	protoc Sources/EchoExample/echo.proto --proto_path=Sources/EchoExample --plugin=.build/debug/protoc-gen-swift --plugin=.build/debug/protoc-gen-swiftgrpc --swiftgrpc_out=/tmp --swiftgrpc_opt=TestStubs=true
 	diff -u /tmp/echo.grpc.swift Sources/EchoExample/Generated/echo.grpc.swift

+ 3 - 0
Package.swift

@@ -46,5 +46,8 @@ let package = Package(
               "Commander"
             ],
             path: "Sources/EchoExample"),
+    .target(name: "Simple",
+            dependencies: ["SwiftGRPC", "Commander"],
+            path: "Sources/SimpleExample"),
     .testTarget(name: "SwiftGRPCTests", dependencies: ["SwiftGRPC"])
   ])

+ 0 - 0
Examples/Simple/PackageManager/README.md → Sources/SimpleExample/README.md


+ 0 - 0
Examples/Simple/PackageManager/main.swift → Sources/SimpleExample/main.swift