readme.md updated to fit

This commit is contained in:
2025-05-20 14:40:19 +02:00
parent aa5349f704
commit cc2fa8d1d6

View File

@@ -1,29 +1,31 @@
# Pommer 🍟 # Pommer 🍟
**Pommer** is an internal Python tool designed to streamline CI workflow generation for Java/Kotlin Maven projects. It scans for `pom.xml` files, analyzes project metadata, and generates a Gitea CI workflow along with a local build script. **Pommer** is an internal Python tool designed to streamline CI workflow generation for **Java/Kotlin projects** using **Gradle**. It scans your project for build files, analyzes project metadata, and generates a Gitea CI workflow along with a local build script for convenience.
> 🛠️ **Now supports Gradle!**
> The **Maven-compatible version** is maintained on a separate Git branch.
--- ---
## ⚠️ Internal Use Only ## ⚠️ Internal Use Only
> **This tool is for internal use within Gitea only. Do not distribute or share to outsiders.** > **This tool is for internal use within Gitea only. Do not distribute or share externally.**
--- ---
## Features ## Features
- **Automatic discovery** of all `pom.xml` files in a repository. * 🔍 **Automatic discovery** of Gradle (`build.gradle` / `build.gradle.kts`) and Maven (`pom.xml`) projects.
- **Parses project metadata** (artifactId, groupId, version, Java/Kotlin detection, etc.). * 📦 **Parses project metadata** (artifact ID, group ID, version, Java/Kotlin usage, etc.).
- **Generates a Gitea CI workflow** compatible with multi-module Maven projects. * 🏗️ **Generates a Gitea CI workflow**, compatible with multi-module projects.
- **Creates a local `build.sh` script** for convenience. * 🧪 **Creates a `build.sh` script** for local testing and development.
- **Configurable**: Target a specific directory or POM file. * 🎯 **Configurable**: Target a specific directory or file to process.
--- ---
## Usage ## Usage
No installation required. Run directly with Python 3. No installation required. Just run with Python 3:
```bash ```bash
python3 pommer.py python3 pommer.py
@@ -32,17 +34,20 @@ python3 pommer.py
### Options ### Options
| Option | Description | | Option | Description |
|------------------------|-------------------------------------------------------------| | ----------------------------------------------------------------------------------- | -------------------------------------------------- |
| `-d`, `--dir` | Base directory to scan for `pom.xml` files (default: `.`) | | `-d`, `--dir` | Base directory to scan (default: `.`) |
| `-p`, `--specific-pom` | Path to a specific `pom.xml` file to process | | `-p`, `--specific-pom` | (For Maven only) Path to a specific `pom.xml` file |
| *Gradle projects are detected automatically by presence of `build.gradle`/*`kts`*.* | |
#### Examples #### Examples
- Scan a specific directory: * Scan a specific directory:
```bash ```bash
python3 pommer.py --dir path/to/project python3 pommer.py --dir path/to/project
``` ```
- Use a specific POM file: * Use a specific Maven POM file (legacy mode):
```bash ```bash
python3 pommer.py --specific-pom path/to/pom.xml python3 pommer.py --specific-pom path/to/pom.xml
``` ```
@@ -51,42 +56,47 @@ python3 pommer.py
## Output ## Output
- **Gitea Workflow:** * 📄 **Gitea Workflow:**
`.gitea/workflows/maven_build.yaml` `.gitea/workflows/build.yaml`
Automates build and artifact upload for all detected Maven projects. Automates build and artifact upload for all detected Gradle (and Maven, if applicable) projects.
- **Build Script:** * 🔧 **Build Script:**
`build.sh` `build.sh`
Simple script for local Maven builds. Simple, local script to build all projects using Gradle or Maven, as detected.
![](img.png) ---
### _**Comment on Compile Times with CI/CD :**_ ## ⚡ CI/CD Compile Time Notice
_Currently installing **JDK** and finishing up the **Proccess** takes ages! If it is **stuck** on **"Downloading JDK 21"** for a few minutes just **wait**. If you arent sure if its actually doing stuff ; **check the Network Usage of the Server**. If it is **0** for a long time then **restart the Runner!** Finishing up also takes ages ; but that **usually doesn't get stuck** as often. But if just **reboot**!_ > ⚠️ **Slow compile or stuck builds?**
>
_**For big Projects it might take a while** ; if compiling via Maven on your local Instance takes ages ; **it will take even longer on Gitea CI/CD!**_ > * **Installing JDK** and setting up the runner can take a while.
> * If it seems stuck on **"Downloading JDK 21"**, be patient and **monitor server network usage**.
> * **No network activity for several minutes?** → Try **restarting the runner**.
> * The **final steps ("finishing up") are slow**, but usually not broken.
> * **Local builds slow?** → Itll be even slower on CI/CD.
--- ---
## Requirements ## Requirements
- Python 3.7+ * Python 3.7+
- Only standard Python libraries required * No third-party dependencies (standard library only)
--- ---
## Notes ## Notes
- The workflow uses the highest Java version detected among all modules. * Gradle is now the primary build system supported.
- Kotlin support is detected automatically. * Maven support is preserved in the legacy branch.
- For internal CI/CD use only. * Java/Kotlin support is detected automatically across modules.
* The workflow always uses the **highest JDK version** found in the project tree.
--- ---
## Support ## Support
For questions or issues, contact [Internal Team/Contact Person]. Contact rattatwinko help or feature requests.
--- ---