GithubHelp home page GithubHelp logo

node-alias's Introduction

node-alias

Mac OS aliases creation and reading from node.js

Attention

This library does currently not handle the book\0\0\0\0mark\0\0\0\0-header. It only does manipulation on the raw alias data.

I intend to add something like alias.write(buf, path) and alias.read(path).

Installation

npm install macos-alias

Usage

var alias = require('macos-alias');

API

alias.create(target)

Create a new alias pointing to target, returns a buffer.

(This function performs blocking fs interaction)

alias.decode(buf)

Decodes buffer buf and returns an object with info about the alias.

alias.encode(info)

Encodes the info-object into an alias, returns a buffer.

alias.isAlias(path)

Check if the file at path is an alias, returns a boolean.

(This function performs blocking fs interaction)

Hacking

Clone the repo and start making changes, run node-gyp to build the project.

node-gyp rebuild

Tests

mocha

node-alias's People

Contributors

baptistejamin avatar dliessi avatar linusu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

node-alias's Issues

Assertion Errors

Example:

  • I created an alias with macOS Big Sur / MacBook Air M1
  • In the node script I read the buffer with fs.readFileSync(pathToAliasFile)
  • I performed decode() on the buffer

... and received the following error:

Bildschirmfoto 2021-06-25 um 21 55 11

Library using an earlier version of nan

Hi,
(Sorry to bother you again.)
This library can't be installed in io.js v3.x as it uses an older version of nan.

This library is needed by ds-store which is used by node-appdmg.

Thanks a lot!

"npm install -g macos-alias" also fails

