An issue arose while trying to create the perfect seed with yeoman

While working on my first Yeoman webapp using the ultimate-seed-generator, I encountered some errors that are hindering progress:

C:\Users\Fidel\Desktop\Nueva carpeta\new-proyect>npm install



> <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="32475e465b5f5346571f4157575672021c011c0300">[email protected]</a> preinstall C:\Users\Fidel\Desktop\Nueva carpeta\new-proyect
> node npm-scripts preinstall

npm preinstall script executed
\


> <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="552039213c38342130782630303115657b667b6467">[email protected]</a> postinstall C:\Users\Fidel\Desktop\Nueva carpeta\new-proyect
> node npm-scripts postinstall

npm postinstall script executed
{ [Error: Command failed: cp: invalid option -- n
Try `cp --help' for more information.
] killed: false, code: 1, signal: null }
-
npm ERR! <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="b6c3dac2dfdbd7c2d39bc5d3d3d2f6869885988784">[email protected]</a> postinstall: `node npm-scripts postinstall`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="bfcad3cbd6d2decbda92ccdadadbff8f918c918e8d">[email protected]</a> postinstall script.
npm ERR! This is most likely a problem with the ultimate-seed package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node npm-scripts postinstall
npm ERR! You can get their info via:
npm ERR!     npm owner ls ultimate-seed
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nod
ejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! cwd C:\Users\Fidel\Desktop\Nueva carpeta\new-proyect
npm ERR! node -v v0.10.29
npm ERR! npm -v 1.4.14
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     C:\Users\Fidel\Desktop\Nueva carpeta\new-proyect\npm-debug.log
npm ERR! not ok code 0

I believe both node js and yeoman were installed correctly. The issue may lie with compatibility between Window and yeoman. Does anyone have any insights on this?

Answer №1

The issue lies in the post-install script which relies on the unix cp command for copying files. Since you are using Windows, this method will not work properly.

To resolve this, you can execute the npm install command within cygwin or another unix-like shell on your Windows system.

It's worth noting that the package has been removed from npm -- I recommend finding a current alternative to use instead.

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

The callback function in AngularJS' $http is failing to trigger

$scope.submitNewUser = function() { $http({ method: 'POST', url: 'api/user/signup', data: {'user': $scope.user}, headers: {'Content-Type': ...

npm package construction failed

https://i.stack.imgur.com/bk9r2.png Whenever I attempt to execute the command npm run watch, I consistently encounter this error message. Can someone please assist me with resolving this issue? Click on the image to view the problem. Thank you in advance. ...

Error [ERR_MODULE_NOT_FOUND]: Module could not be located in vscode

Issue with VS Code: Module Not Found Error View the image associated with the erroreN.png ...

Fetching data from multiple URLs with an unknown quantity asynchronously

What would be the most efficient approach for performing an unknown quantity of asynchronous GET requests? Imagine you have a base URL, '', and you want to execute a series of asynchronous requests to various paths like: [ 'http://www. ...

An error is triggered when using db.listCollections() in an ExpressJS environment

I am currently working with ExpressJs and MongoDB, but I've encountered an issue with the following code: var db = monk(DB_URL); app.use(function (req, res, next) { req.db = db; next(); }); app.get("/view_collections", function (req, res) { ...

An error occurred while trying to access the property 'send' which is undefined

I am currently facing an issue while attempting to send data to the router from an external script. The error message that I receive is TypeError: Cannot read property 'send' of undefined Below is the code snippet: app.js var Cake = require(&a ...

What is the solution to fixing the JSON parsing error that says 'JSON.parse: bad control character in string literal'?

When sending data from NodeJS Backend to the client, I utilize the following code: res.end(filex.replace("<userdata>", JSON.stringify({name:user.name, uid:user._id, profile:user.profile}) )) //No errors occur here and the object is successfully stri ...

The process of setting a trial date on the Stripe dashboard pertains exclusively to referencing plans, rather than generating them within my app

Yesterday, I posted a question similar to this one but did not receive any response. The issue relates to tracking the end of a trial period for users who sign up and select a plan on my platform. The trial limit is set in the stripe dashboard, and I am no ...

The animation in an AngularJS directive only functions properly when utilizing $timeout

I can't seem to figure out why the animation is not working as intended in the code below: app.directive('openMenu', ['$animate', '$timeout', function($animate, $timeout) { return { link: function(scope, elem ...

When running `npm install @babel/cli`, warnings appeared for four deprecated modules. What steps can be taken to resolve these deprecations?

Overview of my current setup Operating System: MacOS Catalina 10.15.4 (latest) nvm Version: 0.35.3 (latest) node.js Version: 12.16.3 (latest LTS) - Installed using nvm directories npm Version: 6.14.4 (latest) - Installed using nvm directories Note: Avoi ...

Close the IonicPopup in Ionic when a button triggers an Ajax request

I am new to both Angular and Ionic. On my page, I have a popup that displays an input field for users to enter the OTP (One Time Password) along with a submit button. When the submit button is clicked, I make an Ajax call to check if the entered OTP is val ...

Is it possible to list bash/sh files as dependencies in package.json?

Currently, I have a bash script named publish.sh that I use for publishing modules to npm. Since I am constantly adjusting this script, I find myself needing to update every copy of it in each npm module I manage. Is there a method to include this bash sc ...

Tips for creating $http calls in AngularJS

Having some issues with my code, as I'm unsure of the correct placement for making an $http request to a local server. api.js var express = require('express'); var router = express.Router(); var mongoose = require('mongoose'); va ...

Once an item is added, the table vanishes into thin air

I have a DataTables setup to show a list of project names, and I have a button that should add an item to the displayed array. However, when I click the button, the table disappears. Below is the code snippet: view.html <button ng-click="vm.add()"> ...

What is the best way to combine arrays?

Here is the array retrieved from the database: [ { "_id": "58144e6c0c8d7534f4307269", "doctor_id": "5813221ace684e2b3f5f0a6d", "prescription": [ { "_id": "58144e6c0c8d7534f430726a", "medicine_id": "1001124 ...

Solution: "The Mongoose Model.find method consistently provides an empty result set."

Currently, I am utilizing mongoose in combination with next.js to interact with an existing collection. Despite the collection not being empty, the mongoose model.find() function consistently returns an empty array. Below is my model code: const mongoose ...

Configuration for secondary dependencies in Tailwind

As per the guidelines outlined in the official documentation, it is recommended to configure Tailwind to scan reusable components for class names when using them across multiple projects: If you’ve created your own set of components styled with Tailwin ...

Having trouble accessing the $scope property value in AngularJS

1. script.js var appProfileInfo = angular.module('profileInfoApp', ['ngMaterial','ngAria','ngAnimate','ngRoute' ]); 2. messageController.js appProfileInfo.controller('messageController', functi ...

Guide for Deploying Firebase Function on Heroku for Google Assistant Integration

I have developed a straightforward function for Google Assistant (using Dialogflow) within a Firebase function with the following structure: functions/ node_module/ index.js package-lock.json package.json firebase.json I am looking t ...

Preventing the callback nightmare in nodeJs / Sharing variables with nested functions

Let's simplify this scenario: const generateUrl = (req, res) => { const id = req.query.someParameter; const query = MyMongooseModel.findOne({'id': id}); query.exec((err, mongooseModel) => { if(err) { / ...