forge-struct

0.0.4 • Public • Published

Asynchronous project generator

Example from node

const Forge = require('forge-struct');

Forge.create([
  '/from_an_absolute_path/foo/subfoo/file_a.js',
  './from_a_relative_pathfoo/subfoo/file_b.js',
  '../../dir/file_b.js',
  'foo/subfoo/subsubfoo/file_c.js',
  'sample.js',
  'another_dir/empty_dir',
  {path: 'file_with_text.js', content: 'Hello !'} // Initialize a file with some content
])
.then(() => {
  console.log('Project generate');
});

Example from command line

npm install forge-struct -g

Explicit creation

forge foo/subfoo/file_a.js foo/subfoo/file_b.js foo/subfoo/subsubfoo/file_c.js sample.js another_dir/empty_dir

Implicit file creation

forge -f structure.json

With structure.json as follow

[
  "foo/subfoo/file_a.js",
  "foo/subfoo/file_b.js",
  "sample.js"
]

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.4
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.4
    1
  • 0.0.3
    0
  • 0.0.2
    0
  • 0.0.1
    0

Package Sidebar

Install

npm i forge-struct

Weekly Downloads

1

Version

0.0.4

License

ISC

Unpacked Size

4.99 kB

Total Files

5

Last publish

Collaborators

  • karlito40