Initialize Your Catalyst Project

You can now begin working on your Catalyst project from the CLI. The first step is to initialize the project in an empty directory. This will be the home directory of your project and all of the project files will be saved in it.

You can learn more about this from the Project Directory Structure help page. You can learn about initializing a project in detail from the CLI help documentation.

For this application, you will be initializing the AppSail component. The AppSail component will be initialized in the Node.js programming stack.

  1. Launch Catalyst CLI terminal in the /aliencity directory you just unzipped, and execute the following CLI command.
copy
$
catalyst init

Navigate using the arrow keys and select your preferred portal and click Enter. If you have no other organizations associated with the account, then the default will be selected automatically. catalyst_alien_city_cli_portal_choice You can find out more about Catalyst’s multi-org portal feature in this help document.

  1. The CLI will now ask you to associate a Catalyst project with the directory. Associate it with the project that we created earlier from the console. Select Alien City from the list and click Enter. catalyst_alien_city_cli_project_choice

  2. Select AppSail using the space bar, then click Enter to initialize. catalyst_alien_city_cli_appsail_select

  3. The CLI will initiate the AppSail service:

    • Because you are creating your own project, enter “n” and click Enter for the prompt asking if you wish to get started with a list of recommended projects.
    • Because you have initialized the project in the Alien City/ directory created specifically for this application, enter “Y” and click Enter for the prompt asking you to confirm if this the directory you wish to initialize your AppSail service. catalyst_alien_city_cli_appsail_setup_start
  4. Next, we will begin configuring our AppSail service. Select your current directory as the build path of your AppSail service. catalyst_alcity_appsail_spring_choose_appsail_path

  5. Enter “aliencity” as the name of your AppSail service, and choose the latest runtime of Java as the programming stack, and click Enter. catalyst_alcity_appsail_spring_choose_java_func

  6. Choose Java SE as the platform for your AppSail service, and click Enter. catalyst_alcity_appsail_spring_choose_java_plat

The AppSail service has been initialized for your Alien City project. catalyst_alcity_appsail_spring_init_completed

The aliencity/ directory will be modified to contain the app-config.json file which includes the configuration of your AppSail service, along with the standard project configuration files such as the catalyst.json file and a hidden .catalystrc file.

This structure of the aliencity Spring Boot project’s directory initialized with the AppSail service is shown below: catalyst_alcity_appsail_spring_catalyst_init_dir

Last Updated 2024-02-22 23:26:30 +0530 +0530