Hi
I have an issue which is probably related to the space in my hard-drive (nodejs/node-gyp#65).
The fix normally is to install globally:
npm install -g macos-alias

But this fails also..
The npm-debug.log shows that it [email protected] is installed but when it needs to install macos-alias
291 info lifecycle [email protected]~install: Failed to exec install script
and starts to rollback (rollbackFailedOptional)
But besides that not helpful.

But when I look at the output from my terminal:

→ npm install -g macos-alias

> [email protected] install /usr/local/lib/node_modules/macos-alias
> node-gyp rebuild

make: *** No rule to make target `../../../../../../Volumes/Data', needed by `Makefile'.  Stop.

the last line seems odd, because I was trying to stop the install from looking for my "Data HD"

cannot install on MacOS Sierra

Hi!

The command:

npm install macos-alias

Returns following errors:

[email protected] install /Users/pasha/ZergFWD/node_modules/macos-alias
node-gyp rebuild

CXX(target) Release/obj.target/volume/src/volume.o
In file included from /usr/include/Availability.h:176:0,
from /usr/include/stdio.h:65,
from /Users/pasha/.node-gyp/4.4.7/include/node/uv.h:51,
from ../../nan/nan.h:46,
from ../src/volume.cc:2:
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:777:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLLabelColorKey API_DEPRECATED("Use NSURLLabelColorKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'message' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'message' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'message' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:785:42: error: 'message' was not declared in this scope
const CFStringRef kCFURLEffectiveIconKey API_DEPRECATED("Use NSURLEffectiveIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'deprecated' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:789:39: error: 'message' was not declared in this scope
const CFStringRef kCFURLCustomIconKey API_DEPRECATED("Use NSURLCustomIconKey", macosx(10.6, 10.12), ios(4.0, 10.0), watchos(2.0, 3.0), tvos(9.0, 10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:833:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCanonicalPathKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:833:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCanonicalPathKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:833:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCanonicalPathKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:833:42: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLCanonicalPathKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1046:46: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsEncryptedKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1046:46: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsEncryptedKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1046:46: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsEncryptedKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1046:46: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsEncryptedKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1050:51: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsRootFileSystemKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1050:51: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsRootFileSystemKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1050:51: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsRootFileSystemKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1050:51: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeIsRootFileSystemKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1054:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsCompressionKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1054:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsCompressionKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1054:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsCompressionKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1054:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsCompressionKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1058:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsFileCloningKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1058:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsFileCloningKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1058:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsFileCloningKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1058:54: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsFileCloningKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1062:55: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsSwapRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1062:55: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsSwapRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1062:55: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsSwapRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1062:55: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsSwapRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1066:60: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsExclusiveRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1066:60: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsExclusiveRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1066:60: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsExclusiveRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h:1066:60: error: 'introduced' was not declared in this scope
const CFStringRef kCFURLVolumeSupportsExclusiveRenamingKey API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
^
make: *** [Release/obj.target/volume/src/volume.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: make failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/opt/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:276:23)
gyp ERR! stack at emitTwo (events.js:87:13)
gyp ERR! stack at ChildProcess.emit (events.js:172:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 16.0.0
gyp ERR! command "/opt/local/bin/node" "/opt/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/pasha/ZergFWD/node_modules/macos-alias
gyp ERR! node -v v4.4.7
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
npm WARN optional Skipping failed optional dependency /7zip-bin/7zip-bin-win:
npm WARN notsup Not compatible with your operating system or architecture: [email protected]
npm WARN optional Skipping failed optional dependency /7zip-bin/7zip-bin-linux:
npm WARN notsup Not compatible with your operating system or architecture: [email protected]
npm WARN [email protected] No repository field.
npm WARN [email protected] No license field.
npm ERR! Darwin 16.0.0
npm ERR! argv "/opt/local/bin/node" "/opt/local/bin/npm" "install" "macos-alias"
npm ERR! node v4.4.7
npm ERR! npm v3.10.5
npm ERR! code ELIFECYCLE

npm ERR! [email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the macos-alias package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs macos-alias
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls macos-alias
npm ERR! There is likely additional logging output above.

My configuration:

MacOS 10.12 (16A323)
Xcode 8.0 (8A218a)
CommandLineTools 1.12 for Xcode 8
npm 3.10.5 (installed via macports)
node version v4.4.7 (installed via macports)

Old OS X implementation and Node 0.12.x is incompatible

From discussion in #2

dyld: lazy symbol binding failed: Symbol not found: _FSGetCatalogInfo
  Referenced from: /Users/davide/Programmazione/node-alias/build/Release/volume.node
  Expected in: flat namespace

dyld: Symbol not found: _FSGetCatalogInfo
  Referenced from: /Users/davide/Programmazione/node-alias/build/Release/volume.node
  Expected in: flat namespace

New method to get Volume Name

The Volume Name currently is an empty string for the root path, (should be e.g. Macintosh HD).

Mounted volume that got a number appended to it also gets wrongly detected, (e.g. Test Title 1 when it should be Test Title).

Error: Module version mismatch. Expected 48, got 49.

Hi,

I'm getting an error when trying to require the module with node 6.3.0 and 6.4.0.

MacBook-Pro:wmail Tom$ node
> require('macos-alias')
Error: Module version mismatch. Expected 48, got 49.
    at Error (native)
    at Object.Module._extensions..node (module.js:583:18)
    at Module.load (module.js:473:32)
    at tryModuleLoad (module.js:432:12)
    at Function.Module._load (module.js:424:3)
    at Module.require (module.js:483:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/Users/Tom/GitHub/wmail/node_modules/macos-alias/lib/create.js:7:13)
    at Module._compile (module.js:556:32)
    at Object.Module._extensions..js (module.js:565:10)

I've tried removing node_modules and doing npm cache clean. I've tried running node-gyp rebuild in the directory but to no avail. Do you have any suggestions?

Thanks!

error: expected constructor, destructor, or type conversion before ‘<’ token

When building macos-alias from the Git repository with node-gyp rebuild I get the following error:

In file included from ../src/volume.cc:6:
../src/impl-apple.cc:28: error: expected constructor, destructor, or type conversion before ‘<’ token
make: *** [Release/obj.target/volume/src/volume.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/opt/local/lib/node_modules/node-gyp/lib/build.js:267:23)
gyp ERR! stack     at ChildProcess.EventEmitter.emit (events.js:98:17)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (child_process.js:797:12)
gyp ERR! System Darwin 10.8.0
gyp ERR! command "node" "/opt/local/bin/node-gyp" "rebuild"
gyp ERR! cwd /Users/davide/Programmazione/node-alias
gyp ERR! node -v v0.10.26
gyp ERR! node-gyp -v v0.13.0
gyp ERR! not ok 

I'm on Mac OS 10.6.

"This platform is not implemented yet" on Windows 10

The following exception happens running on Windows 10.

> [email protected] install C:\jenkins\workspace\UniletApp\node_modules\macos-alias
> node-gyp rebuild


C:\jenkins\workspace\UniletApp\node_modules\macos-alias>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node "" rebuild )
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
  volume.cc
  win_delay_load_hook.cc
..\src\volume.cc(9): fatal error C1189: #error:  This platform is not implemented yet [C:\jenkins\workspace\UniletApp\node_modules\macos-alias\build\volume.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:285:23)
gyp ERR! stack     at emitTwo (events.js:125:13)
gyp ERR! stack     at ChildProcess.emit (events.js:213:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:197:12)
gyp ERR! System Windows_NT 10.0.14393
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\jenkins\workspace\UniletApp\node_modules\macos-alias
gyp ERR! node -v v8.0.0
gyp ERR! node-gyp -v v3.6.1
gyp ERR! not ok

add isAlias

It could be fs.ReadStream-based so that scanning the first chunk(s) for 62 6F 6F 6B 00 00 00 00 6D 61 72 6B 00 00 00 00 [reference] can be performed prior to the file being fully loaded, followed by closing the stream.

I haven't used this library yet as supporting aliases quickly became more complicated than I'd thought it would be (I thought that they were symlinks!). Which leads me to my next question: can this library at least be installed on other operating systems?

Xcodebuild error when installing.

Having an issue when installing create-dmg and issues seems to being caused by macos-alias.
Xcode and Xcode CLI tools already currently installed.

➜  Desktop npm i -g create-dmg
/usr/local/bin/create-dmg -> /usr/local/lib/node_modules/create-dmg/cli.js

> [email protected] install /usr/local/lib/node_modules/create-dmg/node_modules/macos-alias
> node-gyp rebuild

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

No receipt for 'com.apple.pkg.CLTools_Executables' found at '/'.

No receipt for 'com.apple.pkg.DeveloperToolsCLILeo' found at '/'.

No receipt for 'com.apple.pkg.DeveloperToolsCLI' found at '/'.

gyp: No Xcode or CLT version detected!
gyp ERR! configure error 
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:336:16)
gyp ERR! stack     at emitTwo (events.js:125:13)
gyp ERR! stack     at ChildProcess.emit (events.js:213:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:197:12)
gyp ERR! System Darwin 17.0.0
gyp ERR! command "/usr/local/Cellar/node/8.1.0_1/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/local/lib/node_modules/create-dmg/node_modules/macos-alias
gyp ERR! node -v v8.1.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/meadowcottage/.npm/_logs/2017-06-22T13_20_18_842Z-debug.log

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.