This is an automated email from the ASF dual-hosted git repository.

slawrence pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/daffodil-site.git


The following commit(s) were added to refs/heads/main by this push:
     new e076a97  Add pages for Daffodil SBT Plugin release
e076a97 is described below

commit e076a978fc3abad2b8ad5ce6be721f32a297b37d
Author: Steve Lawrence <[email protected]>
AuthorDate: Thu Apr 25 08:45:13 2024 -0400

    Add pages for Daffodil SBT Plugin release
    
    Also update DFDL Layout page to mention the plugin and additional minor 
fixups
---
 site/_config.yml                              |  5 ++
 site/_includes/themes/apache/_navigation.html | 10 +++-
 site/_includes/themes/apache/default.html     |  2 +-
 site/_layouts/sbt.html                        | 70 +++++++++++++++++++++++++++
 site/_sbt/1.0.0.md                            | 28 +++++++++++
 site/dfdl-layout.md                           | 49 +++++++++----------
 site/sbt.md                                   | 55 +++++++++++++++++++++
 7 files changed, 190 insertions(+), 29 deletions(-)

diff --git a/site/_config.yml b/site/_config.yml
index b556b00..cf36250 100644
--- a/site/_config.yml
+++ b/site/_config.yml
@@ -28,6 +28,9 @@ collections:
     vscode:
       output: true
       permalink: /vscode/:title/
+    sbt:
+      output: true
+      permalink: /sbt/:title/
 
 # Site-wide defaults
 defaults:
@@ -35,6 +38,8 @@ defaults:
       values: { layout: release }
     - scope:  { type: vscode }
       values: { layout: vscode }
+    - scope:  { type: sbt }
+      values: { layout: sbt }
 
 # Used by the JIRA plugin
 jira_base_url: https://issues.apache.org/jira/browse
diff --git a/site/_includes/themes/apache/_navigation.html 
b/site/_includes/themes/apache/_navigation.html
index 25e408e..4d145f8 100644
--- a/site/_includes/themes/apache/_navigation.html
+++ b/site/_includes/themes/apache/_navigation.html
@@ -4,7 +4,13 @@
         <nav role="navigation">
           <ul class="nav navbar-nav navbar-right">
             <li><a href="/releases">Releases</a></li>
-            <li><a href="/vscode">VS Code</a></li>
+            <li id="extensions">
+              <a href="#" data-toggle="dropdown" 
class="dropdown-toggle">Extensions<b class="caret"></b></a>
+              <ul class="dropdown-menu dropdown-left">
+                <li><a href="/vscode">VS Code</a></li>
+                <li><a href="/sbt">SBT</a></li>
+              </ul>
+            </li>
             <li id="documentation">
               <a href="#" data-toggle="dropdown" 
class="dropdown-toggle">Docs<b class="caret"></b></a>
               <ul class="dropdown-menu dropdown-left">
@@ -64,7 +70,7 @@
 {% else %}
 <div class="title">
   <div class="container">
-    <h2>{% if page.collection == "releases" %}{% if page.apache %}Apache {% 
endif %}Daffodil {% endif %}{% if page.collection == "vscode" %}VS Code 
Extension {% endif %}{{ page.title }}</h2>
+    <h2>{% if page.collection == "releases" %}{% if page.apache %}Apache {% 
endif %}Daffodil {% endif %}{% if page.collection == "vscode" %}VS Code 
Extension {% endif %}{% if page.collection == "sbt" %}SBT Plugin {% endif %}{{ 
page.title }}</h2>
   </div>
 </div>
 {% endif %}
diff --git a/site/_includes/themes/apache/default.html 
b/site/_includes/themes/apache/default.html
index 7ef5081..264b9e1 100644
--- a/site/_includes/themes/apache/default.html
+++ b/site/_includes/themes/apache/default.html
@@ -2,7 +2,7 @@
 <html lang="en">
   <head>
     <meta charset="utf-8">
