Packages
A web application in pursuit of meaning in life.
Current section
Files
Jump to
Current section
Files
assets/node_modules/deppack/lib/helpers.js
'use strict';
const sysPath = require('./path');
const fs = require('fs');
const isRelative = path => path.slice(0, 2) === './' || path.slice(0, 3) === '../';
const makeRelative = path => sysPath.relative(process.cwd(), path);
const not = f => i => !f(i);
const exists = path => new Promise(resolve => fs.exists(path, resolve));
module.exports = {makeRelative, isRelative, not, exists};