How to use the foy.fs.copy function in foy

To help you get started, we’ve selected a few foy examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github teamhola / holakit / docs / Foyfile.js View on Github external
componentReadmes.forEach(async path => {
    const scope = path.match(/\/packages\/([a-z]+)\//)[1]
    const name = path.match(/\/([a-z\-]+)\/readme.md/)[1]
    if (!Array.isArray(sidebar[scope])) sidebar[scope] = []
    sidebar[scope].push(name)
    await fs.copy(path, `components/${scope}/${name}.md`)
  })

foy

A simple, light-weight and modern task runner for general purpose.

MIT
Latest version published 4 months ago

Package Health Score

65 / 100
Full package analysis