diff --git a/.scripts/check_proposals b/.scripts/check_proposals
index 594ab165..7ee64684 100755
--- a/.scripts/check_proposals
+++ b/.scripts/check_proposals
@@ -25,6 +25,7 @@ end
class MetadataChecker
def initialize
@categories = load_all_categories()
+ @stability_levels = ["experimental", "preview", "community", "default"]
end
def check pr_number, front_matter
@@ -37,6 +38,25 @@ class MetadataChecker
else
system("gh pr edit #{pr_number} --remove-label invalid-categories")
end
+ issue_errors = check_issue(pr_number, front_matter)
+ if issue_errors.length() > 0
+ errors << issue_errors
+ system("gh pr edit #{pr_number} --add-label missing-issue")
+ else
+ system("gh pr edit #{pr_number} --remove-label missing-issue")
+ end
+ begin
+ stability_level, err = check_stability_level(pr_number, front_matter)
+ system("gh pr edit #{pr_number} --remove-label invalid-stability-level")
+ # remove any previous stability-levels
+ @stability_levels.map { | level | system("gh pr edit #{pr_number} --remove-label stability-level/#{level}") }
+ system("gh pr edit #{pr_number} --add-label stability-level/#{stability_level}")
+ rescue => error
+ errors << error.message
+ system("gh pr edit #{pr_number} --add-label invalid-stability-level")
+ @stability_levels.map { | level | system("gh pr edit #{pr_number} --remove-label stability-level/#{level}") }
+ end
+
errors
end
@@ -54,6 +74,22 @@ class MetadataChecker
errors
end
+ def check_issue pr_number, front_matter
+ errors = []
+ unless (front_matter.key? "issue") && (front_matter["issue"] != nil)
+ errors << "Missing field: issue"
+ end
+ errors
+ end
+
+ def check_stability_level pr_number, front_matter
+ unless (front_matter.key? "stability-level") && (@stability_levels.include? front_matter["stability-level"])
+ raise "Invalid field: stability-level"
+ else
+ return front_matter["stability-level"]
+ end
+ end
+
def load_all_categories
yaml = YAML.load_file("_data/wildfly-categories.yaml")
return yaml["categories"]
diff --git a/_includes/index-categories.html b/_includes/index-categories.html
index bbddadac..87194629 100644
--- a/_includes/index-categories.html
+++ b/_includes/index-categories.html
@@ -28,7 +28,13 @@
-
{{page.title}}
+
+ {% if page.stability-level != "default" %}
+ [{{ page.stability-level }}]
+ {% endif %}
+ {{page.title}}
+
{% unless pages.categories == empty %}
@@ -14,6 +19,9 @@
{{page.title}}
{% endfor %}
{% endunless %}
+
{{ content }}
diff --git a/design-doc-template.adoc b/design-doc-template.adoc
index e0ce62b1..a2955f60 100644
--- a/design-doc-template.adoc
+++ b/design-doc-template.adoc
@@ -4,8 +4,17 @@ categories:
# - core
# - management
# if missing, add it to _data/widfly-categories and use its id
+#
+# Specify the stability level of the feature.
+# Values can be one of: experimental preview community default
+stability-level:
+#Specify the Feature Development tracker issue for the feature.
+# This must be an issue tracked in https://github.com/orgs/wildfly/projects/7/views/1.
+# To create a Feature Development tracker issue, go to https://github.com/wildfly/wildfly-proposals/issues/new/choose
+# and select 'Feature Development'
+issue:
---
-= [Experimental|Preview|Community|default]Template
+=
:author: Your Name
:email: your.email@redhat.com
:toc: left
@@ -13,95 +22,66 @@ categories:
:idprefix:
:idseparator: -
-== Overview
-
-== Issue Metadata
-
-=== Issue
-
-* https://issues.redhat.com/browse/WFCORE[WFCORE-XXXX]
-
-=== Related Issues
-
-* https://issues.redhat.com/browse/WFLY[WFLY-XXXX]
-
-=== Stability Level
-// Choose the planned stability level for the proposed functionality
-* [ ] Experimental
-
-* [ ] Preview
+____
-* [ ] Community
-
-* [ ] default
-
-=== Dev Contacts
+== Overview
-* mailto:{email}[{author}]
+____
-=== QE Contacts
+== Related Issues
-=== Testing By
-// Put an x in the relevant field to indicate if testing will be done by Engineering or QE.
-// Discuss with QE during the Kickoff state to decide this
-* [ ] Engineering
+____
-* [ ] QE
+== Affected Projects or Components
-=== Affected Projects or Components
+____
=== Other Interested Projects
=== Relevant Installation Types
-// Remove the x next to the relevant field if the feature in question is not relevant
-// to that kind of WildFly installation
-* [x] Traditional standalone server (unzipped or provisioned by Galleon)
-
-* [x] Managed domain
-* [x] OpenShift s2i
+____.
-* [x] Bootable jar
+* Traditional standalone server (unzipped or provisioned by Galleon)
+* Managed domain
+* OpenShift Source-to-Image (S2I)
+* Bootable jar
== Requirements
-=== Hard Requirements
-
-=== Nice-to-Have Requirements
-// Requirements in this section do not have to be met to merge the proposed functionality.
-// Note: Nice-to-have requirements that don't end up being implemented as part of
-// the work covered by this proposal should be moved to the 'Future Work' section.
-
+____
=== Non-Requirements
-// Use this section to explicitly discuss things that readers might think are required
-// but which are not required.
+
+__