Skip to content

Commit f0526f8

Browse files
authored
Merge branch 'main' into hotfix/URISyntaxException
2 parents dde296d + 79e0fc6 commit f0526f8

124 files changed

Lines changed: 8498 additions & 344 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/dependabot.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,32 @@ updates:
33
- package-ecosystem: "maven"
44
directory: "/"
55
rebase-strategy: "disabled"
6+
target-branch: "main"
7+
open-pull-requests-limit: 10
68
schedule:
79
interval: "monthly"
810
time: "02:00"
911
- package-ecosystem: "github-actions"
1012
directory: "/"
1113
rebase-strategy: "disabled"
14+
target-branch: "main"
15+
open-pull-requests-limit: 10
16+
schedule:
17+
interval: "monthly"
18+
time: "02:00"
19+
- package-ecosystem: "maven"
20+
directory: "/"
21+
rebase-strategy: "disabled"
22+
target-branch: "main-1.x"
23+
open-pull-requests-limit: 10
24+
schedule:
25+
interval: "monthly"
26+
time: "02:00"
27+
- package-ecosystem: "github-actions"
28+
directory: "/"
29+
rebase-strategy: "disabled"
30+
target-branch: "main-1.x"
31+
open-pull-requests-limit: 10
1232
schedule:
1333
interval: "monthly"
1434
time: "02:00"

.github/workflows/codeql-analysis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848
java-version: 17
4949

5050
- name: Checkout repository
51-
uses: actions/checkout@v6
51+
uses: actions/checkout@v7
5252

5353
# Initializes the CodeQL tools for scanning.
5454
- name: Initialize CodeQL

.github/workflows/create_release_tag_and_pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
create_release_tag:
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/checkout@v6
13+
- uses: actions/checkout@v7
1414
with:
1515
fetch-depth: 0
1616

.github/workflows/maven-build.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ on:
44
push:
55
branches:
66
- main
7-
- main-2.x
7+
- main-1.x
88
- '!/refs/heads/dependabot/*'
99
pull_request:
1010
branches:
@@ -25,7 +25,7 @@ jobs:
2525
strategy:
2626
fail-fast: true
2727
steps:
28-
- uses: actions/checkout@v6
28+
- uses: actions/checkout@v7
2929
- name: Set up JDK
3030
uses: actions/setup-java@v5
3131
with:
@@ -47,7 +47,7 @@ jobs:
4747
strategy:
4848
fail-fast: false
4949
steps:
50-
- uses: actions/checkout@v6
50+
- uses: actions/checkout@v7
5151
- name: Set up JDK
5252
uses: actions/setup-java@v5
5353
with:
@@ -68,7 +68,7 @@ jobs:
6868
strategy:
6969
fail-fast: true
7070
steps:
71-
- uses: actions/checkout@v6
71+
- uses: actions/checkout@v7
7272
- name: Set up JDK
7373
uses: actions/setup-java@v5
7474
with:
@@ -90,7 +90,7 @@ jobs:
9090
os: [ ubuntu, windows ]
9191
java: [ 17, 21 ]
9292
steps:
93-
- uses: actions/checkout@v6
93+
- uses: actions/checkout@v7
9494
- name: Set up JDK
9595
uses: actions/setup-java@v5
9696
with:
@@ -120,13 +120,13 @@ jobs:
120120
needs: test
121121
runs-on: ubuntu-latest
122122
steps:
123-
- uses: actions/checkout@v6
123+
- uses: actions/checkout@v7
124124
- uses: actions/download-artifact@v8
125125
with:
126126
name: maven-test-target-directory
127127
path: target
128128
- name: Codecov Report
129-
uses: codecov/codecov-action@v5.5.2
129+
uses: codecov/codecov-action@v7.0.0
130130
with:
131131
# Codecov token from https://app.codecov.io/gh/hub4j/github-api/settings
132132
token: ${{ secrets.CODECOV_TOKEN }}
@@ -138,7 +138,7 @@ jobs:
138138
needs: build
139139
runs-on: ubuntu-latest
140140
steps:
141-
- uses: actions/checkout@v6
141+
- uses: actions/checkout@v7
142142
- uses: actions/download-artifact@v8
143143
with:
144144
name: maven-target-directory

