Globbing includes #1

merged 1 commit into from Feb 11, 2014


None yet
3 participants

timoxley commented May 7, 2012

This got a bit more tricky than anticipated, but it works ok.

3 systems:

// merge all items matching glob
config: "include config/*" 

// collect as map, keyed by filename (note use of '{}' )
config: "include {config/*}"
// e.g.
  database: { 
    // db settings from config/database.json 
  app: { 
    // app settings from config/app.json 

// collect as an array, (note use of '[]' )
users: "include [users/*]" 
// e.g.
  users: [
      {user: 'from users/dave.json'}
      {user: 'from users/barry.json'}
      {user: 'from users/joe.json'}

timoxley commented May 7, 2012

The readme could probably do with some work, let me know what you think.


3rd-Eden commented Jul 17, 2012

Do want


timoxley commented Jul 20, 2012

@visionmedia updated this to work with your latest master. Also refactored the code a bit as previously it looked like the ravings of a madman, high on mapreduce.


timoxley commented Feb 8, 2014


tj added a commit that referenced this pull request Feb 11, 2014

@tj tj merged commit 0cc29c0 into tj:master Feb 11, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment