@epublishing/get-gem-paths

0.2.0 • Public • Published

get-gem-paths

This is a Node module that provides Ruby/Bundler interoperability. It's used to find the locations of installed gems in the Jade Rails stack, which grunt-epublishing then uses to resolve the front-end assets it needs.

This is meant to be installed into a Jade site or engine with a Gemfile present. It uses the current working directory to initialize Bundler and query its gem registry. It runs a Ruby script to do this, so you must have a working ruby somewhere in your PATH.

Installation & Usage

npm install @epublishing/get-gem-paths
const getGemPaths = require('@epublishing/get-gem-paths');

// getGemPaths is a function that returns a promise containing an array of result objects:
getGemPaths('jade').then((results) => {
  console.log(results);
});

/**
 * each result is an object with the following shape:
 * {
 *   name: 'jade',
 *   path: '/path/to/jade',
 *   version: '6.7.pre'
 * }
 */

Package Sidebar

Install

npm i @epublishing/get-gem-paths

Weekly Downloads

70

Version

0.2.0

License

MIT

Unpacked Size

3.77 kB

Total Files

7

Last publish

Collaborators

  • mikedamage
  • brewern
  • mhedges1
  • niyati.ace
  • mhedges