SwiftSyntaxSerializer
is a command line tool that lets you parse Swift code into a JSON-LD serialization format and vice versa.
This tool is part of the Whole Platform; the installation of this tool is necessary in order to enable the native Swift persistence of the Swift and SwiftSyntax languages.
SwiftSyntaxSerializer
depends on SwiftSyntax for parsing and unparsing the Swift code and on SwiftFormat for formatting the Whole generated code.
The version of the standalone parsing library that is distributed as part of the Swift toolchain must match the one expected by SwiftSyntax. So you should check out and build SwiftSyntaxSerializer
from the branch that is compatible with the version of Swift you are using. As an alternative you can install and switch to a compatible Swift toolchain.
The last supported version of Swift is: 5.1. Check from the command line the version of Swift you are using.
$ swift --version
Apple Swift version 5.1.3 (swiftlang-1100.0.282.1 clang-1100.0.33.15)
Clone the repository and build the executable with the Swift Package Manager included with Swift.
git clone https://github.com/wholeplatform/whole-swift-syntaxserializer.git
cd whole-swift-syntaxserializer
swift build -c release
cp .build/release/SwiftSyntaxSerializer /usr/local/bin
The Whole Platform is Copyright 2004-2020 Riccardo Solmi. All rights reserved.
The Whole Platform is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
The Whole Platform is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
link |
Stars: 0 |
Last commit: 4 years ago |
Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics