Compare commits

..

4 Commits

Author SHA1 Message Date
rattatwinko
1c90605f0b logo on the old branch! 2025-05-21 19:22:29 +02:00
ZockerKatze
84d55c546e readme.md update ; info to how cicd works with long tasks / how long it takes see #Comment on Compile Times with CI/CD! 2025-05-15 10:04:16 +02:00
rattatwinko
50c38e5f97 Merge remote-tracking branch 'origin/master'
# Conflicts:
#	pommer/pommer.py
2025-05-13 16:29:44 +02:00
rattatwinko
2c81e58e7a update the "info up top of the file" 2025-05-13 16:29:18 +02:00
3 changed files with 62 additions and 29 deletions

BIN
logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 95 KiB

View File

@@ -1,11 +1,21 @@
#!/usr/bin/env python3 #!/usr/bin/env python3
""" """
POMMER.PY
THIS IS PROPRIETARY SOFTWARE DO NOT DISTRIBUTE TO OUTSIDERS!
This Python File is distributed with every Kotlin Plugin Repository!
If you find this to be confusing to use look at the Documentation in "rattatwinko/pommer"
Run this Script with Python 3.11 ; 3.9
This YET only works with Maven!
This Python File is proprietary software
""" """
import os import os
import xml.etree.ElementTree as ET import xml.etree.ElementTree as ET
import re import re

View File

@@ -1,28 +1,35 @@
# Pommer 🍟 <div style="text-align: center;">
<img src="logo.png" alt="logo image" height="50">
</div>
**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 **Maven**. It scans your project for `pom.xml` files, analyzes project metadata, and generates a Gitea CI workflow along with a local build script for convenience.
> ⚙️ **This is the stable, Maven-only branch.**
> For Gradle support, switch to the `master` 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 the local Gitea Instance only. Do not distribute or share externally.**
--- ---
## Features ## Features
- **Automatic discovery** of all `pom.xml` files in a repository. * 🔍 **Automatic discovery** of Maven projects (`pom.xml`)
- **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 Maven setups
- **Creates a local `build.sh` script** for convenience. * 🧪 **Creates a `build.sh` script** for local Maven testing
- **Configurable**: Target a specific directory or POM file. * 🎯 **Configurable**: Target a specific directory or file
--- ---
## 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
@@ -30,18 +37,21 @@ 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` | Path to a specific `pom.xml` file |
#### 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 POM file:
```bash ```bash
python3 pommer.py --specific-pom path/to/pom.xml python3 pommer.py --specific-pom path/to/pom.xml
``` ```
@@ -50,39 +60,52 @@ 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 Maven projects.
- **Build Script:** * 🔧 **Build Script:**
`build.sh` `build.sh`
Simple script for local Maven builds. Local script to build all Maven projects easily.
![](img.png) ---
## ⚡ CI/CD Compile Time Notice
> ⚠️ **Slow compile or stuck builds?**
>
> * **Installing JDK** and setting up the runner can take time.
> * If its stuck on **"Downloading JDK 21"**, be patient and **check network usage**.
> * **No activity?** → Restart the runner.
> * Final build steps are **slow but usually fine**.
> * **Local builds slow?** → Expect slower CI/CD times.
--- ---
## 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. * This branch **only supports Maven**.
- Kotlin support is detected automatically. * For Gradle support, use the `gradle-support` branch.
- For internal CI/CD use only. * Java/Kotlin usage is detected automatically.
* The workflow uses the **highest JDK version** found.
--- ---
## Support ## Support
For questions or issues, contact [Internal Team/Contact Person]. Contact **rattatwinko** for help or feature requests.
--- ---
## License ## License
**Internal Use Only Not for Distribution** **Internal Use Only Not for Distribution**
More details are in pommer.py