Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-7066

Support mixins in repoinit "create path" statements

    XMLWordPrintableJSON

Details

    Description

      The repoinit "create path" statement currently supports nodetypes but no mixins, we should add support for them.

      The current create path syntax is like

      create path (sling:Folder) /var/discovery(nt:unstructured)/somefolder
      create path /one/two/three
      create path /three/four(nt:folk)/five(nt:jazz)/six
      

      Where the first bracketed statement, before the path, is the default nodetype for all subpaths, and each subpath can have a specific nodetype.

      To add mixin support I suggest the syntax of these examples for these bracketed statements:

      (sling:Folder mixin mix:A, mix:B)
      (nt:unstructured mixin mix:C)
      (mixin mix:A)
      (mixin mix:A, mix:B)
      

      The last two forms without a nodeteype meaning "set mixins only but keep the default nodetype", which in this example

      create path (sling:Folder) /var/foo(mixin mix:B)
      

      means /var/foo is of type sling:Folder with mixin mix:B

      whereas in this example

      create /var/bar(mixin mix:C)
      

      /var/bar uses the default type defined by /var's type, with mix:C added.

      Attachments

        Activity

          People

            marett Timothee Maret
            bdelacretaz Bertrand Delacretaz
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: