The app is written in Swift 5.0, which requires Xcode 10.2 to be installed. CocoaPods is used to manage third party dependencies. Ensure you have CocoaPods installed before proceeding.
- Clone the repository
git clone https://github.com/CameronPorter95/FormBuilder.git
- Run
pod install
- Open
FormBuilder.xcworkspace
with xcode
This will install the CocoaPod dependencies.
*note you will probably have to delete info.plist from the "NextResponderTextField" target inside the pods project. This can be done through BuildPhases->CompileSources
To enable quick local testing and automated UI testing that doesn't rely on a remote server, you can use StubServer project locally that serves prepared static responses. The stub server uses Vapor and is written in Swift. Stub server dependencies are managed with Swift Package Manager.
To setup the stub server:
- download "hschmidt/EnvPane" from: https://github.com/hschmidt/EnvPane/releases/tag/releases%2F0.6
- add the environment variable key: SERVER_DIR with value of the stubserver directory E.G. Documents/projects/app/ios/StubServer
- install vapor by running 'brew install vapor/tap/vapor'
- go to StubServer folder and run 'vapor xcode'
- open the xcode "OrbitRemit" workspace
- select the "run" scheme and choose to execute on "My Mac"
- you should see: "Migrating sqlite DB Migrations complete Server starting on http://localhost:8080" in the console. go to: http://localhost:8080/forms.json and check that you're getting json response from the stub server to verify that it is working
- run the "OrbitRemitStubs" scheme on your iPhone of choice.
- success!
Created by Cameron Porter on 30/05/19