-
Notifications
You must be signed in to change notification settings - Fork 23
Add Support for Swift 5.7 #153
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
Merged
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
3b77b84
Add support for Swift 5.7
Andrea-Scuderi 5c75aab
Add support for Swift 5.7
Andrea-Scuderi 671853d
Fix linting
Andrea-Scuderi 3ce8585
Update Swift 5.7 Docker image to Swift 5.7.2
Andrea-Scuderi f2b9212
Remove `rm -rf /var/lib/apt/lists/*` from swift57Action Dockerfile
Andrea-Scuderi 02fe787
Revert "Remove `rm -rf /var/lib/apt/lists/*` from swift57Action Docke…
Andrea-Scuderi e2b37b3
Try to force a rebuild
Andrea-Scuderi 668df44
Update image to swift:5.7.2-bionic
Andrea-Scuderi fbdc9e2
Remove Package.resolved and add Swift 5.7 Tests
Andrea-Scuderi d660bcd
Revert the image back to swift:5.7.2
Andrea-Scuderi 87e3ec5
Update Travis to use Ubuntu Jammy
Andrea-Scuderi 0707e20
Add 5.7 to GHA
Andrea-Scuderi 4917c54
Fix Changelog
Andrea-Scuderi e403cd3
Fix Makefile 5.7
Andrea-Scuderi 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 hidden or 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 hidden or 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 |
---|---|---|
|
@@ -81,3 +81,6 @@ test.json | |
*.done | ||
examples/*/*.zip | ||
ActionLoop/ | ||
|
||
#Swift | ||
**/.swiftpm/ |
This file contains hidden or 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 |
---|---|---|
|
@@ -16,7 +16,7 @@ | |
# | ||
|
||
sudo: required | ||
dist: xenial | ||
dist: jammy | ||
jdk: openjdk8 | ||
language: java | ||
services: | ||
|
This file contains hidden or 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 hidden or 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 hidden or 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,25 @@ | ||
<!-- | ||
# | ||
# Licensed to the Apache Software Foundation (ASF) under one or more | ||
# contributor license agreements. See the NOTICE file distributed with | ||
# this work for additional information regarding copyright ownership. | ||
# The ASF licenses this file to You 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. | ||
# | ||
--> | ||
|
||
# Apache OpenWhisk Swift 5.7 Runtime Container | ||
|
||
- Support for swift async/await | ||
|
||
## 1.17.0 | ||
- Next Apache Release |
This file contains hidden or 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,66 @@ | ||
# | ||
# Licensed to the Apache Software Foundation (ASF) under one or more | ||
# contributor license agreements. See the NOTICE file distributed with | ||
# this work for additional information regarding copyright ownership. | ||
# The ASF licenses this file to You 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. | ||
# | ||
|
||
# build go proxy from source | ||
FROM golang:1.18 AS builder_source | ||
ARG GO_PROXY_GITHUB_USER=apache | ||
ARG GO_PROXY_GITHUB_BRANCH=master | ||
RUN git clone --branch ${GO_PROXY_GITHUB_BRANCH} \ | ||
https://github.com/${GO_PROXY_GITHUB_USER}/openwhisk-runtime-go /src ; \ | ||
cd /src ; env GO111MODULE=on CGO_ENABLED=0 go build main/proxy.go && \ | ||
mv proxy /bin/proxy | ||
|
||
# or build it from a release | ||
FROM golang:1.18 AS builder_release | ||
ARG GO_PROXY_RELEASE_VERSION=1.18@1.20.0 | ||
RUN curl -sL https://github.com/apache/openwhisk-runtime-go/archive/{$GO_PROXY_RELEASE_VERSION}.tar.gz | tar xzf - \ | ||
&& cd openwhisk-runtime-go-*/main \ | ||
&& GO111MODULE=on CGO_ENABLED=0 go build -o /bin/proxy | ||
|
||
FROM swift:5.7.2 | ||
|
||
# select the builder to use | ||
ARG GO_PROXY_BUILD_FROM=release | ||
|
||
RUN rm -rf /var/lib/apt/lists/* \ | ||
&& apt-get clean && apt-get -qq update \ | ||
&& apt-get install -y --no-install-recommends locales python3 vim libssl-dev libicu-dev \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& locale-gen en_US.UTF-8 | ||
|
||
ENV LANG="en_US.UTF-8" \ | ||
LANGUAGE="en_US:en" \ | ||
LC_ALL="en_US.UTF-8" | ||
|
||
RUN mkdir -p /swiftAction | ||
WORKDIR /swiftAction | ||
|
||
COPY --from=builder_source /bin/proxy /bin/proxy_source | ||
COPY --from=builder_release /bin/proxy /bin/proxy_release | ||
RUN mv /bin/proxy_${GO_PROXY_BUILD_FROM} /bin/proxy | ||
ADD swiftbuild.py /bin/compile | ||
ADD swiftbuild.py.launcher.swift /bin/compile.launcher.swift | ||
COPY _Whisk.swift /swiftAction/Sources/ | ||
COPY Package.swift /swiftAction/ | ||
COPY swiftbuildandlink.sh /swiftAction/ | ||
COPY main.swift /swiftAction/Sources/ | ||
RUN swift build -c release; \ | ||
touch /swiftAction/Sources/main.swift; \ | ||
rm /swiftAction/.build/release/Action | ||
|
||
ENV OW_COMPILER=/bin/compile | ||
ENTRYPOINT [ "/bin/proxy" ] |
This file contains hidden or 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,40 @@ | ||
// swift-tools-version:5.7 | ||
// The swift-tools-version declares the minimum version of Swift required to build this package. | ||
|
||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one or more | ||
* contributor license agreements. See the NOTICE file distributed with | ||
* this work for additional information regarding copyright ownership. | ||
* The ASF licenses this file to You 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: "Action", | ||
platforms: [ | ||
.macOS(.v12), | ||
], | ||
products: [ | ||
.executable( | ||
name: "Action", | ||
targets: ["Action"] | ||
) | ||
], | ||
targets: [ | ||
.executableTarget( | ||
name: "Action", | ||
path: "." | ||
) | ||
] | ||
) |
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.
Uh oh!
There was an error while loading. Please reload this page.