Bootstrapping the App

The starting point for the workshop is the Apple Swift UI tutorial at the “Handling User Input” step.

  1. Download the project zip file
    The file has the following directory structure Directory Structure

  2. This workshop will start from the Complete version of the tutorial project. In the remaining part of this workshop, $PROJECT_DIRECTORY will refer to ~/Downloads/amplify-ios-workshop/Complete/Landmarks.

    Unzip the file and open the XCode project:

    # download the workshop ZIP file
    curl -o ~/Downloads/HandlingUserInput.zip https://amplify-ios-workshop.go-aws.com/20_getting_started/20_bootstrapping_the_app.files/HandlingUserInput.zip
    
    # unzip 
    cd ~/Downloads
    mkdir amplify-ios-workshop
    cd amplify-ios-workshop
    unzip ../HandlingUserInput.zip
    
    # set env variable
    PROJECT_DIRECTORY=~/Downloads/amplify-ios-workshop/Complete/Landmarks
    cd $PROJECT_DIRECTORY
    
    # open xcode 
    open HandlingUserInput.xcodeproj
    

    You can safely ackowledge XCode’s message informing you this app has been downloaded from Internet. XCode warning

  3. In XCode, Choose the iOS Simulator you want to use (I am using iPhone 11) and click the build icon or press ⌘R. First build

After a few seconds, you should see the application running in the iOS simulator. First run

In the following steps, we will guide you through step by step instructions to modify this app to add user authentication and a data-driven API.

If the example application in not starting or not working as described above, do not proceed to the next section. The instructions will fail at some point.