index.js
function getGlobs() {

  // Look globally and locally for matching glob pattern
  const dirs = [
    `${process.cwd()}/node_modules/`, // local (where they ran the command from)
    `${__dirname}/..`,  // global, if scoped package (where this code exists)
    `${__dirname}/../..`, // global, if not scoped package
  ];

  let globs = [];

  dirs.forEach(dir => {
    const legacyPattern = path.join(dir, '*/skyux-builder*/package.json');
    const newPattern = path.join(dir, '@skyux-sdk/builder*/package.json');

    logger.verbose(`Looking for modules in ${legacyPattern} and ${newPattern}`);

    globs = globs.concat([
      ...glob.sync(legacyPattern),
      ...glob.sync(newPattern)
    ]);
  });

  return globs;
}
function getGlobs() {

  // Look globally and locally for matching glob pattern
  const dirs = [
    `${process.cwd()}/node_modules/`, // local (where they ran the command from)
    `${__dirname}/..`,  // global, if scoped package (where this code exists)
    `${__dirname}/../..`, // global, if not scoped package
  ];

  let globs = [];

  dirs.forEach(dir => {
    const legacyPattern = path.join(dir, '*/skyux-builder*/package.json');
    const newPattern = path.join(dir, '@skyux-sdk/builder*/package.json');

    logger.verbose(`Looking for modules in ${legacyPattern} and ${newPattern}`);

    globs = globs.concat([
      ...glob.sync(legacyPattern),
      ...glob.sync(newPattern)
    ]);
  });

  return globs;
}
function getGlobs ( ) { // Look globally and locally for matching glob pattern const dirs = [ ` ${ process . cwd ( ) } ` , // local (where they ran the command from) ` ${ __dirname } ` , // global, if scoped package (where this code exists) ` ${ __dirname } ` , // global, if not scoped package ] ; let globs = [ ] ; dirs . forEach ( dir => { const legacyPattern = path . join ( dir , '*/skyux-builder*/package.json' ) ; const newPattern = path . join ( dir , '@skyux-sdk/builder*/package.json' ) ; logger . verbose ( ` ${ legacyPattern } ${ newPattern } ` ) ; globs = globs . concat ( [ ... glob . sync ( legacyPattern ) , ... glob . sync ( newPattern ) ] ) ; } ) ; return globs ; }
Returns results of glob.sync from specified directory and our glob pattern.
@returns {Array} Array of matching patterns
Returns results of glob . sync from specified directory and our glob pattern .