Skip to content

Commit 71e7aa1

Browse files
committed
Plugin init
0 parents  commit 71e7aa1

File tree

13 files changed

+377
-0
lines changed

13 files changed

+377
-0
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* @jenkinsci/oras-java-api-plugin-developers

.github/dependabot.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuring-dependabot-version-updates
2+
3+
version: 2
4+
updates:
5+
- package-ecosystem: maven
6+
directory: /
7+
schedule:
8+
interval: monthly
9+
- package-ecosystem: github-actions
10+
directory: /
11+
schedule:
12+
interval: monthly

.github/workflows/cd.yaml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# Note: additional setup is required, see https://www.jenkins.io/redirect/continuous-delivery-of-plugins
2+
#
3+
# Please find additional hints for individual trigger use case
4+
# configuration options inline this script below.
5+
#
6+
---
7+
name: cd
8+
on:
9+
workflow_dispatch:
10+
inputs:
11+
validate_only:
12+
required: false
13+
type: boolean
14+
description: |
15+
Run validation with release drafter only
16+
→ Skip the release job
17+
# Note: Change this default to true,
18+
# if the checkbox should be checked by default.
19+
default: false
20+
# If you don't want any automatic trigger in general, then
21+
# the following check_run trigger lines should all be commented.
22+
# Note: Consider the use case #2 config for 'validate_only' below
23+
# as an alternative option!
24+
check_run:
25+
types:
26+
- completed
27+
28+
permissions:
29+
checks: read
30+
contents: write
31+
32+
jobs:
33+
maven-cd:
34+
uses: jenkins-infra/github-reusable-workflows/.github/workflows/maven-cd.yml@v1
35+
with:
36+
# Comment / uncomment the validate_only config appropriate to your preference:
37+
#
38+
# Use case #1 (automatic release):
39+
# - Let any successful Jenkins build trigger another release,
40+
# if there are merged pull requests of interest
41+
# - Perform a validation only run with drafting a release note,
42+
# if manually triggered AND inputs.validate_only has been checked.
43+
#
44+
validate_only: ${{ inputs.validate_only == true }}
45+
#
46+
# Alternative use case #2 (no automatic release):
47+
# - Same as use case #1 - but:
48+
# - Let any check_run trigger a validate_only run.
49+
# => enforce the release job to be skipped.
50+
#
51+
#validate_only: ${{ inputs.validate_only == true || github.event_name == 'check_run' }}
52+
secrets:
53+
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
54+
MAVEN_TOKEN: ${{ secrets.MAVEN_TOKEN }}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# More information about the Jenkins security scan can be found at the developer docs: https://www.jenkins.io/redirect/jenkins-security-scan/
2+
3+
name: Jenkins Security Scan
4+
on:
5+
push:
6+
branches:
7+
- "main"
8+
pull_request:
9+
types: [ opened, synchronize, reopened ]
10+
workflow_dispatch:
11+
12+
permissions:
13+
security-events: write
14+
contents: read
15+
actions: read
16+
17+
jobs:
18+
security-scan:
19+
uses: jenkins-infra/jenkins-security-scan/.github/workflows/jenkins-security-scan.yaml@v2
20+
with:
21+
java-cache: 'maven' # Optionally enable use of a build dependency cache. Specify 'maven' or 'gradle' as appropriate.
22+
# java-version: 21 # Optionally specify what version of Java to set up for the build, or remove to use a recent default.

.gitignore

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
target
2+
3+
# mvn hpi:run
4+
work
5+
6+
# IntelliJ IDEA project files
7+
*.iml
8+
*.iws
9+
*.ipr
10+
.idea
11+
12+
# Eclipse project files
13+
.settings
14+
.classpath
15+
.project

.mvn/extensions.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<extensions xmlns="http://maven.apache.org/EXTENSIONS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/EXTENSIONS/1.0.0 https://maven.apache.org/xsd/core-extensions-1.0.0.xsd">
2+
<extension>
3+
<groupId>io.jenkins.tools.incrementals</groupId>
4+
<artifactId>git-changelist-maven-extension</artifactId>
5+
<version>1.8</version>
6+
</extension>
7+
</extensions>

.mvn/maven.config

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
-Pconsume-incrementals
2+
-Pmight-produce-incrementals
3+
-Dchangelist.format=%d.v%s

Jenkinsfile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/*
2+
See the documentation for more options:
3+
https://github.com/jenkins-infra/pipeline-library/
4+
*/
5+
buildPlugin(
6+
forkCount: '1C', // run this number of tests in parallel for faster feedback. If the number terminates with a 'C', the value will be multiplied by the number of available CPU cores
7+
useContainerAgent: true, // Set to `false` if you need to use Docker for containerized tests
8+
configurations: [
9+
[platform: 'linux', jdk: 21],
10+
[platform: 'windows', jdk: 17],
11+
])

LICENSE.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
The MIT License
2+
3+
Copyright 2025
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
6+
7+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
8+
9+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Jenkins ORAS Java SDK API Plugin
2+
3+
[![Build Status](https://ci.jenkins.io/job/Plugins/job/oras-java-api-plugin/job/main/badge/icon)](https://ci.jenkins.io/job/Plugins/job/oras-java-api-plugin/job/main/)
4+
[![Jenkins Plugin](https://img.shields.io/jenkins/plugin/v/oras-java-api.svg)](https://plugins.jenkins.io/oras-java-api)
5+
[![GitHub release](https://img.shields.io/github/release/jenkinsci/oras-java-api-plugin.svg?label=changelog)](https://github.com/jenkinsci/oras-java-api-plugin/releases/latest)
6+
[![GitHub license](https://img.shields.io/github/license/jenkinsci/oras-java-api-plugin)](https://github.com/jenkinsci/oras-java-api-plugin/blob/main/LICENSE.md)
7+
8+
ORAS Java SDK API Plugin
9+
10+
This plugin provides ORAS Java SDK for other plugins (https://github.com/oras-project/oras-java)
11+
12+
# Build
13+
14+
To build the plugin locally:
15+
16+
```
17+
mvn -Dset.changelist clean install
18+
```

0 commit comments

Comments
 (0)