Skip to content

Commit

Permalink
add configure page
Browse files Browse the repository at this point in the history
  • Loading branch information
mzp committed Jun 11, 2011
1 parent 50e4a24 commit f3113f5
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 171 deletions.
140 changes: 0 additions & 140 deletions src/main/java/org/codefirst/jenkins/wsnotifier/HelloWorldBuilder.java

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ public DescriptorImpl getDescriptor() {

@Extension // This indicates to Jenkins that this is an implementation of an extension point.
public static final class DescriptorImpl extends BuildStepDescriptor<Publisher> {
private int port = 8081;

public int port(){ return port; }
public boolean isApplicable(Class<? extends AbstractProject> aClass) {
// Indicates that this builder can be used with all kinds of project types
return true;
Expand All @@ -47,8 +50,9 @@ public String getDisplayName() {

@Override
public boolean configure(StaplerRequest req, JSONObject formData) throws FormException {
port = formData.getInt("port");
save();
return super.configure(req,formData);
}
}
}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:d="jelly:define" xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form">
<f:section title="Websocket Notifier">
<f:entry title="Port"
description="Port number of Websocket server"
help="/plugin/wsnotifier/help-globalConfig.html">
<f:textbox name="port" value="${descriptor.port()}" />
</f:entry>
</f:section>
</j:jelly>

0 comments on commit f3113f5

Please sign in to comment.