Skip to content

Commit

Permalink
Merge pull request #2 from ingrammicro-xvantage/tweak-workflow
Browse files Browse the repository at this point in the history
Adding package details in readme
  • Loading branch information
im-pradeep committed Jan 23, 2024
2 parents efaf306 + 775a55d commit d554bfe
Show file tree
Hide file tree
Showing 4 changed files with 72 additions and 16 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,18 @@ name: Java CI with Maven

on:
push:
branches: [ main, master ]

branches: [ main ]
pull_request:
branches: [ main, master ]
branches: [ main]

jobs:
build:
name: Build Reseller API
runs-on: ubuntu-latest
strategy:
matrix:
java: [ '8' ]
java: [ '8', '11', '17' ]
steps:
- uses: actions/checkout@v2
- name: Set up JDK
Expand Down
40 changes: 40 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Java Package Publishing
on:
workflow_dispatch:
inputs:
version:
description: 'Enter the new version for the package'
required: true
jobs:
build:
name: Build Reseller API
runs-on: ubuntu-latest
strategy:
matrix:
java: ['17']
steps:
- uses: actions/checkout@v2
- name: Set up JDK
uses: actions/setup-java@v2
with:
java-version: ${{ matrix.java }}
distribution: 'temurin'
cache: maven

- name: Update Version
run: |
NEW_VERSION="${{ github.event.inputs.version }}"
mvn versions:set -DnewVersion=${NEW_VERSION}
git config --global user.email ${{secrets.ADMIN_EMAIL}}
git config --global user.name ${{secrets.ORG_NAME}}
git add .
git commit -m "Bump version to ${{ github.event.inputs.version }}"
git push https://${{secrets.WORKFLOW_TOKEN}}@github.com/ingrammicro-xvantage/xi-sdk-resellers-java main
- name: Build with Maven
run: mvn -B package --no-transfer-progress --file pom.xml

- name: Publish Package
run: mvn --batch-mode clean deploy
env:
GITHUB_TOKEN: ${{ secrets.WORKFLOW_TOKEN}}
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ Add this dependency to your project's POM:
<dependency>
<groupId>xi.sdk.resellers</groupId>
<artifactId>xi.sdk.resellers</artifactId>
<version>6.0</version>
<version>1.0.0</version>
<scope>compile</scope>
</dependency>
```
Expand Down Expand Up @@ -513,6 +513,14 @@ Authentication schemes defined for the API:
It's recommended to create an instance of `ApiClient` per thread in a multithreaded environment to avoid any potential issues.

## Author
-[Ingram Micro Xvantage](https://github.com/ingrammicro-xvantage)

## Contact

For any inquiries or support, please feel free to contact us at:

- Email: [[email protected]]([email protected])




31 changes: 19 additions & 12 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,36 @@
<artifactId>xi.sdk.resellers</artifactId>
<packaging>jar</packaging>
<name>xi.sdk.resellers</name>
<version>6.0</version>
<url>https://github.com/openapitools/openapi-generator</url>
<description>OpenAPI Java</description>
<version>1.0.0</version>
<url>https://github.com/ingrammicro-xvantage/xi-sdk-resellers-java</url>
<distributionManagement>
<repository>
<id>github</id>
<name>GitHub Packages</name>
<url>https://maven.pkg.github.com/ingrammicro-xvantage/xi-sdk-resellers-java</url>
</repository>
</distributionManagement>
<description>Ingram Micro - Xvantage Integration (XI) Java Server-side SDK.</description>
<scm>
<connection>scm:git:[email protected]:openapitools/openapi-generator.git</connection>
<developerConnection>scm:git:[email protected]:openapitools/openapi-generator.git</developerConnection>
<url>https://github.com/openapitools/openapi-generator</url>
<connection>scm:git:[email protected]:ingrammicro-xvantage/xi-sdk-resellers-java.git</connection>
<developerConnection>scm:git:[email protected]:ingrammicro-xvantage/xi-sdk-resellers-java.git</developerConnection>
<url>https://github.com/ingrammicro-xvantage/xi-sdk-resellers-java</url>
</scm>

<licenses>
<license>
<name>Unlicense</name>
<url>http://unlicense.org</url>
<name>MIT</name>
<url>https://github.com/ingrammicro-xvantage/xi-sdk-resellers-java/blob/main/LICENSE</url>
<distribution>repo</distribution>
</license>
</licenses>

<developers>
<developer>
<name>OpenAPI-Generator Contributors</name>
<email>[email protected]</email>
<organization>OpenAPITools.org</organization>
<organizationUrl>http://openapitools.org</organizationUrl>
<name>Ingram Micro Xvantage Intergration(XI)</name>
<email>[email protected]</email>
<organization>Ingram Micro</organization>
<organizationUrl>https://developer.ingrammicro.com/reseller</organizationUrl>
</developer>
</developers>

Expand Down

0 comments on commit d554bfe

Please sign in to comment.