.github/workflows/publish_release_branch.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
build:
1313
runs-on: ubuntu-latest
1414
steps:
15-
- uses: actions/checkout@v6
15+
- uses: actions/checkout@v7
1616
- name: Set up Maven Central Repository
1717
uses: actions/setup-java@v5
1818
with:
@@ -35,7 +35,7 @@ jobs:
3535
runs-on: ubuntu-latest
3636
needs: build
3737
steps:
38-
- uses: actions/checkout@v6
38+
- uses: actions/checkout@v7
3939
- name: Set up Maven Central Repository
4040
uses: actions/setup-java@v5
4141
with:
@@ -69,7 +69,7 @@ jobs:
6969
needs: build
7070
if: ${{ github.ref == 'refs/heads/release/v2.x' }}
7171
steps:
72-
- uses: actions/checkout@v6
72+
- uses: actions/checkout@v7
7373
with:
7474
fetch-depth: 0
7575

.github/workflows/release-drafter.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,6 @@ jobs:
1717
runs-on: ubuntu-latest
1818
steps:
1919
- name: Release Drafter
20-
uses: release-drafter/release-drafter@v6
20+
uses: release-drafter/release-drafter@v7
2121
env:
2222
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

pom.xml

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<modelVersion>4.0.0</modelVersion>
44
<groupId>org.kohsuke</groupId>
55
<artifactId>${github-api.artifactId}</artifactId>
6-
<version>2.0-rc.6-SNAPSHOT</version>
6+
<version>2.0-rc.8-SNAPSHOT</version>
77
<name>GitHub API for Java</name>
88
<description>GitHub API for Java</description>
99
<url>https://hub4j.github.io/github-api/</url>
@@ -75,10 +75,10 @@
7575
<!-- This project was registered before 2021, so it uses the old server. -->
7676
<nexus.serverUrl>https://ossrh-staging-api.central.sonatype.com</nexus.serverUrl>
7777
<okhttp3.version>4.12.0</okhttp3.version>
78-
<okio.version>3.16.0</okio.version>
78+
<okio.version>3.17.0</okio.version>
7979
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
8080
<spotbugs-maven-plugin.failOnError>true</spotbugs-maven-plugin.failOnError>
81-
<spotbugs-maven-plugin.version>4.9.8.2</spotbugs-maven-plugin.version>
81+
<spotbugs-maven-plugin.version>4.9.8.3</spotbugs-maven-plugin.version>
8282
<spotbugs.version>4.8.6</spotbugs.version>
8383
<spring.boot.version>3.4.5</spring.boot.version>
8484
<surefire.argLine></surefire.argLine>
@@ -89,7 +89,7 @@
8989
<dependency>
9090
<groupId>com.fasterxml.jackson</groupId>
9191
<artifactId>jackson-bom</artifactId>
92-
<version>2.21.0</version>
92+
<version>2.21.2</version>
9393
<type>pom</type>
9494
<scope>import</scope>
9595
</dependency>
@@ -103,7 +103,7 @@
103103
<dependency>
104104
<groupId>org.slf4j</groupId>
105105
<artifactId>slf4j-bom</artifactId>
106-
<version>2.0.17</version>
106+
<version>2.0.18</version>
107107
<type>pom</type>
108108
<scope>import</scope>
109109
</dependency>
@@ -194,7 +194,7 @@
194194
<dependency>
195195
<groupId>org.apache.commons</groupId>
196196
<artifactId>commons-lang3</artifactId>
197-
<version>3.19.0</version>
197+
<version>3.20.0</version>
198198
</dependency>
199199
<dependency>
200200
<groupId>com.github.npathai</groupId>
@@ -211,19 +211,19 @@
211211
<dependency>
212212
<groupId>com.google.code.gson</groupId>
213213
<artifactId>gson</artifactId>
214-
<version>2.13.2</version>
214+
<version>2.14.0</version>
215215
<scope>test</scope>
216216
</dependency>
217217
<dependency>
218218
<groupId>com.google.guava</groupId>
219219
<artifactId>guava</artifactId>
220-
<version>33.4.6-jre</version>
220+
<version>33.5.0-jre</version>
221221
<scope>test</scope>
222222
</dependency>
223223
<dependency>
224224
<groupId>com.tngtech.archunit</groupId>
225225
<artifactId>archunit</artifactId>
226-
<version>1.4.1</version>
226+
<version>1.4.2</version>
227227
<scope>test</scope>
228228
</dependency>
229229
<dependency>
@@ -268,7 +268,7 @@
268268
<dependency>
269269
<groupId>org.mockito</groupId>
270270
<artifactId>mockito-core</artifactId>
271-
<version>5.21.0</version>
271+
<version>5.23.0</version>
272272
<scope>test</scope>
273273
</dependency>
274274
<!--
@@ -340,11 +340,11 @@
340340
</plugin>
341341
<plugin>
342342
<artifactId>maven-resources-plugin</artifactId>
343-
<version>3.3.1</version>
343+
<version>3.5.0</version>
344344
</plugin>
345345
<plugin>
346346
<artifactId>maven-source-plugin</artifactId>
347-
<version>3.3.1</version>
347+
<version>3.4.0</version>
348348
</plugin>
349349
<plugin>
350350
<artifactId>maven-surefire-plugin</artifactId>
@@ -357,12 +357,12 @@
357357
<plugin>
358358
<groupId>org.codehaus.mojo</groupId>
359359
<artifactId>versions-maven-plugin</artifactId>
360-
<version>2.18.0</version>
360+
<version>2.21.0</version>
361361
</plugin>
362362
<plugin>
363363
<groupId>org.jacoco</groupId>
364364
<artifactId>jacoco-maven-plugin</artifactId>
365-
<version>0.8.14</version>
365+
<version>0.8.15</version>
366366
<configuration>
367367
<!-- no need to get data about external code. It dramatically reduces performance of JaCoCo for nothing -->
368368
<excludes>
@@ -535,7 +535,7 @@
535535
<plugin>
536536
<groupId>com.github.siom79.japicmp</groupId>
537537
<artifactId>japicmp-maven-plugin</artifactId>
538-
<version>0.23.1</version>
538+
<version>0.26.1</version>
539539
<configuration>
540540
<parameter>
541541
<breakBuildOnBinaryIncompatibleModifications>true</breakBuildOnBinaryIncompatibleModifications>
@@ -585,7 +585,7 @@
585585
</plugin>
586586
<plugin>
587587
<artifactId>maven-compiler-plugin</artifactId>
588-
<version>3.14.0</version>
588+
<version>3.15.0</version>
589589
<configuration>
590590
<source>11</source>
591591
<target>11</target>
@@ -602,7 +602,7 @@
602602
<plugin>
603603
<groupId>org.apache.maven.plugins</groupId>
604604
<artifactId>maven-jar-plugin</artifactId>
605-
<version>3.4.2</version>
605+
<version>3.5.0</version>
606606
<configuration>
607607
<archive>
608608
<manifestEntries>
@@ -626,7 +626,7 @@
626626
<plugin>
627627
<groupId>org.apache.maven.plugins</groupId>
628628
<artifactId>maven-release-plugin</artifactId>
629-
<version>3.1.1</version>
629+
<version>3.3.1</version>
630630
<configuration>
631631
<autoVersionSubmodules>true</autoVersionSubmodules>
632632
<useReleaseProfile>false</useReleaseProfile>
@@ -637,7 +637,7 @@
637637
<plugin>
638638
<groupId>org.apache.maven.plugins</groupId>
639639
<artifactId>maven-site-plugin</artifactId>
640-
<version>3.21.0</version>
640+
<version>3.22.0</version>
641641
</plugin>
642642
<plugin>
643643
<artifactId>maven-surefire-plugin</artifactId>
@@ -683,7 +683,7 @@
683683
<extension>
684684
<groupId>org.apache.maven.scm</groupId>
685685
<artifactId>maven-scm-provider-gitexe</artifactId>
686-
<version>2.1.0</version>
686+
<version>2.2.1</version>
687687
</extension>
688688
<extension>
689689
<groupId>org.apache.maven.scm</groupId>
@@ -904,7 +904,7 @@
904904
<plugin>
905905
<groupId>org.apache.maven.plugins</groupId>
906906
<artifactId>maven-enforcer-plugin</artifactId>
907-
<version>3.5.0</version>
907+
<version>3.6.3</version>
908908
<executions>
909909
<execution>
910910
<id>enforce-jacoco-exist</id>

src/main/java/org/kohsuke/github/GHContent.java

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,34 @@ static String getApiRoute(GHRepository repository, String path) {
5656
public GHContent() {
5757
}
5858

59+
/**
60+
* Creates a builder that can be used to delete this file.
61+
*
62+
* <p>
63+
* Unlike the {@link #delete(String)} convenience methods, this builder supports setting the author and committer of
64+
* the resulting commit.
65+
*
66+
* @return a content deleter
67+
* @see GHContentDeleter
68+
*/
69+
public GHContentDeleter createDelete() {
70+
return new GHContentDeleter(this);
71+
}
72+
73+
/**
74+
* Creates a builder that can be used to update this file's content.
75+
*
76+
* <p>
77+
* Unlike the {@link #update(String, String)} convenience methods, this builder supports setting the author and
78+
* committer of the resulting commit.
79+
*
80+
* @return a content updater
81+
* @see GHContentUpdater
82+
*/
83+
public GHContentUpdater createUpdate() {
84+
return new GHContentUpdater(this);
85+
}
86+
5987
/**
6088
* Delete gh content update response.
6189
*

0 commit comments

Comments
 (0)