This is an automated email from the ASF dual-hosted git repository.
niallp pushed a commit to branch experimental
in repository https://gitbox.apache.org/repos/asf/attic.git
The following commit(s) were added to refs/heads/experimental by this push:
new 11ab8d4 Split "Projects" & "Sub-projects" on different pages & menus
11ab8d4 is described below
commit 11ab8d4d31c2bb81999b27e25165e6553747d25b
Author: Niall Pemberton <[email protected]>
AuthorDate: Tue May 6 12:42:19 2025 +0100
Split "Projects" & "Sub-projects" on different pages & menus
---
_plugins/projects-plugin.rb | 7 ++++++-
projects.md | 10 +++++-----
projects.md => subprojects.md | 16 +++++++++-------
3 files changed, 20 insertions(+), 13 deletions(-)
diff --git a/_plugins/projects-plugin.rb b/_plugins/projects-plugin.rb
index 30d5da5..f0c2c0f 100644
--- a/_plugins/projects-plugin.rb
+++ b/_plugins/projects-plugin.rb
@@ -52,12 +52,17 @@ module ProjectsPlugin
# doesn't exist in the `data` hash.
#data.default_proc = proc do |_, projname|
# site.frontmatter_defaults.find(relative_path, :projects, projname)
+
+ parent = 'Retired Projects'
+ if project['project_type'] == 'Subproject'
+ parent = 'Retired Sub-Projects'
+ end
# Define custom data.
@data = project.clone
@data['layout'] ='project-layout'
@data['title'] = project['project_name']
- @data['parent'] = 'Retired Projects'
+ @data['parent'] = parent
@data['nav_order'] = index
@data['has_toc'] = true
end
diff --git a/projects.md b/projects.md
index 368e9b1..4a82989 100644
--- a/projects.md
+++ b/projects.md
@@ -25,15 +25,15 @@ limitations under the License.
***
{: .fs-5}
-This page lists all the **Projects** and **Subprojects** in The Apache Attic.
+This page lists all the **Projects** in The Apache Attic, for Sub-Projects see
the
+[Retired Sub-Projects page]({% link subprojects.md %}).
-{: .note}
-In the early years The Apache Attic accepted some ***Subprojects***, but this
is no longer the
-case and only ***Top Level Projects*** (projects with a **PMC**) are now
accepted.
+
+{% assign project_array = site.data.project_array | where: "project_type",
"PMC" -%}
|Project|Type|Description|Retired|
|:------|:---|:----------|:------|
-{%- for project in site.data.project_array %}
+{%- for project in project_array %}
|{{forloop.index}}. [{{project.project_apachename}}](
{%- link {{project.project_id | prepend: "projects/" | append: ".html"}} -%}
)|{{project.project_type}}|{{project.project_shortdesc}}|{{project.retirement_date
| date: "%b %Y"}}
diff --git a/projects.md b/subprojects.md
similarity index 72%
copy from projects.md
copy to subprojects.md
index 368e9b1..35940e2 100644
--- a/projects.md
+++ b/subprojects.md
@@ -1,8 +1,8 @@
---
layout: page
-title: Retired Projects
+title: Retired Sub-Projects
has_toc: false
-nav_order: 40
+nav_order: 45
---
{%- comment -%}
Licensed to the Apache Software Foundation (ASF) under one or more
@@ -21,19 +21,21 @@ See the License for the specific language governing
permissions and
limitations under the License.
{% endcomment %}
-<h1>Retired Projects</h1>
+<h1>Retired Sub-Projects</h1>
***
{: .fs-5}
-This page lists all the **Projects** and **Subprojects** in The Apache Attic.
+This page lists all the **Sub-Projects** in The Apache Attic, for Projects see
the
+[Retired Projects page]({% link projects.md %}).
{: .note}
-In the early years The Apache Attic accepted some ***Subprojects***, but this
is no longer the
-case and only ***Top Level Projects*** (projects with a **PMC**) are now
accepted.
+Historically the Apache Attic accepted ***Sub-Projects***, but since 2014 this
is no longer the case.
+
+{% assign project_array = site.data.project_array | where: "project_type",
"Subproject" -%}
|Project|Type|Description|Retired|
|:------|:---|:----------|:------|
-{%- for project in site.data.project_array %}
+{%- for project in project_array %}
|{{forloop.index}}. [{{project.project_apachename}}](
{%- link {{project.project_id | prepend: "projects/" | append: ".html"}} -%}
)|{{project.project_type}}|{{project.project_shortdesc}}|{{project.retirement_date
| date: "%b %Y"}}