View on GitHub

pattern-atlas-api

https://patternatlas.github.io/pattern-atlas-api/

IntelliJ Setup

  1. At start of IntelliJ, browse to the root pom.xml and open it as project.
  2. Enable checkstyle:
    • Install the IntelliJ CheckStyle-IDEA Plugin. It can be found via plug-in repository
      (File > Settings > Plugins > Marketplace; Mac: IntelliJ IDEA > Preferences > Plugins > Marketplace).
      checkstyle
  1. Enable Lombok:
    • Install the IntelliJ Lombok-IDEA Plugin. It can be found via plug-in repository
      (File > Settings > Plugins > Marketplace; Mac: IntelliJ IDEA > Preferences > Plugins > Marketplace). checkstyle
    • Install the CheckStyle-IDEA Plugin, click “Apply” and restart the project upon request.
  2. Configure the code style (Source: https://youtrack.jetbrains.com/issue/IDEA-61520#comment=27-1292600)
    • Open the Settings (by pressing Ctrl + Alt + S; Mac: command + ,)
    • Go to “Editor > Code Style”
    • Click on the gear icon (right of “Scheme:”)
    • Click “Import Scheme”
    • Choose “IntelliJ IDEA code style XML”
    • Navigate to intellij-idea-code-style.xml. It is located in docs/dev/config/IntelliJ IDEA.
    • Click “Apply”
    • Click “OK”
    • Click “Close”
  3. Setup code headers to be inserted automatically
    copyright-profile
    • Open the Settings (by pressing Ctrl + Alt + S; Mac: command + ,)
    • Go to “Editor > Copyright > Copyright Profiles”
    • Click the “+”
    • Name “Atlas”
    • Copyright text from CodeHeaders
    • Click “Apply”
    • Go to “Editor > Copyright > Formatting”
    • Adjust copyright formatting settings

    checkstyle - Change to Use block comments with Prefix each line - Set Relative Location to Before other comments - Set Separator beforeto 80 and Separator after to 81 - Go to “Editor > Copyright” - Set “Atlas” as Default project copyright - Click “Apply”

  4. Configure Git to handle line endings
    • Insert the following commands in your console:
      For Windows: git config --global core.autocrlf true
      For Mac/Linux: git config --global core.autocrlf input
  5. Set up database:
    • Open Terminal in IntelliJ checkstyle
    • Navigate to directory ..\.docker\
    • Insert the following commands docker-compose up -d
    • Open “Database” checkstyle
    • Click the “+”
    • Go to “Data Source > PostgresSQL”
    • Enter username and password: “postgres” (both) checkstyle
    • Click “Apply”
  6. Save to database:
    • Open “Database” checkstyle
    • Go to “postgres@localhost > databases > postgres > schemas > public > tables”
    • Right-Click on “tables” checkstyle
    • Go to “Dump Data to File(s)”
    • Click on “SQL Inserts”
    • Click on the “Output directory”
    • Choose the target sql file
    • Hit “Enter”