Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

broccoli-merge-trees

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

broccoli-merge-trees - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

4

CHANGELOG.md
# master
# 0.2.1
* Use node-symlink-or-copy to enable possible future symlink support on Windows
# 0.2.0

@@ -4,0 +8,0 @@

14

index.js

@@ -7,4 +7,2 @@ var fs = require('fs')

var isWindows = process.platform === 'win32'
module.exports = TreeMerger

@@ -121,3 +119,3 @@ TreeMerger.prototype = Object.create(Writer.prototype)

if (infoHash.isDirectory) {
if (isWindows || infoHash.indices.length > 1) {
if (infoHash.indices.length > 1) {
// Copy/merge subdirectory

@@ -130,11 +128,3 @@ if (infoHash.indices[0] === i) { // avoid duplicate recursion

// Symlink entire subdirectory
if (fs.lstatSync(fullPath).isSymbolicLink()) {
// When we encounter symlinks, follow them. This prevents indirection
// from growing out of control. Note: At the moment `realpath` on Node
// is 70x slower than native: https://github.com/joyent/node/issues/7902
fullPath = fs.realpathSync(fullPath)
} else if (fullPath[0] !== path.sep) {
fullPath = process.cwd() + path.sep + fullPath
}
fs.symlinkSync(fullPath, destPath)
symlinkOrCopySync(fullPath, destPath)
}

@@ -141,0 +131,0 @@ } else { // isFile

{
"name": "broccoli-merge-trees",
"description": "Broccoli plugin to merge multiple trees into one",
"version": "0.2.0",
"version": "0.2.1",
"author": "Jo Liss <joliss42@gmail.com>",

@@ -6,0 +6,0 @@ "main": "index.js",

var Writer = require('broccoli-writer')
var RSVP = require('rsvp')
var Promise = require('rsvp').Promise
var ncp = require('ncp')

@@ -22,3 +21,3 @@ var fixturify = require('fixturify')

function readTree (tree) {
return Promise.resolve().then(function () {
return RSVP.resolve().then(function () {
// Plain directory path?

@@ -31,3 +30,3 @@ if (typeof tree === 'string') return tree

if (self.treesToCleanUp.indexOf(tree) === -1) self.treesToCleanUp.push(tree)
return Promise.resolve(tree.read(readTree))
return RSVP.resolve(tree.read(readTree))
.then(function (dir) {

@@ -34,0 +33,0 @@ trees.push(tree)

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc