Skip to content

Commit

Permalink
Merge branch 'develop' into update-from-template-merged
Browse files Browse the repository at this point in the history
  • Loading branch information
xdev-gh-bot committed Feb 3, 2025
2 parents 1e97852 + 57fc1d3 commit 9daf3fc
Show file tree
Hide file tree
Showing 26 changed files with 853 additions and 130 deletions.
3 changes: 3 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
custom:
- https://incompetech.com/donate.html
- https://xiph.org/donate
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ body:
attributes:
label: "Checklist"
options:
- label: "I am able to reproduce the bug with the [latest version](https://github.com/xdev-software/template-placeholder/releases/latest)"
- label: "I am able to reproduce the bug with the [latest version](https://github.com/xdev-software/music-maven-plugin/releases/latest)"
required: true
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/template-placeholder/issues) or [closed](https://github.com/xdev-software/template-placeholder/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/music-maven-plugin/issues) or [closed](https://github.com/xdev-software/music-maven-plugin/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
required: true
- label: "I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise."
required: true
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/enhancement.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ body:
attributes:
label: "Checklist"
options:
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/template-placeholder/issues) or [closed](https://github.com/xdev-software/template-placeholder/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/music-maven-plugin/issues) or [closed](https://github.com/xdev-software/music-maven-plugin/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
required: true
- label: "I have taken the time to fill in all the required details. I understand that the feature request will be dismissed otherwise."
required: true
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/question.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ body:
attributes:
label: "Checklist"
options:
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/template-placeholder/issues) or [closed](https://github.com/xdev-software/template-placeholder/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
- label: "I made sure that there are *no existing issues* - [open](https://github.com/xdev-software/music-maven-plugin/issues) or [closed](https://github.com/xdev-software/music-maven-plugin/issues?q=is%3Aissue+is%3Aclosed) - which I could contribute my information to."
required: true
- label: "I have taken the time to fill in all the required details. I understand that the question will be dismissed otherwise."
required: true
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,11 @@ jobs:
## Installation
Add the following lines to your pom:
```XML
<dependency>
<plugin>
<groupId>software.xdev</groupId>
<artifactId>${{ env.PRIMARY_MAVEN_MODULE }}</artifactId>
<version>${{ steps.version.outputs.release }}</version>
</dependency>
</plugin>
```
publish-maven:
Expand Down
16 changes: 0 additions & 16 deletions .run/Run Demo.run.xml

This file was deleted.

32 changes: 32 additions & 0 deletions .run/Run Maven Demo.run.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Run Maven Demo" type="MavenRunConfiguration" factoryName="Maven">
<MavenSettings>
<option name="myGeneralSettings" />
<option name="myRunnerSettings" />
<option name="myRunnerParameters">
<MavenRunnerParameters>
<option name="cmdOptions" />
<option name="profiles">
<set />
</option>
<option name="goals">
<list>
<option value="install" />
</list>
</option>
<option name="multimoduleDir" />
<option name="pomFileName" />
<option name="profilesMap">
<map />
</option>
<option name="projectsCmdOptionValues">
<list />
</option>
<option name="resolveToWorkspace" value="false" />
<option name="workingDirPath" value="$PROJECT_DIR$" />
</MavenRunnerParameters>
</option>
</MavenSettings>
<method v="2" />
</configuration>
</component>
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# 1.0.1
* Updated dependencies

# 1.0.0
_Initial release_
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,10 @@ You should have the following things installed:
* Ensure that the JDK/Java-Version is correct


## Releasing [![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/template-placeholder/release.yml?branch=master)](https://github.com/xdev-software/template-placeholder/actions/workflows/release.yml)
## Releasing [![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/music-maven-plugin/release.yml?branch=master)](https://github.com/xdev-software/music-maven-plugin/actions/workflows/release.yml)

Before releasing:
* Consider doing a [test-deployment](https://github.com/xdev-software/template-placeholder/actions/workflows/test-deploy.yml?query=branch%3Adevelop) before actually releasing.
* Consider doing a [test-deployment](https://github.com/xdev-software/music-maven-plugin/actions/workflows/test-deploy.yml?query=branch%3Adevelop) before actually releasing.
* Check the [changelog](CHANGELOG.md)

If the ``develop`` is ready for release, create a pull request to the ``master``-Branch and merge the changes
Expand Down
89 changes: 83 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,87 @@
[![Latest version](https://img.shields.io/maven-central/v/software.xdev/template-placeholder?logo=apache%20maven)](https://mvnrepository.com/artifact/software.xdev/template-placeholder)
[![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/template-placeholder/check-build.yml?branch=develop)](https://github.com/xdev-software/template-placeholder/actions/workflows/check-build.yml?query=branch%3Adevelop)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=xdev-software_template-placeholder&metric=alert_status)](https://sonarcloud.io/dashboard?id=xdev-software_template-placeholder)
[![Latest version](https://img.shields.io/maven-central/v/software.xdev/music-maven-plugin?logo=apache%20maven)](https://mvnrepository.com/artifact/software.xdev/music-maven-plugin)
[![Build](https://img.shields.io/github/actions/workflow/status/xdev-software/music-maven-plugin/check-build.yml?branch=develop)](https://github.com/xdev-software/music-maven-plugin/actions/workflows/check-build.yml?query=branch%3Adevelop)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=xdev-software_music-maven-plugin&metric=alert_status)](https://sonarcloud.io/dashboard?id=xdev-software_music-maven-plugin)

# template-placeholder
# music-maven-plugin

🎵 Plays some background music while Maven is building.

## Usage

### Basic

The following configuration will play some "elevator" music in the background as soon as Maven starts building:

```xml
<plugin>
<groupId>software.xdev</groupId>
<artifactId>music-maven-plugin</artifactId>
<version>...</version>
<!-- You might also want to add <inherited>false</inherited> so not every child executes this -->
<executions>
<execution>
<phase>validate</phase>
<goals>
<goal>music</goal>
</goals>
</execution>
</executions>
</plugin>
```

### Customizing the music

You can customize the music by adding other sources:

```xml
<configuration>
<sources>
<musicSource>
<uri>https://incompetech.com/music/royalty-free/mp3-royaltyfree/Corncob.mp3</uri>
</musicSource>
<musicSource>
<!-- Relative to project directory -->
<file>my_cool_music.mp3</file>
</musicSource>
<musicSource>
<classpath>/default/Andrew_Codeman_-_03_-_Mussels_short_version.ogg</classpath>
</musicSource>
</sources>
<shuffle>true</shuffle>
</configuration>
```

#### Supported codecs

| Codec | Container |
| --- | --- |
| [MP3](https://en.wikipedia.org/wiki/MP3) | ``.mp3`` |
| [Vorbis](https://en.wikipedia.org/wiki/Vorbis) | [``.ogg``](https://en.wikipedia.org/wiki/Ogg) |

> [!NOTE]
> Container files can also include different codecs.
> For example ``.ogg`` can also contain ``Opus``, ``Speex``, ``FLAC``, ... which are not supported.
> [!TIP]
> If you want to convert to supported formats you can do so with [``ffmpeg``](https://www.ffmpeg.org/):<br/>
> ``ffmpeg -i music.opus music.ogg``
## Installation
[Installation guide for the latest release](https://github.com/xdev-software/template-placeholder/releases/latest#Installation)
[Installation guide for the latest release](https://github.com/xdev-software/music-maven-plugin/releases/latest#Installation)

## Run the demo

> [!WARNING]
> Might be loud!
* Checkout the repo
* Run ``mvn install``

## Why?
This is obviously a joke/fun plugin.<br/>
You probably shouldn't use it in production or maybe only on April 1st to annoy your colleagues :P

We got the idea during XDEV's christmas party as [rfichtner](https://github.com/rfichtner) always needs more plugins for funnier Maven presentations and was inspired by [this GraalVM issue from joshlong](https://github.com/oracle/graal/issues/5327).

## Support
If you need support as soon as possible and you can't wait for any pull request, feel free to use [our support](https://xdev.software/en/services/support).
Expand All @@ -15,4 +90,6 @@ If you need support as soon as possible and you can't wait for any pull request,
See the [contributing guide](./CONTRIBUTING.md) for detailed instructions on how to get started with our project.

## Dependencies and Licenses
View the [license of the current project](LICENSE) or the [summary including all dependencies](https://xdev-software.github.io/template-placeholder/dependencies)
View the [license of the current project](LICENSE) or the [summary including all dependencies](https://xdev-software.github.io/music-maven-plugin/dependencies)

The license and download information for the [built-in music](./music-maven-plugin/src/main/resources/default/) can be found in [sources.txt](./music-maven-plugin/src/main/resources/default/sources.txt).
2 changes: 1 addition & 1 deletion SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

## Reporting a Vulnerability

Please report a security vulnerability [on GitHub Security Advisories](https://github.com/xdev-software/template-placeholder/security/advisories/new).
Please report a security vulnerability [on GitHub Security Advisories](https://github.com/xdev-software/music-maven-plugin/security/advisories/new).
132 changes: 132 additions & 0 deletions music-maven-plugin-demo/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>software.xdev</groupId>
<artifactId>music-maven-plugin-root</artifactId>
<version>1.0.2-SNAPSHOT</version>
</parent>

<artifactId>music-maven-plugin-demo</artifactId>
<version>1.0.2-SNAPSHOT</version>
<packaging>jar</packaging>

<organization>
<name>XDEV Software</name>
<url>https://xdev.software</url>
</organization>

<properties>
<javaVersion>17</javaVersion>
<maven.compiler.release>${javaVersion}</maven.compiler.release>

<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

<mainClass>software.xdev.Application</mainClass>
</properties>

<build>
<finalName>${project.artifactId}</finalName>

<plugins>
<plugin>
<groupId>software.xdev</groupId>
<artifactId>music-maven-plugin</artifactId>
<version>${project.version}</version>
<executions>
<execution>
<id>1-elevator</id>
<phase>validate</phase>
<goals>
<goal>music</goal>
</goals>
</execution>
<execution>
<id>2-shuffle</id>
<phase>prepare-package</phase>
<goals>
<goal>music</goal>
</goals>
<configuration>
<sources>
<musicSource>
<uri>https://incompetech.com/music/royalty-free/mp3-royaltyfree/Corncob.mp3</uri>
</musicSource>
<musicSource>
<classpath>/default/Andrew_Codeman_-_03_-_Mussels_short_version.ogg</classpath>
</musicSource>
</sources>
<shuffle>true</shuffle>
</configuration>
</execution>
<execution>
<id>3-finished</id>
<phase>package</phase>
<goals>
<goal>music</goal>
</goals>
<configuration>
<sources>
<musicSource>
<classpath>/default/First_Call.ogg</classpath>
<volumeDB>-15</volumeDB>
</musicSource>
</sources>
<!-- blocking -->
<background>false</background>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>3.5.0</version>
<executions>
<execution>
<id>1</id>
<phase>process-classes</phase>
<goals>
<goal>java</goal>
</goals>
<configuration>
<arguments>
<argument>5000</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>2</id>
<phase>prepare-package</phase>
<goals>
<goal>java</goal>
</goals>
<configuration>
<arguments>
<argument>5000</argument>
</arguments>
</configuration>
</execution>
</executions>
<configuration>
<mainClass>${mainClass}</mainClass>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.13.0</version>
<configuration>
<release>${maven.compiler.release}</release>
<compilerArgs>
<arg>-proc:none</arg>
</compilerArgs>
</configuration>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package software.xdev;

public final class Application
{
public static void main(final String[] args) throws InterruptedException
{
if(args.length > 0)
{
Thread.sleep(Integer.parseInt(args[0]));
}
}

private Application()
{
}
}
Loading

0 comments on commit 9daf3fc

Please sign in to comment.