Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 0 additions & 18 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -152,18 +152,9 @@ jobs:
distribution: temurin
java-version: 11
cache: 'maven'
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
server-password: MAVEN_CENTRAL_TOKEN # env variable for token in deploy
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Create Jars
run: mvn "-DmavenSkipMain=true" --file ./src/jvm/netpdf/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Compile command line
run: dotnet build --no-incremental --configuration Release /p:Platform="Any CPU" /p:NoWarn="0108%3B1030%3B0618" src\net\NetPDFCLI\NetPDFCLI.csproj
Expand Down Expand Up @@ -238,18 +229,9 @@ jobs:
distribution: temurin
java-version: 11
cache: 'maven'
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
server-password: MAVEN_CENTRAL_TOKEN # env variable for token in deploy
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Create Jars
run: mvn "-DmavenSkipMain=true" --file ./src/jvm/netpdf/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v3
Expand Down
9 changes: 0 additions & 9 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,18 +44,9 @@ jobs:
distribution: temurin
java-version: 11
cache: 'maven'
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
server-password: MAVEN_CENTRAL_TOKEN # env variable for token in deploy
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Create Jars
run: mvn --file ./src/jvm/netpdf/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v3
Expand Down
17 changes: 2 additions & 15 deletions .github/workflows/generateclasses.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
DOTNET_EnableCrashReport: 1
JCOBRIDGE_LicensePath: ${{ secrets.JCOBRIDGE_ENCODED_2_6_5 }}
JNet_Version: 2.6.5
PDFBox_Version: 3.0.6
PDFBox_Version: 3.0.7
FONTCACHE_FOLDER: ${{ github.workspace }}\fontcache

# Steps represent a sequence of tasks that will be executed as part of the job
Expand Down Expand Up @@ -81,24 +81,15 @@ jobs:
distribution: temurin
java-version: 11
cache: 'maven'
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
server-password: MAVEN_CENTRAL_TOKEN # env variable for token in deploy
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Create Jars
run: mvn "-DmavenSkipMain=true" --file ./src/jvm/netpdf/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Clear C# generated files
run: Remove-Item .\src\net\NetPDF\Generated\* -Recurse -Force -Exclude README.md

- name: Clear Java generated files
run: Remove-Item .\src\jvm\netpdf\src\main\java\org\mases\netpdf\generated\* -Recurse -Force -Exclude README.md
run: Remove-Item .\src\jvm\netpdf\src\main\java\org\mases\netpdf\generated\* -Recurse -Force -Exclude README.md,.editorconfig

- name: Get last workflow run of JNet
if: ${{ inputs.UseLastRepositoryBuild == true }}
Expand Down Expand Up @@ -130,10 +121,6 @@ jobs:
- name: Create Jars of JNetReflector
if: ${{ inputs.UseLatestJNetReflectorSource == true }}
run: mvn "-Djcobridgepath=../../../binReflector/net8.0/JCOBridge.jar" --file ./JNet/src/jvm/jnet/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Build JNetReflector
if: ${{ inputs.UseLatestJNetReflectorSource == true }}
Expand Down
18 changes: 0 additions & 18 deletions .github/workflows/pullrequest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -90,18 +90,9 @@ jobs:
distribution: temurin
java-version: 11
cache: 'maven'
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
server-password: MAVEN_CENTRAL_TOKEN # env variable for token in deploy
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Create Jars
run: mvn "-DmavenSkipMain=true" --file ./src/jvm/netpdf/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Build Docker Image
run: docker build -t netpdf -f ./src/container/Dockerfile.linux .
Expand Down Expand Up @@ -145,18 +136,9 @@ jobs:
distribution: temurin
java-version: 11
cache: 'maven'
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
server-password: MAVEN_CENTRAL_TOKEN # env variable for token in deploy
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Create Jars
run: mvn "-DmavenSkipMain=true" --file ./src/jvm/netpdf/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Compile command line
run: dotnet build --no-incremental --configuration Release /p:Platform="Any CPU" /p:NoWarn="0108%3B1030%3B0618" src\net\NetPDFCLI\NetPDFCLI.csproj
Expand Down
9 changes: 0 additions & 9 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,9 @@ jobs:
distribution: temurin
java-version: 11
cache: 'maven'
server-id: ossrh # Value of the distributionManagement/repository/id field of the pom.xml
server-username: MAVEN_USERNAME # env variable for username in deploy
server-password: MAVEN_CENTRAL_TOKEN # env variable for token in deploy
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import
gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase

- name: Create Jars
run: mvn --file ./src/jvm/netpdf/pom.xml --no-transfer-progress package
env:
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

- name: Compile NetPDF CLI
run: dotnet build --no-incremental --configuration Release /p:Platform="Any CPU" /p:NoWarn="0108%3B1030%3B0618" src\net\NetPDFCLI\NetPDFCLI.csproj
Expand Down
68 changes: 68 additions & 0 deletions .github/workflows/update_version.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# This is a basic workflow to help you get started with Actions

name: "Change version"

# Controls when the action will run. Triggers the workflow on push
# events but only for the master branch
on:
workflow_dispatch:
inputs:
CurrentVersion:
description: 'The current version'
required: true
type: string
PreReleaseCurrentVersion:
description: 'The current version pre-release tag'
required: false
type: string
NewVersion:
description: 'The new version'
required: true
type: string
PreReleaseNewVersion:
description: 'The new version pre-release tag'
required: false
type: string

