dergraaf / library-builder

Module based library builder for source code libraries
BSD 2-Clause "Simplified" License
4 stars 3 forks source link

Add a project.xml file generator/wizard #24

Open salkinium opened 6 years ago

salkinium commented 6 years ago

I would like to have a lbuild new command, which just generates a project.xml which contains a verbosely commented default project configuration.

Something like:

<?xml version='1.0' encoding='UTF-8'?>
<library xmlns:xsd="http://www.w3.org/2001/XMLSchema-instance"
         xsd:noNamespaceSchemaLocation="https://github.com/dergraaf/library-builder/lbuild/resources/configuration.xsd">
  <repositories> <!-- Add one or more repositories here -->
    <repository>
      <path><!-- path to repo.lb --></path>
    </repository>
    <!-- VCS docu? -->
    <cache>.lbuild_cache</cache> <!-- @dergraaf, what is this? -->
  </repositories>

  <options>
    <!-- For a list of available options try `lbuild discover-options` then `lbuild discover-module-options  
    <option name="repository:option">value</option>
    <option name="repository:module:option">value</option>
    <option name="repository:module:submodule:option">value</option> -->
  </options>
  <modules>
    <!-- For a list of available modules try `lbuild discover-modules`, this may depend on the above options!
    <module>repository:module</module>
    <module>repository:module:submodule</module> -->
  </modules>
</library>

cc @dergraaf

salkinium commented 6 years ago

I think lbuild new -m "repo:module:submodule" should then also create a submodule.lb and submodule.md with the correct init(module) function that sets module.name to submodule and module.parent to module and module.description to FileReader(submodule.md).