Je veux exécuter le script dans le gestionnaire d'extensions Brackets lors de l'installation de mon extension.comment exécuter le script entre parenthèses extension package.json?
Vous avez trouvé ce code dans l'extension par défaut 'JavaScriptCodeHints' de Brackets. Même utilisation de "postinstall": "node ./test", mais affiche ce message d'erreur.
npm-stderr: sh: node: command not found
npm WARN [email protected] No description
npm WARN [email protected] No repository field.
npm WARN [email protected] No license field.
npm ERR! Darwin 16.7.0
npm ERR! argv "/Applications/Brackets.app/Contents/MacOS/Brackets-node" "/Applications/Brackets.app/Contents/www/node_modules/npm/bin/npm-cli.js" "install" "--production"
npm ERR! node v6.3.1
npm ERR! npm v3.10.9
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! [email protected] postinstall: `node ./test`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] postinstall script 'node ./test'.
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 testExtensionInstaller package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node ./test
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs testExtensionInstaller
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls testExtensionInstaller
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /private/var/folders/1y/bd63w8h51wzccq_zbw6804440000gn/T/bracketsPackage_117723-46419-zgk6x5.ki3sicc8fr/testExtensionInstaller/npm-debug.log
comment utiliser le noeud sans installer nodejs dans l'installation de l'extension Brackets?
Je vois ça. mais l'extension par défaut est installée sans nodejs et l'environnement PATH. – Amadas
Veuillez vérifier si le chemin du noeud est dans l'environnement d'exécution brackets-nodejs en exécutant le fichier suivant en utilisant l'extension: 'console.log (process.env.PATH);' – Bamieh
son extension par défaut, donc installé avec des crochets (extension interne). donc je ne peux pas ajouter de code avant de construire le support. https://github.com/adobe/brackets/tree/master/src/extensions/default/JavaScriptCodeHints est l'extension par défaut github url – Amadas