# This workflow contains one job called "build_documentation"
jobs:
update_version:
# The type of runner that the job will run on
runs-on: windows-2022

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Runs a set of commands using the runners shell
# Support longpaths
- name: Support long paths
run: git config --system core.longpaths true

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v6
with:
fetch-depth: '1'

- run: (Get-Content ${{ github.workspace }}\src\jvm\netpdf\pom.xml).Replace('<netpdfversion>${{ inputs.CurrentVersion }}.0</netpdfversion>', '<netpdfversion>${{ inputs.NewVersion }}.0</netpdfversion>') | Set-Content ${{ github.workspace }}\src\jvm\netpdf\pom.xml

- run: (Get-Content ${{ github.workspace }}\src\net\Common\Common.props).Replace('<Version>${{ inputs.CurrentVersion }}.0${{ inputs.PreReleaseCurrentVersion }}</Version>', '<Version>${{ inputs.NewVersion }}.0${{ inputs.PreReleaseNewVersion }}</Version>') | Set-Content ${{ github.workspace }}\src\net\Common\Common.props

- run: (Get-Content ${{ github.workspace }}\src\net\NetPDFCLI\NetPDFCLI.nuspec).Replace('<version>${{ inputs.CurrentVersion }}${{ inputs.PreReleaseCurrentVersion }}</version>', '<version>${{ inputs.NewVersion }}${{ inputs.PreReleaseNewVersion }}</version>') | Set-Content ${{ github.workspace }}\src\net\NetPDFCLI\NetPDFCLI.nuspec

- run: (Get-Content ${{ github.workspace }}\src\net\NetPDFPS\MASES.NetPDFPS.psd1).Replace('${{ inputs.CurrentVersion }}${{ inputs.PreReleaseCurrentVersion }}', '${{ inputs.NewVersion }}${{ inputs.PreReleaseNewVersion }}') | Set-Content ${{ github.workspace }}\src\net\NetPDFPS\MASES.NetPDFPS.psd1
- run: (Get-Content ${{ github.workspace }}\src\net\NetPDFPS\MASES.NetPDFPSCore.psd1).Replace('${{ inputs.CurrentVersion }}${{ inputs.PreReleaseCurrentVersion }}', '${{ inputs.NewVersion }}${{ inputs.PreReleaseNewVersion }}') | Set-Content ${{ github.workspace }}\src\net\NetPDFPS\MASES.NetPDFPSCore.psd1
- run: (Get-Content ${{ github.workspace }}\src\net\NetPDFPS\MASES.NetPDFPSFramework.psd1).Replace('${{ inputs.CurrentVersion }}${{ inputs.PreReleaseCurrentVersion }}', '${{ inputs.NewVersion }}${{ inputs.PreReleaseNewVersion }}') | Set-Content ${{ github.workspace }}\src\net\NetPDFPS\MASES.NetPDFPSFramework.psd1

- run: (Get-Content ${{ github.workspace }}\src\net\templates\templates\netpdfApp\netpdfApp.csproj).Replace('${{ inputs.CurrentVersion }}${{ inputs.PreReleaseCurrentVersion }}', '${{ inputs.NewVersion }}${{ inputs.PreReleaseNewVersion }}') | Set-Content ${{ github.workspace }}\src\net\templates\templates\netpdfApp\netpdfApp.csproj

- name: Request a PR to commit changes
uses: peter-evans/create-pull-request@v8
with:
branch-suffix: short-commit-hash
add-paths: src/*.*
commit-message: Update version from ${{ inputs.CurrentVersion }}${{ inputs.PreReleaseCurrentVersion }} to ${{ inputs.NewVersion }}${{ inputs.PreReleaseNewVersion }}
title: Update version from ${{ inputs.CurrentVersion }}${{ inputs.PreReleaseCurrentVersion }} to ${{ inputs.NewVersion }}${{ inputs.PreReleaseNewVersion }}
body: |
Automated changes by GitHub action fix #47
reviewers: masesdevelopers
assignees: masesdevelopers
labels: enhancement, Docker, java, NetPDF, NetPDF CLI, NetPDF PowerShell, NetPDF Template, .NET
2 changes: 1 addition & 1 deletion src/jvm/netpdf/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
<classpathfile>${basedir}/classpathfile.classpath</classpathfile>
<mavenSkipMain>false</mavenSkipMain> <!-- set mavenSkipMain to true to avoid source compilation: use directive in command-line -->
<jnetVersion>2.6.5.0</jnetVersion>
<pdfBoxVersion>3.0.6</pdfBoxVersion>
<pdfBoxVersion>3.0.7</pdfBoxVersion>
<netpdfversion>3.0.9.0</netpdfversion>
<rootDir>${basedir}/../../../</rootDir>
<jcobridgepath>${rootDir}/bin/net8.0/JCOBridge.jar</jcobridgepath>
Expand Down
6 changes: 6 additions & 0 deletions src/net/NetPDF/Generated/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[*.cs]
generated_code = true
dotnet_analyzer_diagnostic.severity = none
dotnet_diagnostic.CS0108.severity = none
dotnet_diagnostic.CS0419.severity = none
dotnet_diagnostic.CS1574.severity = none
Loading