Skip to content

Installation‐manual

Roar Andre Saanum Fagerkind edited this page Apr 15, 2026 · 20 revisions

Installation Guide HmH-Application

Table of contents

Prerequisites

The following prerequisites are required to run the application:

Required:

Optional (Recommended):

  • Git -- Version 2.53 or later
    Download: https://git-scm.com/install/

  • Integrated Development Environment (IDE) -- An IDE with built-in Maven support is recommended

Example: IntelliJ IDEA (Community or Ultimate Edition)
Download: https://www.jetbrains.com/idea/download/

Verify prerequisites installation

After installing the prerequisites, verify that they are installed correctly and available in your system PATH.

Verify Java

Run the following command in your terminal or command prompt:

Java -version

You should see output indicating Java version 25.

Verify Maven

If you installed Maven manually (i.e. not through an IDE), run the following command:

mvn -version

You should see output indicating Maven version 3.9 or later.

Verify Git (optional)

To verify Git installation, run the command:

git --version

Output should ideally show version 2.53 or higher.

Using an IDE with built-in Maven

If you are using an IDE with built-in Maven support, e.g. IntelliJ IDEA:

  • Maven is typically bundled and does not need to be installed separately

  • You can verify Maven functionality by importing the project and checking if dependencies are resolved correctly

  • Alternatively, you can run the command in "2. Verify Maven" in the IDE's terminal

Installation Steps

If you have any problems during any of these steps, please refer to the troubleshooting section.

Obtaining the Source Code

To begin installing the application you first need to obtain the source code to build it. The source code is located at: https://git.ntnu.no/cathrkri/systemutviklingTeam6.

Click the green code button and you will be presented with 5 choices for downloading:

img

Figure 1 - Options for downloading source code

At the top: HTTPS, SSH, GitHub CLI. At the bottom: Open with GitHub Desktop, and Download Zip.

Simple install

If you want the simplest option, click "Download ZIP", and unzip the downloaded zip-file to an easy to remember location on your computer.

Recommended install

We recommend that you go with SSH for obtaining the source code. To use SSH, you need to already have an SSH key pair on your computer. If you don't already have one, here is a guide by NTNU how to create one: https://wiki.math.ntnu.no/drift/help/using_ssh_keys.

Once you have a valid key-pair on your computer, select SSH, and then click the icon with the two rectangles next to the URL below the top choices. This will copy the SSH-link to your clipboard. If you installed git as a prerequisite, you can then open command prompt or a terminal window, and type:

-git clone <URLToRepositoryWithout<>Marks>

,inputting the URL you just copied without the "<>" marks. This will clone the git repository to the location given by your command prompt or terminal window.

Here is an example of how the cloning process looks on Windows 11 command prompt:

img

Figure 2 - Example of SSH-cloning git repository

In Figure 2, the repository will be saved to "C:\Users\Roar\systemutviklingTeam6". You can change the folder location of the terminal before cloning to save the repository somewhere else or move it manually after downloading.

If you did not install git, you can run the git-clone command in the terminal in your IDE. First, open your IDE and create a new project. Then, when the IDE has finished setting up, open the terminal in your IDE, run the command for SSH cloning given above, and the repository will appear as a folder in your IDE.

img

Figure 3 - Example of git cloning in IntelliJ IDEA

Building the application

With an IDE

Locate where you downloaded the git repository folder "systemutviklingTeam6" and in your IDE, select open, and navigate to that folder.

To build the application, first, open the "systemutviklingTeam6" folder. Then, navigate to the "helpmehelpapplication" folder, and right-click the "pom.xml" file. From the context menu that pops up, select "Add as Maven Project". This will automatically download all the necessary dependencies for the application and make it ready to be built into a ".jar" file for running the application.

img

Figure 4 - Resolving dependencies in IntelliJ IDEA

From here, to build the application and run it, you can type into your IDE terminal:

mvn clean javafx:run

and the application will build and then start.

Without an IDE

Locate where you downloaded the git repository folder "systemutviklingTeam6", and open a command prompt or terminal window, depending on your operation system. Then, navigate to the subfolder "helpmehelpapplication" (the folder that contains a "pom.xml"-file). When your command promp/terminal is in the correct location, run the command:

mvn clean javafx:run

and the application should start shortly after.

img

Figure 5 - Example of running the application from command prompt in windows 11]

Troubleshooting

Before trying any of these fixes, try reinstalling the prerequisites and restarting your computer to see if that fixes your issue.

Command not recognized

If commands such as "java", "mvn", and "git" are not recognized:

  • Ensure that you followed the installation instructions of the prerequisites carefully

  • Make sure that that the "bin" folder of java, maven, and git, has been successfully added to your system PATH

Incorrect Java version

  • Ensure Java 25 is installed

  • Check that JAVA_HOME points to the correct installation

  • Verify your PATH prioritizes the correct Java version

Maven not resolving dependencies

  • Reload the project, restart IDE or exit the command prompt/terminal and try again

  • Check that you have an active, working internet connection

  • Invalidate the cache of the IDE

Checking PATH/JAVA_HOME

Windows

Push the windows key, then search: "environment variables", and click "edit environment variables", and make sure that in the row starting with "PATH", that the folder path to your installation of java, maven, and git, are present. Also make sure that the row starting with "JAVA_HOME" points to your java installation (should not end in a "bin" folder).

MacOS

Open a terminal and run the command "which java", then "which maven", then "which git". You should get a folder structure output for each of these. If any of these commands return a blank output, the given prerequisite is not correctly set up in your PATH variable.

Linux

Open a terminal and type the commands:

command -v java

command -v mvn

command -v git

If one of these fails, then there is an issue with PATH.

Fixing PATH/JAVA_HOME

Be very careful when editing PATH. Only edit if reinstalling does not work! Make sure that the commands you enter are correct! Restart your command prompt/terminal/IDE after updating environment variables.

Windows

Find your PATH variable, click edit, click new, then add the path to the "bin" folder of the prerequisite. Find your JAVA_HOME variable (if it does not exist, click new, and under "variable name" write JAVA_HOME), click edit, and add the path to your java installation as the value.

MacOS

Open a terminal and run the command:

export PATH="pathToBin":$PATH

where "pathToBin" is the path to the "bin" folder of the prerequisite, quotations marks should be included. For java, you also need to set "JAVA_HOME":

export JAVA_HOME=$("pathToBin")

here not including the quotation marks.

Linux

To fix PATH issues, run the command:

export PATH="pathToBin":$PATH

where "pathToBin" is the path to the bin folder of the prerequisite, not including quotation marks in the command. For java you also need to set JAVA_HOME. If you successfully added java to PATH, you can run the command:

export JAVA_HOME=$(dirname $(readlink -f $(command -v java))))

and it will fix your JAVA_HOME path for the terminal session. For a permanent fix, you must add JAVA_HOME and PATH to your ".bashrc" file.

Clone this wiki locally