-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Swift iphone app template #1870
Merged
Merged
Changes from 10 commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
4e8b79e
draft swift template
krisbitney 7ce4cd2
added cocoapods
krisbitney bc889b7
adjustments for use with cocoapods
krisbitney e7fede2
fix .gitignore
krisbitney beca7b0
fix .gitignore
krisbitney 5316b44
swift template working
krisbitney 29dc8eb
changed swift template codegen url to github url
krisbitney 8e8c544
changed swift template codegen to assume url is known by cli
krisbitney 6273728
added "ios" app template option to polywrap create command
krisbitney acfa2b1
updated polywrap create "help" expected output
krisbitney 08cfd3f
Update packages/templates/app/ios/polywrap.graphql
krisbitney 6cf00b5
using latest bindings
krisbitney 2e774b8
using "Ethers" instead of "Ethereum"
krisbitney e2ee8a6
merge origin-dev
dOrgJelli c3da5ee
Merge branch 'origin-dev' into kris/swift-template
dOrgJelli 4e9996b
Update tests.spec.ts
dOrgJelli File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# Polywrap | ||
wrap | ||
|
||
# AppCode | ||
.idea/ | ||
.idea_modules/ | ||
|
||
# User-specific | ||
*.iml | ||
|
||
# Xcode | ||
*.pbxuser | ||
!default.pbxuser | ||
*.mode1v3 | ||
!default.mode1v3 | ||
*.mode2v3 | ||
!default.mode2v3 | ||
*.perspectivev3 | ||
!default.perspectivev3 | ||
xcuserdata/ | ||
*.moved-aside | ||
|
||
# Compiled Source | ||
*.pyc | ||
*.o | ||
*.out | ||
|
||
# Project Files | ||
*.xcworkspace | ||
|
||
# CocoaPods | ||
Pods/ | ||
|
||
# Carthage | ||
Carthage/Build | ||
|
||
# Swift Package Manager | ||
.build/ | ||
|
||
# macOS | ||
.DS_Store | ||
.AppleDouble | ||
.LSOverride | ||
|
||
# Unix | ||
*.swp | ||
*~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Uncomment the next line to define a global platform for your project | ||
# platform :ios, '9.0' | ||
|
||
target 'Template' do | ||
# Comment the next line if you don't want to use dynamic frameworks | ||
use_frameworks! | ||
|
||
# Pods for Template | ||
pod 'PolywrapClient', '0.0.8' | ||
|
||
target 'TemplateTests' do | ||
inherit! :search_paths | ||
# Pods for testing | ||
end | ||
|
||
target 'TemplateUITests' do | ||
# Pods for testing | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
PODS: | ||
- AsyncObjects (2.1.0): | ||
- OrderedCollections (~> 1.0.0) | ||
- MessagePacker (0.4.7) | ||
- OrderedCollections (1.0.4) | ||
- PolywrapClient (0.0.8): | ||
- AsyncObjects (~> 2.1.0) | ||
- MessagePacker (~> 0.4.7) | ||
- PolywrapClientNative (~> 0.0.7) | ||
- PolywrapClientNative (0.0.7) | ||
|
||
DEPENDENCIES: | ||
- PolywrapClient (= 0.0.8) | ||
|
||
SPEC REPOS: | ||
trunk: | ||
- AsyncObjects | ||
- MessagePacker | ||
- OrderedCollections | ||
- PolywrapClient | ||
- PolywrapClientNative | ||
|
||
SPEC CHECKSUMS: | ||
AsyncObjects: 37d04187100fd9cd545a6570a8ad727c5a3c5090 | ||
MessagePacker: ab2fe250e86ea7aedd1a9ee47a37083edd41fd02 | ||
OrderedCollections: c754ce5f9e42cf22b73afd73582317347903ab6d | ||
PolywrapClient: c8f2edac2500bbc421dfe7d2c4af757fa6db7224 | ||
PolywrapClientNative: 30398b076b00c8bbf5c2046cfa1c1554c3c31321 | ||
|
||
PODFILE CHECKSUM: 90587966da0d18a791d29e2a8d3181c36468506e | ||
|
||
COCOAPODS: 1.12.1 |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should here be
swift
and notios
? btw idk whyswift
is not added in theplugin
array below this line 🤔 we have support for pluginsThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made it "ios" and "android" for swift and Kotlin for clarity.
Swift is used for iOS, macOS, watchOS, and tvOS and I'm not sure what else.
Kotlin is used for Android, desktop, web back ends, multiplatform mobile apps, and more.
Do you think it makes more sense to do "swift" and "kotlin"? Maybe iOS and Android use cases are implied?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I lean toward the android/ios since the template specifically targets those. If it was a generic template then the language name would make more sense
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what you're saying make sense, but swift client supports
iOS
andmacOS
.it still makes more sense to me to name this
swift
andkotlin
rather thanios
orandroid
; this is codegen and from my perspective it should be agnostic of the OS (even tho I completely understand your point)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If they're android/ios specific templates then IMO this should be "ios".
But, correct me if I'm wrong, it doesn't seem that is the case: https://github.com/polywrap/wrap-abi-bindgen/pull/55/files#diff-2539b6e33504cb7efe01bdb09121a3aaba4ba6023d13c460f34dcb161ca244de
Also, whatever we do, we should be consistent. In this thread there's a push for "ios" while in that link it's "app-swift"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The codegen bindings are not specific to ios, but the app template is a simple ios app
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
iOS and Android are platforms, not languages. It's a bit weird to have "iOS, Golang, Android, Typescript, Interface"; as it seems there are 3, or at least 2, concepts mixed in there.
That said, the template you're talking about targets "iOS" in particular. If it was generic enough to be built to macOS or tvOS, then it should be swift; but it isn't. I think here the answer should be "ios"; but indeed a bit weird to have "ios" as a "supportedLang". Maybe it's just a variable naming change thing, but nvm.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This situation is VERY similar to when we had a "react" app template. So, based on how we handled that, I suggest we:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also one detail to make sure we're all clear on: "android" and "ios" are ONLY used within the
polywrap create
command. All other places (codegen, manifest, etc) "kotlin" and "swift" are used.