New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@achingbrain/debootstrap

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@achingbrain/debootstrap - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

15

lib/dereference-symlinks.js
const fs = require('fs-extra')
const path = require('path')
const dereferenceDir = (dir) => {
const dereferenceDir = (options) => {
return new Promise((resolve, reject) => {
if (!dir) {
if (!options.path) {
return reject(new Error('Please specify a directory'))
}
const backup = `${dir}.backup`
const backup = `${options.path}.backup`
const dotDirs = []
fs.copy(dir, backup, {
fs.copy(options.path, backup, {
dereference: true,

@@ -25,6 +25,7 @@ filter: (filePath) => {

.then(() => Promise.all(
dotDirs.map(dotDir => fs.copy(dotDir, dotDir.replace(dir, backup)))
dotDirs
.map(dotDir => fs.copy(dotDir, dotDir.replace(options.path, backup)))
))
.then(() => fs.remove(dir))
.then(() => fs.move(backup, dir))
.then(() => fs.remove(options.path))
.then(() => fs.move(backup, options.path))
.then(resolve)

@@ -31,0 +32,0 @@ .catch(reject)

{
"name": "@achingbrain/debootstrap",
"version": "0.0.1",
"version": "0.0.2",
"description": "Like lerna bootstrap, but in reverse",

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

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