Skip to content

Commit 13311b9

Browse files
Merge pull request #9 from SomeRandomiOSDev/Modernize
Regenerated project and migrated to `gyb` package
2 parents 9b6551b + 7e8318a commit 13311b9

24 files changed

+970
-1882
lines changed

.github/workflows/cocoapods.yml

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,15 @@ on: [push, workflow_dispatch]
33

44
jobs:
55
lint:
6+
strategy:
7+
matrix:
8+
linttype: [Dynamic, Static]
9+
610
name: Lint
711
runs-on: macOS-11
12+
env:
13+
LINT_TYPE: ${{ matrix.linttype }}
14+
815
steps:
916
- name: Checkout Code
1017
uses: actions/checkout@v2
@@ -14,10 +21,10 @@ jobs:
1421
with:
1522
version: latest
1623

17-
- name: Lint (Dynamic Library)
18-
run: |
19-
pod lib lint
20-
21-
- name: Lint (Static Library)
24+
- name: Lint
2225
run: |
23-
pod lib lint --use-libraries
26+
if [ "$LINT_TYPE" == "Dynamic" ]; then
27+
pod lib lint
28+
else
29+
pod lib lint --use-libraries
30+
fi

.github/workflows/swift-pacakge.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ jobs:
3939
- name: Generate Code Coverage File
4040
if: ${{ runner.os == 'macOS' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
4141
run: |
42-
xcrun llvm-cov export --instr-profile=.build/x86_64-apple-macosx/debug/codecov/default.profdata .build/x86_64-apple-macosx/debug/HalfPackageTests.xctest/Contents/MacOS/HalfPackageTests > ./info.lcov
42+
xcrun llvm-cov export --format=lcov --instr-profile=".build/debug/codecov/default.profdata" ".build/debug/HalfPackageTests.xctest/Contents/MacOS/HalfPackageTests" > "./codecov.lcov"
4343
4444
- name: Upload Code Coverage
4545
if: ${{ runner.os == 'macOS' && github.event_name == 'push' && github.ref == 'refs/heads/main' }}
46-
uses: codecov/codecov-action@v1
46+
uses: codecov/codecov-action@v2
4747
with:
4848
token: ${{ secrets.CODECOV_TOKEN }}
49-
file: ./info.lcov
49+
file: ./codecov.lcov
5050
verbose: true

.github/workflows/swiftlint.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: SwiftLint
2+
on: [push, workflow_dispatch]
3+
4+
jobs:
5+
build:
6+
name: Run SwiftLint
7+
runs-on: macOS-latest
8+
9+
steps:
10+
- name: Checkout Code
11+
uses: actions/checkout@v2
12+
13+
- name: Run SwiftLint
14+
run: |
15+
swiftlint lint --reporter github-actions-logging

.github/workflows/upload-assets.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616

1717
- name: Build
1818
run: |
19-
./scripts/xcframework.sh -output ${TMPDIR}/Half.xcframework
19+
./scripts/xcframework.sh --output ${TMPDIR}/Half.xcframework
2020
2121
- name: Create Zip
2222
run: |

.github/workflows/xcframework.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ jobs:
1414

1515
- name: Build
1616
run: |
17-
./scripts/xcframework.sh -output ${TMPDIR}/Half.xcframework
17+
./scripts/xcframework.sh --output ${TMPDIR}/Half.xcframework

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,3 @@ Half.xcodeproj/xcuserdata
44
.build
55
.swiftpm
66
scripts/build
7-
gyb.pyc

.swiftlint.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ opt_in_rules:
2929
- vertical_parameter_alignment_on_call
3030
- pattern_matching_keywords
3131
- fatal_error_message
32-
- implicit_return
3332
- implicitly_unwrapped_optional
3433
- joined_default_parameter
3534
- let_var_whitespace
@@ -59,6 +58,8 @@ opt_in_rules:
5958
reporter: "xcode"
6059

6160
excluded:
61+
- Pods
62+
- Carthage
6263
- Tests/LinuxMain.swift
6364
- Tests/HalfTests/XCTestManifests.swift
6465
- Tests/CHalfTests/XCTestManifests.swift

ATTRIBUTIONS

Lines changed: 0 additions & 219 deletions
Original file line numberDiff line numberDiff line change
@@ -531,222 +531,3 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
531531
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
532532
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
533533
THE SOFTWARE.
534-
535-
536-
537-
gyb and gyb.py are copied from the Swift project.
538-
539-
https://github.com/apple/swift
540-
--------------------------------------------------
541-
542-
Apache License
543-
Version 2.0, January 2004
544-
http://www.apache.org/licenses/
545-
546-
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
547-
548-
1. Definitions.
549-
550-
"License" shall mean the terms and conditions for use, reproduction,
551-
and distribution as defined by Sections 1 through 9 of this document.
552-
553-
"Licensor" shall mean the copyright owner or entity authorized by
554-
the copyright owner that is granting the License.
555-
556-
"Legal Entity" shall mean the union of the acting entity and all
557-
other entities that control, are controlled by, or are under common
558-
control with that entity. For the purposes of this definition,
559-
"control" means (i) the power, direct or indirect, to cause the
560-
direction or management of such entity, whether by contract or
561-
otherwise, or (ii) ownership of fifty percent (50%) or more of the
562-
outstanding shares, or (iii) beneficial ownership of such entity.
563-
564-
"You" (or "Your") shall mean an individual or Legal Entity
565-
exercising permissions granted by this License.
566-
567-
"Source" form shall mean the preferred form for making modifications,
568-
including but not limited to software source code, documentation
569-
source, and configuration files.
570-
571-
"Object" form shall mean any form resulting from mechanical
572-
transformation or translation of a Source form, including but
573-
not limited to compiled object code, generated documentation,
574-
and conversions to other media types.
575-
576-
"Work" shall mean the work of authorship, whether in Source or
577-
Object form, made available under the License, as indicated by a
578-
copyright notice that is included in or attached to the work
579-
(an example is provided in the Appendix below).
580-
581-
"Derivative Works" shall mean any work, whether in Source or Object
582-
form, that is based on (or derived from) the Work and for which the
583-
editorial revisions, annotations, elaborations, or other modifications
584-
represent, as a whole, an original work of authorship. For the purposes
585-
of this License, Derivative Works shall not include works that remain
586-
separable from, or merely link (or bind by name) to the interfaces of,
587-
the Work and Derivative Works thereof.
588-
589-
"Contribution" shall mean any work of authorship, including
590-
the original version of the Work and any modifications or additions
591-
to that Work or Derivative Works thereof, that is intentionally
592-
submitted to Licensor for inclusion in the Work by the copyright owner
593-
or by an individual or Legal Entity authorized to submit on behalf of
594-
the copyright owner. For the purposes of this definition, "submitted"
595-
means any form of electronic, verbal, or written communication sent
596-
to the Licensor or its representatives, including but not limited to
597-
communication on electronic mailing lists, source code control systems,
598-
and issue tracking systems that are managed by, or on behalf of, the
599-
Licensor for the purpose of discussing and improving the Work, but
600-
excluding communication that is conspicuously marked or otherwise
601-
designated in writing by the copyright owner as "Not a Contribution."
602-
603-
"Contributor" shall mean Licensor and any individual or Legal Entity
604-
on behalf of whom a Contribution has been received by Licensor and
605-
subsequently incorporated within the Work.
606-
607-
2. Grant of Copyright License. Subject to the terms and conditions of
608-
this License, each Contributor hereby grants to You a perpetual,
609-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
610-
copyright license to reproduce, prepare Derivative Works of,
611-
publicly display, publicly perform, sublicense, and distribute the
612-
Work and such Derivative Works in Source or Object form.
613-
614-
3. Grant of Patent License. Subject to the terms and conditions of
615-
this License, each Contributor hereby grants to You a perpetual,
616-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
617-
(except as stated in this section) patent license to make, have made,
618-
use, offer to sell, sell, import, and otherwise transfer the Work,
619-
where such license applies only to those patent claims licensable
620-
by such Contributor that are necessarily infringed by their
621-
Contribution(s) alone or by combination of their Contribution(s)
622-
with the Work to which such Contribution(s) was submitted. If You
623-
institute patent litigation against any entity (including a
624-
cross-claim or counterclaim in a lawsuit) alleging that the Work
625-
or a Contribution incorporated within the Work constitutes direct
626-
or contributory patent infringement, then any patent licenses
627-
granted to You under this License for that Work shall terminate
628-
as of the date such litigation is filed.
629-
630-
4. Redistribution. You may reproduce and distribute copies of the
631-
Work or Derivative Works thereof in any medium, with or without
632-
modifications, and in Source or Object form, provided that You
633-
meet the following conditions:
634-
635-
(a) You must give any other recipients of the Work or
636-
Derivative Works a copy of this License; and
637-
638-
(b) You must cause any modified files to carry prominent notices
639-
stating that You changed the files; and
640-
641-
(c) You must retain, in the Source form of any Derivative Works
642-
that You distribute, all copyright, patent, trademark, and
643-
attribution notices from the Source form of the Work,
644-
excluding those notices that do not pertain to any part of
645-
the Derivative Works; and
646-
647-
(d) If the Work includes a "NOTICE" text file as part of its
648-
distribution, then any Derivative Works that You distribute must
649-
include a readable copy of the attribution notices contained
650-
within such NOTICE file, excluding those notices that do not
651-
pertain to any part of the Derivative Works, in at least one
652-
of the following places: within a NOTICE text file distributed
653-
as part of the Derivative Works; within the Source form or
654-
documentation, if provided along with the Derivative Works; or,
655-
within a display generated by the Derivative Works, if and
656-
wherever such third-party notices normally appear. The contents
657-
of the NOTICE file are for informational purposes only and
658-
do not modify the License. You may add Your own attribution
659-
notices within Derivative Works that You distribute, alongside
660-
or as an addendum to the NOTICE text from the Work, provided
661-
that such additional attribution notices cannot be construed
662-
as modifying the License.
663-
664-
You may add Your own copyright statement to Your modifications and
665-
may provide additional or different license terms and conditions
666-
for use, reproduction, or distribution of Your modifications, or
667-
for any such Derivative Works as a whole, provided Your use,
668-
reproduction, and distribution of the Work otherwise complies with
669-
the conditions stated in this License.
670-
671-
5. Submission of Contributions. Unless You explicitly state otherwise,
672-
any Contribution intentionally submitted for inclusion in the Work
673-
by You to the Licensor shall be under the terms and conditions of
674-
this License, without any additional terms or conditions.
675-
Notwithstanding the above, nothing herein shall supersede or modify
676-
the terms of any separate license agreement you may have executed
677-
with Licensor regarding such Contributions.
678-
679-
6. Trademarks. This License does not grant permission to use the trade
680-
names, trademarks, service marks, or product names of the Licensor,
681-
except as required for reasonable and customary use in describing the
682-
origin of the Work and reproducing the content of the NOTICE file.
683-
684-
7. Disclaimer of Warranty. Unless required by applicable law or
685-
agreed to in writing, Licensor provides the Work (and each
686-
Contributor provides its Contributions) on an "AS IS" BASIS,
687-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
688-
implied, including, without limitation, any warranties or conditions
689-
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
690-
PARTICULAR PURPOSE. You are solely responsible for determining the
691-
appropriateness of using or redistributing the Work and assume any
692-
risks associated with Your exercise of permissions under this License.
693-
694-
8. Limitation of Liability. In no event and under no legal theory,
695-
whether in tort (including negligence), contract, or otherwise,
696-
unless required by applicable law (such as deliberate and grossly
697-
negligent acts) or agreed to in writing, shall any Contributor be
698-
liable to You for damages, including any direct, indirect, special,
699-
incidental, or consequential damages of any character arising as a
700-
result of this License or out of the use or inability to use the
701-
Work (including but not limited to damages for loss of goodwill,
702-
work stoppage, computer failure or malfunction, or any and all
703-
other commercial damages or losses), even if such Contributor
704-
has been advised of the possibility of such damages.
705-
706-
9. Accepting Warranty or Additional Liability. While redistributing
707-
the Work or Derivative Works thereof, You may choose to offer,
708-
and charge a fee for, acceptance of support, warranty, indemnity,
709-
or other liability obligations and/or rights consistent with this
710-
License. However, in accepting such obligations, You may act only
711-
on Your own behalf and on Your sole responsibility, not on behalf
712-
of any other Contributor, and only if You agree to indemnify,
713-
defend, and hold each Contributor harmless for any liability
714-
incurred by, or claims asserted against, such Contributor by reason
715-
of your accepting any such warranty or additional liability.
716-
717-
END OF TERMS AND CONDITIONS
718-
719-
APPENDIX: How to apply the Apache License to your work.
720-
721-
To apply the Apache License to your work, attach the following
722-
boilerplate notice, with the fields enclosed by brackets "[]"
723-
replaced with your own identifying information. (Don't include
724-
the brackets!) The text should be enclosed in the appropriate
725-
comment syntax for the file format. We also recommend that a
726-
file or class name and description of purpose be included on the
727-
same "printed page" as the copyright notice for easier
728-
identification within third-party archives.
729-
730-
Copyright [yyyy] [name of copyright owner]
731-
732-
Licensed under the Apache License, Version 2.0 (the "License");
733-
you may not use this file except in compliance with the License.
734-
You may obtain a copy of the License at
735-
736-
http://www.apache.org/licenses/LICENSE-2.0
737-
738-
Unless required by applicable law or agreed to in writing, software
739-
distributed under the License is distributed on an "AS IS" BASIS,
740-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
741-
See the License for the specific language governing permissions and
742-
limitations under the License.
743-
744-
745-
746-
## Runtime Library Exception to the Apache 2.0 License: ##
747-
748-
749-
As an exception, if you use this Software to compile your source code and
750-
portions of this Software are embedded into the binary product as a result,
751-
you may redistribute such product without providing attribution as would
752-
otherwise be required by Sections 4(a), 4(b) and 4(d) of the License.

Half.podspec

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
Pod::Spec.new do |s|
2-
2+
33
s.name = "Half"
4-
s.version = "1.2.1"
4+
s.version = "1.2.2"
55
s.summary = "Swift Half-Precision Floating Point"
66
s.description = <<-DESC
77
A lightweight framework containing a Swift implementation for a half-precision floating point type for iOS, macOS, tvOS, and watchOS.
88
DESC
9-
9+
1010
s.homepage = "https://github.com/SomeRandomiOSDev/Half"
1111
s.license = "MIT"
1212
s.author = { "Joe Newton" => "somerandomiosdev@gmail.com" }
@@ -30,5 +30,5 @@ Pod::Spec.new do |s|
3030
ts.source_files = 'Tests/CHalfTests/*Tests.swift',
3131
'Tests/HalfTests/*Tests.swift'
3232
end
33-
33+
3434
end

0 commit comments

Comments
 (0)