Creating Projects in Perfect Assistant

Perfect Assistant is the ringmaster of a number of different applications and processes that you will use to create or manage your Server Side Swift applications. 

These instructions guide you through project creation after you have installed Xcode 8.3+, downloaded and opened Perfect Assistant, and downloaded and configured Docker. (If you haven't completed these, please see 'Installation')



The main window in Perfect Assistant is referred to as the Index. This window consists of a list of all your projects and deployment configurations on the left, and a collection of project templates and possible deployment configurations on the right. The right-side view can be toggled hidden by clicking the show/hide button seen at the bottom of the projects & deployments list. The Index window can always be brought to the front by clicking the Index toolbar button on the project and deployment editors, or by using the ⌘-0 (zero) key combination. If the index window is in front, this key combination can also be used to show/hide the templates view.

The Index's project list also features a search field located at the bottom of the view. This field permits the available projects to be filtered according to a search term.

Creating Projects

To create a new project, double click one of the project templates seen in the "Create Project" view.

The basic project templates are:

  • Import Existing Project: Add an existing Swift Package Manager based project to Perfect Assistant.
  • Perfect Template App: A simple multi-server listening on ports 8080 and 8181. Includes a simple HTTP handler.
  • Empty Executable Project: An empty Swift Package Manager project producing an executable.
  • Empty Library Project: An empty Swift Package Manager project producing a library.
  • Custom Repository URL: Clone an existing Swift Package Manager based git hosted repository.

In addition to these basic templates, Perfect Assistant provides a series of ready to run example servers for Perfect as well as for the Kitura and Vapor frameworks.

Double-clicking on a project template will display a sheet letting you configure the project before it is created.

Enter or select an empty directory into which the new project will be placed. Also enter a name for your project. This name field will initially be automatically filled based on the project's directory name.

Xcode Integration

If you wish to have your corresponding Xcode project perform automatic on-going Linux builds at the same time that you build your project for macOS, select the "Integrate Linux Builds with Xcode Project" checkbox. If this is selected then a custom build script step will automatically be added to Xcode projects whenever Perfect Assistant (re)generates the project files due to dependency changes. Note that enabling this will lengthen your Xcode build times but will provide you with active notifications for any Linux-side build errors or warnings as you develop your project in Xcode. This option can always be enabled or disabled from within the project editor itself. This option is only respected when automatic Xcode project regenerations are performed due to project dependency changes; choosing the "Regenerate Xcode Project" or "Integrate Xcode Project" commands from the project editor will bypass this option letting you perform temporarily integrated or un-integrated project generations.

Once you have configured your new project and clicked "Create", the new project will be cloned or created in the indicated directory and the project editor window will be opened. Perfect Assistant will then automatically generate the corresponding Xcode project (with or without Linux build integration) which will pull in all of the project's related macOS dependencies.

Next: Managing Projects