-    <title>Apache Daffodil | {% if page.collection == "vscode" %}VS Code 
Extension {% endif %}{{ page.title }}</title>
+    <title>Apache Daffodil | {% if page.collection == "vscode" %}VS Code 
Extension {% endif %}{% if page.collection == "sbt" %}SBT Plugin {% endif %}{{ 
page.title }}</title>
     {% if page.description %}<meta name="description" content="{{ 
page.description }}">{% endif %}
     <meta name="author" content="{{ site.author.name }}">
 
diff --git a/site/_layouts/sbt.html b/site/_layouts/sbt.html
new file mode 100644
index 0000000..055ba39
--- /dev/null
+++ b/site/_layouts/sbt.html
@@ -0,0 +1,70 @@
+---
+layout: default
+permalink: /sbt/release-notes-:title
+---
+
+{% if page.release != "final" %}
+  <div class="alert alert-warning">
+    Apache Daffodil SBT Plugin {{ page.title }} has not yet been released! The 
artifact
+    and release notes below are drafts for a proposed release of Apache
+    Daffodil SBT Plugin which has not yet occurred.
+  </div>
+{% endif %}
+
+<div class="row">
+  <div class="col-md-12">
+    <h3>Get Release</h3>
+    <ul class="nav nav-tabs">
+      <li class="active"><a data-toggle="tab" 
href="#download">Download</a></li>
+    </ul>
+    <div class="tab-content">
+      <div id="download" class="tab-pane fade in active">
+        {% if page.source-dist %}
+          <h4>Source</h4>
+          <p>
+          {% include download-list.html
+             apache=page.apache
+             artifacts=page.source-dist
+             project="daffodil/daffodil-sbt"
+             release=page.release
+             type="src"
+             version=page.title
+          %}
+          </p>
+        {% endif %}
+
+        {% if page.binary-dist %}
+          <h4>Binaries</h4>
+          <p>
+          {% include download-list.html
+             apache=page.apache
+             artifacts=page.binary-dist
+             project="daffodil/daffodil-sbt"
+             release=page.release
+             type="bin"
+             version=page.title
+          %}
+          </p>
+        {% endif %}
+
+        {% if page.apache %}
+          <hr />
+          <p>
+            <i>
+              The above release files should be verified using the PGP 
signatures and the
+              <a href='https://downloads.apache.org/daffodil/KEYS'>project 
release KEYS</a>. See
+              <a 
href='https://www.apache.org/info/verification.html'>verification 
instructions</a>
+              for a description of using the PGP and KEYS files for
+              verification. A SHA512 checksum is also provided as
+              an alternative verification method.
+            </i>
+          </p>
+        {% endif page.apache %}
+      </div>
+    </div>
+  </div>
+</div>
+
+<h3 id="release-notes">Release Notes</h3>
+
+{{ content }}
diff --git a/site/_sbt/1.0.0.md b/site/_sbt/1.0.0.md
new file mode 100644
index 0000000..d2818a6
--- /dev/null
+++ b/site/_sbt/1.0.0.md
@@ -0,0 +1,28 @@
+---
+
+release: rc1
+apache: true
+title: 1.0.0
+date: 2024-04-25
+summary: >
+    Initial release
+
+source-dist:
+    - "apache-daffodil-sbt-1.0.0-src.zip"
+---
+
+This is the first release of the Apache Daffodil SBT Plugin.
+
+See the [GitHub page](https://github.com/apache/daffodil-sbt) for details to 
enable and configure.
+
+#### New Features
+
+* Configure SBT settings commonly needed for a DFDL Schema project, such as 
Daffodil dependencies, test options, and more
+* Configure settings needed for projects that create Daffodil User Defined 
Functions or Layers
+* Ability to create saved parsers and publish alongside jars
+* Ability to reload and use saved parsers for use with TDML tests
+* Option to use a flat directory structure, useful for examples and testing
+
+#### Closed Issues
+
+[GitHub v1.0.0 Closed 
Issues](https://github.com/apache/daffodil-sbt/milestone/1?closed=1)
diff --git a/site/dfdl-layout.md b/site/dfdl-layout.md
index e6fbcc2..4234060 100644
--- a/site/dfdl-layout.md
+++ b/site/dfdl-layout.md
@@ -25,7 +25,9 @@ limitations under the License.
 There is a specific way of organizing a DFDL schema project that has been found
 to be helpful. It uses specific directory naming conventions and tree structure
 to manage name conflicts in a manner similar to how Java package names
-correspond to directory names.
+correspond to directory names. It also uses the
+[SBT](https://www.scala-sbt.org/) build tool with the [Daffodil SBT 
Plugin](/sbt)
+to more easily manage, build, and test DFDL schema projects.
 
 ### Quick Start
 
@@ -55,8 +57,6 @@ This set of conventions provides a number of benefits:
     * Run a suite of tests via 'sbt test'
     * Publish a local version of the schema for use in other projects that also
       follow this layout.
-* Eclipse IDE for development and test of the schema. Multiple such schemas all
-  work together without conflict in the IDE.
 * Encourages organizing DFDL schemas into reusable libraries. 
     * A DFDL schema project need not define a whole data format. It can define
       a library of pieces to be included/imported by other formats.
@@ -81,7 +81,8 @@ The standard file tree would be:
     │                            of Daffodil needed, or versions of other DFDL 
schemas needed
     ├── README.md              - Documentation about the DFDL schema in 
Markdown file format
     ├── project/
-    │   └── build.properties   - Defines the sbt version
+    │   ├── build.properties   - Defines the sbt version
+    │   └── plugins.sbt        - Defines plugins, including the Daffodil SBT 
plugin
     └── src/
         ├── main/
         │   └── resources/
@@ -109,6 +110,19 @@ The standard file tree would be:
                         └── rfmt/
                             └── Tests1.scala   - Scala test driver file
 
+### project/plugins.sbt
+
+Add the Daffodil SBT plugin to the project/plugins.sbt file:
+
+```scala
+addSbtPlugin("org.apache.daffodil" % "sbt-daffodil" % "1.0.0")
+```
+
+This adds the [Daffodil SBT Plugin](/sbt) to the project, which configures
+settings and capabilities commonly needed to manage, build, and test DFDL 
schema
+projects. For more information about the settings that can be added to 
build.sbt
+or commands to run via SBT, see the [GitHub 
README](https://github.com/apache/daffodil-sbt/).
+
 ### build.sbt
 
 Use the below template for the build.sbt file:
@@ -120,20 +134,11 @@ organization := "com.example"
  
 version := "0.0.1"
  
-scalaVersion := "2.12.11"
- 
-libraryDependencies ++= Seq(
-  "org.apache.daffodil" %% "daffodil-tdml-processor" % "3.0.0" % "test",
-  "com.novocode" % "junit-interface" % "0.11" % "test",
-  "junit" % "junit" % "4.12" % "test",
-)
-
-testOptions += Tests.Argument(TestFrameworks.JUnit, "-v")
+scalaVersion := "2.12.18"
 
-crossPaths := false
+enablePlugins(DaffodilPlugin)
 ```
 
-Edit the version of daffodil-tdml above to match the version you are using. 
 
 ### .gitattributes
 
@@ -150,14 +155,6 @@ directory with the following content to disabling the 
mangline:
 The above tells git that any test files in the data directory should be treated
 as if they were binary, and thus not to mangle newlines.
 
-### Eclipse IDE
-
-If you organize your DFDL schema project using the above conventions, and then
-run ``sbt compile``, the ``lib_managed`` directory will be populated. Then if
-you create a new Eclipse scala project from the directory tree, Eclipse will
-see the ``lib_managed`` directory and construct a classpath containing all
-those jars.
-
 ### XSD Conventions
 
 DFDL schemas should have the ``.dfdl.xsd`` suffix to distinguish them from
@@ -174,7 +171,7 @@ The ``xs:include`` or ``xs:import`` elements of a DFDL 
Schema can
 import/include a DFDL schema that follows these conventions like this:
 
 ``` xml
-<xs:import namespace="urn:example.com/rfmt" 
schemaLocation="com/example/rfmt/xsd/rfmt.dfdl.xsd"/>
+<xs:import namespace="urn:example.com/rfmt" 
schemaLocation="/com/example/rfmt/xsd/rfmt.dfdl.xsd"/>
 ```
 
 The above is for using a DFDL schema as a library, from another different DFDL
@@ -187,14 +184,14 @@ appears in the same directory (the 
src/main/resources/.../xsd directory) via:
 <xs:include schemaLocation="format.dfdl.xsd"/>
 ```
 
-That is, peer files need not carry the long ``com/example/rfmt/xsd/`` prefix
+That is, peer files need not carry the long ``/com/example/rfmt/xsd/`` prefix
 that makes the reference globally unique.
 
 However, if one schema wants to include another different schema, then this
 standard way of organizing schema projects ensures that when packaged into jar
 files, the ``/src/main/resources`` directory contents are at the "root" of the
 jar file so that the ``schemaLocation`` of the ``xs:import`` or ``xs:include``
-containing the fully qualified path (``com/example/rfmt/xsd/rfmt.dfdl.xsd``)
+containing the fully qualified path (``/com/example/rfmt/xsd/rfmt.dfdl.xsd``)
 will be found on the ``CLASSPATH`` unambiguously. This convention is what
 allows the schema files themselves to have short names like rfmt.dfdl.xsd, and
 format.dfdl.xsd. Those names only need to be unique within a single schema
diff --git a/site/sbt.md b/site/sbt.md
new file mode 100644
index 0000000..a4b519d
--- /dev/null
+++ b/site/sbt.md
@@ -0,0 +1,55 @@
+---
+layout: page
+title: SBT Plugin
+group: nav-right
+---
+<!--
+{% comment %}
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+{% endcomment %}
+-->
+
+The Apache Daffodil SBT Plugin is plugin for the [SBT build 
tool](https://www.scala-sbt.org/) to help manage, build, and test DFDL schema 
projects. It is part of the [Standard DFDL Schema Project Layout](/dfdl-layout).
+
+See the [GitHub page](https://github.com/apache/daffodil-sbt) for details to 
enable and configure.
+
+#### Releases
+
+All recent Daffodil SBT Plugin releases are listed here. Each release below is 
listed by the version and date on which it was released. Clicking on the 
version number will take you to the release notes and downloads for that 
release.
+
+{% assign releases = site.sbt  | where: 'release', 'final' | where: 'apache', 
'true' | sort: 'date' %}
+{% if releases.size > 0 %}
+<table class="table">
+    <tr>
+        <th class="col-md-1">Version</th>
+        <th>Summary</th>
+        <th class="col-md-2 text-right">Release&nbsp;Date</th>
+    </tr>
+    {% for release in releases reversed %}
+        {% if release.title %}
+            <tr>
+                <td style="vertical-align: middle; line-height: 2.5em;" 
class="col-md-1"><a href="{{ release.url | prepend: site.baseurl }}">{{ 
release.title }}</a></td>
+                <td style="vertical-align: middle;">{{ release.summary }}</td>
+                <td style="vertical-align: middle;" class="col-md-2 
text-right">{{ release.date | date: "%Y-%m-%d" }}</td>
+            </tr>
+        {% endif %}
+    {% endfor %}
+</table>
+{% else %}
+<div class="alert alert-warning">
+No official Apache releases have been made yet. <a href="/community">Get 
involved</a> and help us on our way!
+</div>
+{% endif %}

Reply via email to