Skip to content

Commit

Permalink
Merge branch 'master' into keyboard-shortcut-animation
Browse files Browse the repository at this point in the history
  • Loading branch information
janfaracik authored Sep 16, 2024
2 parents f9fad99 + 2d2adef commit 08a248c
Show file tree
Hide file tree
Showing 99 changed files with 867 additions and 944 deletions.
File renamed without changes.
2 changes: 1 addition & 1 deletion .github/workflows/run-since-updater.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
id: run_script
shell: bash
- name: Create Pull Request
uses: peter-evans/create-pull-request@8867c4aba1b742c39f8d0ba35429c2dfa4b6cb20 # v7
uses: peter-evans/create-pull-request@d121e62763d8cc35b5fb1710e887d6e69a52d3a4 # v7
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: Fill in since annotations
Expand Down
24 changes: 22 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,27 @@ jenkins_*.changes
*.pkg
*.zip
push-build.sh
war/node_modules/
war/yarn-error.log
node_modules/
yarn-error.log
.java-version
.checkstyle

/rebel.xml
junit.xml

# Yarn
# https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored
.pnp.*
.yarn/*
.yarnrc.yml
!.yarn/patches
!.yarn/plugins
!.yarn/sdks
!.yarn/versions

# Node
node/
node_modules/

# Generated JavaScript Bundles
jsbundles
14 changes: 7 additions & 7 deletions war/.prettierignore → .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,19 @@ node/
.yarnrc.yml

# libraries / external deps / generated files
src/main/js/plugin-setup-wizard/bootstrap-detached.js
src/main/webapp/scripts/yui
src/main/webapp/jsbundles/
src/main/scss/_bootstrap.scss
war/src/main/js/plugin-setup-wizard/bootstrap-detached.js
war/src/main/webapp/scripts/yui
war/src/main/webapp/jsbundles/
war/src/main/scss/_bootstrap.scss

# test files that we don't need formatted
../test/src/test/resources
../test/jmh-report.json
test/src/test/resources
test/jmh-report.json

# doesn't work, see https://github.com/prettier/prettier/issues/5340
*.hbs

.yarn

# Incorrectly flagging forwarding slashes in regex
../.github/renovate.json
.github/renovate.json
2 changes: 1 addition & 1 deletion war/.stylelintrc.js → .stylelintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
extends: "stylelint-config-standard",
customSyntax: "postcss-scss",
ignoreFiles: ["src/main/scss/_bootstrap.scss"],
ignoreFiles: ["war/src/main/scss/_bootstrap.scss"],
rules: {
"no-descending-specificity": null,
"selector-class-pattern": "[a-z]",
Expand Down
8 changes: 2 additions & 6 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,12 @@ MAVEN_OPTS='--add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/ja
To run the Yarn frontend build, after [building the WAR file](#building-the-war-file), add the downloaded versions of Node and Yarn to your path:

```sh
export PATH=$PWD/war/node:$PWD/war/node/yarn/dist/bin:$PATH
export PATH=$PWD/node:$PWD/node/yarn/dist/bin:$PATH
```

Then you can run Yarn with e.g.

```sh
cd war
yarn
```

Expand All @@ -75,10 +74,9 @@ On one terminal, start a development server that will not process frontend asset
MAVEN_OPTS='--add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED' mvn -pl war jetty:run -Dskip.yarn
```

On another terminal, move to the `war` folder and start a [webpack](https://webpack.js.org/) dev server, after [adding Node and Yarn to your path](#running-the-yarn-frontend-build):
Open another terminal and start a [webpack](https://webpack.js.org/) dev server, after [adding Node and Yarn to your path](#running-the-yarn-frontend-build):

```sh
cd war
yarn start
```

Expand Down Expand Up @@ -113,14 +111,12 @@ mvn spotless:apply
To view frontend issues, after [adding Node and Yarn to your path](#running-the-yarn-frontend-build), run:

```sh
cd war
yarn lint
```

To fix frontend issues, after [adding Node and Yarn to your path](#running-the-yarn-frontend-build), run:

```sh
cd war
yarn lint:fix
```

Expand Down
2 changes: 1 addition & 1 deletion bom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ THE SOFTWARE.
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-framework-bom</artifactId>
<version>6.1.12</version>
<version>6.1.13</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Expand Down
16 changes: 8 additions & 8 deletions core/src/main/java/hudson/Functions.java
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ public static String addSuffix(int n, String singular, String plural) {
}

/**
* @since TODO
* @since 2.475
*/
public static RunUrl decompose(StaplerRequest2 req) {
List<Ancestor> ancestors = req.getAncestors();
Expand Down Expand Up @@ -611,7 +611,7 @@ public static <T> Iterable<T> reverse(Collection<T> collection) {
}

/**
* @since TODO
* @since 2.475
*/
public static Cookie getCookie(HttpServletRequest req, String name) {
Cookie[] cookies = req.getCookies();
Expand All @@ -634,7 +634,7 @@ public static javax.servlet.http.Cookie getCookie(javax.servlet.http.HttpServlet
}

/**
* @since TODO
* @since 2.475
*/
public static String getCookie(HttpServletRequest req, String name, String defaultValue) {
Cookie c = getCookie(req, name);
Expand Down Expand Up @@ -754,7 +754,7 @@ public static long getHourLocalTimezone() {
* This is used to determine the "current" URL assigned to the given object,
* so that one can compute relative URLs from it.
*
* @since TODO
* @since 2.475
*/
public static String getNearestAncestorUrl(StaplerRequest2 req, Object it) {
List list = req.getAncestors();
Expand Down Expand Up @@ -982,7 +982,7 @@ public static boolean hasPermission(Object object, Permission permission) throws
}

/**
* @since TODO
* @since 2.475
*/
public static void adminCheck(StaplerRequest2 req, StaplerResponse2 rsp, Object required, Permission permission) throws IOException, ServletException {
// this is legacy --- all views should be eventually converted to
Expand Down Expand Up @@ -1014,7 +1014,7 @@ public static void adminCheck(StaplerRequest req, StaplerResponse rsp, Object re
/**
* Infers the hudson installation URL from the given request.
*
* @since TODO
* @since 2.475
*/
public static String inferHudsonURL(StaplerRequest2 req) {
String rootUrl = Jenkins.get().getRootUrl();
Expand Down Expand Up @@ -2133,7 +2133,7 @@ public static List<Descriptor<CrumbIssuer>> getCrumbIssuerDescriptors() {
}

/**
* @since TODO
* @since 2.475
*/
public static String getCrumb(StaplerRequest2 req) {
Jenkins h = Jenkins.getInstanceOrNull();
Expand Down Expand Up @@ -2329,7 +2329,7 @@ public static String createRenderOnDemandProxy(JellyContext context, String attr
/**
* Called from renderOnDemand.jelly to generate the parameters for the proxy object generation.
*
* @since TODO
* @since 2.475
*/
@Restricted(NoExternalUse.class)
public static StaplerRequest2.RenderOnDemandParameters createRenderOnDemandProxyParameters(JellyContext context, String attributesToCapture) {
Expand Down
4 changes: 2 additions & 2 deletions core/src/main/java/hudson/Plugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ public void configure(JSONObject formData) throws IOException, javax.servlet.Ser
* <p>
* If you are using this method, you'll likely be interested in
* using {@link #save()} and {@link #load()}.
* @since TODO
* @since 2.475
*/
public void configure(StaplerRequest2 req, JSONObject formData) throws IOException, ServletException, FormException {
try {
Expand All @@ -250,7 +250,7 @@ public void configure(StaplerRequest req, JSONObject formData) throws IOExceptio
/**
* This method serves static resources in the plugin under {@code hudson/plugin/SHORTNAME}.
*
* @since TODO
* @since 2.475
*/
public void doDynamic(StaplerRequest2 req, StaplerResponse2 rsp) throws IOException, ServletException {
if (Util.isOverridden(Plugin.class, getClass(), "doDynamic", StaplerRequest.class, StaplerResponse.class)) {
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/java/hudson/PluginManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ PluginManager doCreate(@NonNull Class<? extends PluginManager> klass,
private final PluginStrategy strategy;

/**
* @since TODO
* @since 2.475
*/
protected PluginManager(ServletContext context, File rootDir) {
this.context = context;
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/java/hudson/Util.java
Original file line number Diff line number Diff line change
Expand Up @@ -1852,7 +1852,7 @@ public static long daysElapsedSince(@NonNull Date date) {
* Find the specific ancestor, or throw an exception.
* Useful for an ancestor we know is inside the URL to ease readability
*
* @since TODO
* @since 2.475
*/
@Restricted(NoExternalUse.class)
public static @NonNull <T> T getNearestAncestorOfTypeOrThrow(@NonNull StaplerRequest2 request, @NonNull Class<T> clazz) {
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/java/hudson/WebAppMain.java
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ private void recordBootAttempt(File home) {
}

/**
* @since TODO
* @since 2.475
*/
public static void installExpressionFactory(ServletContextEvent event) {
JellyFacet.setExpressionFactory(event, new ExpressionFactory2());
Expand Down
6 changes: 3 additions & 3 deletions core/src/main/java/hudson/console/AnnotatedLargeText.java
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public AnnotatedLargeText(ByteBuffer memory, Charset charset, boolean completed,
}

/**
* @since TODO
* @since 2.475
*/
public void doProgressiveHtml(StaplerRequest2 req, StaplerResponse2 rsp) throws IOException {
if (Util.isOverridden(AnnotatedLargeText.class, getClass(), "doProgressiveHtml", StaplerRequest.class, StaplerResponse.class)) {
Expand All @@ -122,7 +122,7 @@ private void doProgressiveHtmlImpl(StaplerRequest2 req, StaplerResponse2 rsp) th
/**
* Aliasing what I think was a wrong name in {@link LargeText}
*
* @since TODO
* @since 2.475
*/
public void doProgressiveText(StaplerRequest2 req, StaplerResponse2 rsp) throws IOException {
doProgressText(req, rsp);
Expand All @@ -146,7 +146,7 @@ private boolean isHtml() {
}

/**
* @since TODO
* @since 2.475
*/
@Override
protected void setContentType(StaplerResponse2 rsp) {
Expand Down
8 changes: 4 additions & 4 deletions core/src/main/java/hudson/model/AbstractItem.java
Original file line number Diff line number Diff line change
Expand Up @@ -649,7 +649,7 @@ private Object readResolve() {
/**
* Accepts the new description.
*
* @since TODO
* @since 2.475
*/
@RequirePOST
public synchronized void doSubmitDescription(StaplerRequest2 req, StaplerResponse2 rsp) throws IOException, ServletException {
Expand Down Expand Up @@ -690,7 +690,7 @@ private void doSubmitDescriptionImpl(StaplerRequest2 req, StaplerResponse2 rsp)
* since it predates {@code <l:confirmationLink>}. {@code /delete} goes to a Jelly page
* which should now be unused by core but is left in case plugins are still using it.
*
* @since TODO
* @since 2.475
*/
@RequirePOST
public void doDoDelete(StaplerRequest2 req, StaplerResponse2 rsp) throws IOException, ServletException, InterruptedException {
Expand Down Expand Up @@ -736,7 +736,7 @@ private void doDoDeleteImpl(StaplerRequest2 req, StaplerResponse2 rsp) throws IO
}

/**
* @since TODO
* @since 2.475
*/
@Override
public void delete(StaplerRequest2 req, StaplerResponse2 rsp) throws IOException, ServletException {
Expand Down Expand Up @@ -830,7 +830,7 @@ protected void performDelete() throws IOException, InterruptedException {
/**
* Accepts {@code config.xml} submission, as well as serve it.
*
* @since TODO
* @since 2.475
*/
@WebMethod(name = "config.xml")
public void doConfigDotXml(StaplerRequest2 req, StaplerResponse2 rsp)
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/java/hudson/model/AbstractProject.java
Original file line number Diff line number Diff line change
Expand Up @@ -1778,7 +1778,7 @@ public void doPolling(StaplerRequest2 req, StaplerResponse2 rsp) throws IOExcept
}

/**
* @since TODO
* @since 2.475
*/
@Override
protected void submit(StaplerRequest2 req, StaplerResponse2 rsp) throws IOException, ServletException, FormException {
Expand Down
4 changes: 2 additions & 2 deletions core/src/main/java/hudson/model/Actionable.java
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ public <T extends Action> T getAction(Class<T> type) {
}

/**
* @since TODO
* @since 2.475
*/
public Object getDynamic(String token, StaplerRequest2 req, StaplerResponse2 rsp) {
if (Util.isOverridden(Actionable.class, getClass(), "getDynamic", String.class, StaplerRequest.class, StaplerResponse.class)) {
Expand Down Expand Up @@ -374,7 +374,7 @@ private Object getDynamicImpl(String token, StaplerRequest2 req, StaplerResponse
}

/**
* @since TODO
* @since 2.475
*/
@Override
public ContextMenu doContextMenu(StaplerRequest2 request, StaplerResponse2 response) throws Exception {
Expand Down
4 changes: 2 additions & 2 deletions core/src/main/java/hudson/model/BuildAuthorizationToken.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public BuildAuthorizationToken(String token) {
}

/**
* @since TODO
* @since 2.475
*/
public static BuildAuthorizationToken create(StaplerRequest2 req) {
if (req.getParameter("pseudoRemoteTrigger") != null) {
Expand All @@ -79,7 +79,7 @@ public static BuildAuthorizationToken create(StaplerRequest req) {
}

/**
* @since TODO
* @since 2.475
*/
public static void checkPermission(Job<?, ?> project, BuildAuthorizationToken token, StaplerRequest2 req, StaplerResponse2 rsp) throws IOException {
if (token != null && token.token != null) {
Expand Down
Loading

0 comments on commit 08a248c

Please sign in to comment.