mbeckerle commented on code in PR #2: URL: https://github.com/apache/daffodil-sbt/pull/2#discussion_r1462468321
########## README.md: ########## @@ -0,0 +1,80 @@ +<!-- + 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. +--> + +# Apache Daffodil SBT Plugin + +Plugin to enable Daffodil capabilities for DFDL schema projects. + +## Enable + +To enable the plugin, add the following to `project/plugins.sbt`: + +```scala +addSbtPlugin("org.apache.daffodil" % "sbt-daffodil" % "<version>") +``` + +## Features + +### Saved Parsers + +This plugin adds the ability to create and publish saved parsers of a schema. + +For each saved parser to generate, add an entry to the +`daffodilPackageBinInfos` setting. This setting is a Seq of 3-tuples made up of +the resource path to the schema, an optional root element to use in that +schema, and an optional name that is added to the artifact classifier to +differentiate multiple saved parsers. For example: + +```scala +daffodilPackageBinInfos := Seq( + ("/com/example/xsd/mainSchema.dfdl.xsd", None, None) + ("/com/example/xsd/otherSchema.dfdl.xsd", Some("otherRoot"), Some("other")) +) +``` + +You must also define which versions of Daffodil to build comptiable saved +parsers using the `daffodilPackageBinVersions` setting. For example, to build +saved parsers for Daffodil 3.6.0 and 3.5.0: + +```scala +daffodilPackageBinVersions := Set("3.6.0", "3.5.0") Review Comment: Will it be "370" or "370SNAPSHOT" or something like that in the binary files? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
