dev-guide:getting-started
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| dev-guide:getting-started [2024/06/25 10:51] – [Developer Guide] gaetan | dev-guide:getting-started [2024/12/18 10:54] (current) – [Developer Guide] gaetan | ||
|---|---|---|---|
| Line 5: | Line 5: | ||
| Developing on the GroIMP source code only require a java compiler. Additionally GroIMP support two development setup: Maven and Eclipse. | Developing on the GroIMP source code only require a java compiler. Additionally GroIMP support two development setup: Maven and Eclipse. | ||
| - | - (Optional) **Forking** the official repository to an own one. This is done to be able to commit and push changes. | + | ==== Requirements ==== |
| - | - (Optional) **Mirroring** the fork repository to the official one. This merges updates of the official repository to the fork repository automatically. | + | |
| - | - **Cloning** the fork repository to the local computer (in Eclipse) | + | |
| + | To compile GroIMP you will need the following additional tools: | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | * [[https:// | ||
| + | ===== Get the source code ===== | ||
| - | ==== (Optional) Forking | + | The first step to start developing on the code is to get it. The code is entirely open source and available on [[https:// |
| - | Go to [[https:// | + | The source code is split between the " |
| - | Click on the //Fork// button of the repository. | ||
| - | Select your own gitlab namespace and optionally an other project name (not recommended). | + | ==== (Optional) Forking the repository ==== |
| - | Change or reuse the project slug and description. | + | * Go to the git repository page in your internet browser. |
| - | + | * Click on the //Fork// button of the repository. | |
| - | Click on //Fork project//. | + | * Select your own gitlab namespace and optionally an other project name (not recommended). |
| + | * Change or reuse the project slug and description. | ||
| + | | ||
| ==== (Optional) Mirroring the repository ==== | ==== (Optional) Mirroring the repository ==== | ||
| - | In an internet browser, go to your own repository that forks the official one. | + | * In an internet browser, go to your own repository that forks the official one. |
| - | + | | |
| - | On the side bar, click on // | + | |
| - | + | | |
| - | Expand the category `Mirroring repositories`. | + | |
| - | + | **Note: the two previous steps are optional | |
| - | Insert the URL of the official repository: [[https:// | + | |
| - | + | ||
| - | Click on //Mirror repository// | + | |
| - | + | ||
| - | **Note: the two previous steps are optionals | + | |
| ==== Cloning the repository ==== | ==== Cloning the repository ==== | ||
| - | |||
| === From GitLab === | === From GitLab === | ||
| Line 44: | Line 42: | ||
| It is possible to simply download the directory of source code from GitLab on the main page [[https:// | It is possible to simply download the directory of source code from GitLab on the main page [[https:// | ||
| - | |||
| You can then download the whole repository as any archive format you like. | You can then download the whole repository as any archive format you like. | ||
| - | + | Once it is downloaded, extract the archive to the directory | |
| - | Once it is downloaded, extract the archive to the directory | + | |
| - | + | ||
| - | You still need to import the repository in Eclipse. See two section bellow. | + | |
| === From a bash command === | === From a bash command === | ||
| You can clone a repository from GitLab with the command line: | You can clone a repository from GitLab with the command line: | ||
| - | |||
| < | < | ||
| git clone https:// | git clone https:// | ||
| Line 61: | Line 54: | ||
| This will create a directory named groimp and download all the remote content in it. | This will create a directory named groimp and download all the remote content in it. | ||
| - | You still need to import the repository in Eclipse. See the section bellow. | ||
| - | |||
| - | === Import the repository in Eclipse === | ||
| - | |||
| - | You have the repository with GroIMP source code on your local device. | ||
| - | |||
| - | In Eclipse, click on //File > Import...// | ||
| - | |||
| - | Open the category `Maven`. | ||
| - | |||
| - | Select `Existing Maven Projects`. | ||
| - | |||
| - | Set the Root Directory as the groimp repository you downloaded. | ||
| - | |||
| - | All GroIMP plugins should appear in the projects list. | ||
| - | |||
| - | Click on `Finish`. | ||
| - | |||
| - | === From Eclipse egit === | ||
| - | |||
| - | **Warning: This method sometime lead to error in the code compilation. It is not recommended to use it.** | ||
| - | |||
| - | The git repository can be imported in Eclipse using the eclipse plugin eGit, which is embedded by default in all Eclipse installations. | ||
| - | Click on File > Import… | + | ===== Compile with Maven ===== |
| - | Open the category `Git` | + | Now that you have the source code on your local device, you can compile it with Maven. Maven require '' |
| + | GroIMP core have both a parent pom.xml and a pom.xml for each plugins. Additional plugins only have their pom.xml. | ||
| + | Maven commands are executed from a terminal (bash, Powershell, ...). | ||
| + | Maven commands can be executed either at the project level (on the parent '' | ||
| - | Select Projects from Git | + | The plugins are added with the < |
| - | Select `Clone URI` | + | The most useful maven commands are: |
| - | Insert `git@gitlab.com: | + | * '' |
| + | * '' | ||
| + | * '' | ||
| - | ===== Maven ===== | + | If you package the groimp core code, you will have a '' |
| + | '' | ||
| + | ==== Common errors ==== | ||
| + | The maven commands can fail, here are some common errors: | ||
| + | * '' | ||
| + | * '' | ||
| + | * '' | ||
| ===== Eclipse ===== | ===== Eclipse ===== | ||
| See the guide on how to setup your Eclipse environment [[: | See the guide on how to setup your Eclipse environment [[: | ||
dev-guide/getting-started.1719305497.txt.gz · Last modified: 2024/06/25 10:51 by gaetan
