diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
new file mode 100644
index 0000000..495c83e
--- /dev/null
+++ b/.github/workflows/ci.yml
@@ -0,0 +1,22 @@
+name: JAVA CI
+
+on:
+ push:
+ branches: [ main ]
+ pull_request:
+ branches: [ main ]
+
+jobs:
+ build:
+ runs-on: ubuntu-latest
+
+ steps:
+ - uses: actions/checkout@v3
+ - name: Set up JDK 17
+ uses: actions/setup-java@v3
+ with:
+ java-version: '17'
+ distribution: 'temurin'
+ cache: maven
+ - name: Build with Maven
+ run: mvn -B verify --file pom.xml
diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml
new file mode 100644
index 0000000..fa4f82d
--- /dev/null
+++ b/.github/workflows/publish.yml
@@ -0,0 +1,27 @@
+name: Publish to Maven Central
+
+on:
+ release:
+ types: [created]
+
+jobs:
+ publish:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v3
+ - name: Set up JDK 17
+ uses: actions/setup-java@v3
+ with:
+ java-version: '17'
+ distribution: 'temurin'
+ server-id: central
+ server-username: MAVEN_USERNAME
+ server-password: MAVEN_PASSWORD
+ gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
+ gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }}
+
+ - name: Publish to Maven Central
+ run: mvn -B deploy -P release --file pom.xml
+ env:
+ MAVEN_USERNAME: ${{ secrets.MAVEN_CENTRAL_USERNAME }}
+ MAVEN_PASSWORD: ${{ secrets.MAVEN_CENTRAL_PASSWORD }}
diff --git a/pom.xml b/pom.xml
index ff3f3ee..320916c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -5,7 +5,35 @@
java-preprocessing-lib-parent
pom
1.0.0-SNAPSHOT
+
+
Java Preprocessing Library Parent
+ A lightweight Java library and Maven plugin for C++ style preprocessor directives.
+ https://github.com/tejas-warake/java-preprocessing-lib
+
+
+
+ MIT License
+ http://www.opensource.org/licenses/mit-license.php
+
+
+
+
+
+ Tejas Warake
+ tejaswarake@example.com
+ Open Source
+ https://github.com/tejas-warake
+
+
+
+
+ scm:git:git://github.com/tejas-warake/java-preprocessing-lib.git
+ scm:git:ssh://github.com:tejas-warake/java-preprocessing-lib.git
+ https://github.com/tejas-warake/java-preprocessing-lib/tree/main
+
+
+
preprocessor-core
@@ -18,6 +46,72 @@
1.8
+
+
+
+ org.sonatype.central
+ central-publishing-maven-plugin
+ 0.1.2
+ true
+
+ central
+ true
+ true
+
+
+
+
+
+
+
+ release
+
+
+
+ org.apache.maven.plugins
+ maven-source-plugin
+ 2.2.1
+
+
+ attach-sources
+
+ jar-no-fork
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-javadoc-plugin
+ 2.9.1
+
+
+ attach-javadocs
+
+ jar
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-gpg-plugin
+ 1.5
+
+
+ sign-artifacts
+ verify
+
+ sign
+
+
+
+
+
+
+
+
+