Socket
Socket
Sign inDemoInstall

puli

Package Overview
Dependencies
37
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    puli

Puli JsonRepository Javascript implementation for automation tools plugins


Version published
Weekly downloads
2
Maintainers
1
Install size
426 kB
Created
Weekly downloads
 

Readme

Source

puli.js : the Puli Javascript reader

Build Status Build status

puli.js provides a Javascript, read-only API for transform Puli path into filesystem paths using a JSON file generated by the PHP JsonRepository.

puli.js is a first step towards creating plugins for automation tools such as Gulp, Grunt or Webpack.

This library is maintained for NodeJS 0.12+.

Authors

Usage

The JsonRepository generates a JSON file to store its path mappings (usually /your/project/root/.puli/path-mappings.json). This file is used by puli.js to transform Puli paths into filesystem paths.

var puli = require('puli').load('.puli/path-mappings.json')

puli.path('/res/foo'); // returns the filesystem path associated to the virtual path /app/foo
puli.paths('/res/**/*.js'); // find matching virtual paths and return associated filesystem paths as an array
puli.exists('/res/**/*.js'); // check if the given virtual path exists or if the given glob contain paths

puli.js provides a read-only API: you cannot edit the path-mappings using it.

Documentation

Read the Puli Documentation to learn more about Puli.

Contribute

Contributions to Puli are always welcome!

Report bugs

You can report any bugs or issues you find on the issue tracker.

Pull requests

If you want to contribute on the code, here are some informations:

  • puli.js is developed using ES6 ;
  • we use Babel and Grunt to compile to ES5: to compile yourself, you can either run npm run babel to compile one time or run npm run watch to compile your files live ;
  • the source code is located in src and tests are located in test : theses two directories are compiled by Gulp respectively to dist and test-dist ;
  • run npm test to launch the test suite (the tests use mocha) ;

Create an automation tool plugin using this library

If you are interested in creating an automation tool plugin (for Gulp, Grunt, Webpack, ...), don't hesitate to open an issue in the issue tracker to discuss it. You can also join us on Gitter.

Support

If you are having problems, send a mail to galopintitouan@gmail.com or bschussek@gmail.com or shout out to @titouangalopin or @webmozart on Twitter.

License

All contents of this package are licensed under the MIT license.

Keywords

FAQs

Last updated on 02 Apr 2016

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc