github.com/solo-io/cue@v0.4.7/doc/tutorial/basics/8_packages/10_packages.txt (about)

     1  cue eval a.cue b.cue
     2  cmp stdout expect-stdout-cue
     3  
     4  -- frontmatter.toml --
     5  title = "Packages"
     6  description = ""
     7  
     8  -- text.md --
     9  A CUE file is a standalone file by default.
    10  A `package` clause allows a single configuration to be split across multiple
    11  files.
    12  
    13  The configuration for a package is defined by the concatenation of all its
    14  files, after stripping the package clauses and not considering imports.
    15  
    16  Duplicate definitions are treated analogously to duplicate definitions within
    17  the same file.
    18  The order in which files are loaded is undefined, but any order will result
    19  in the same outcome, given that order does not matter.
    20  
    21  -- a.cue --
    22  package config
    23  
    24  foo: 100
    25  bar: int
    26  
    27  -- b.cue --
    28  package config
    29  
    30  bar: 200
    31  
    32  -- expect-stdout-cue --
    33  foo: 100
    34  bar: 200