Hi folks,
I am trying to upgrade foreman-packaging/rpm/develop, so it will use a newer version of patternfly-react (2.29.0) but having some troubles with it.
Even tho I did it a few times before with no problem, this time it refuses to work.
1. Installed npm2rpm
➜ foreman-packaging git:(rpm/develop) npm install -g npm2rpm
➜ foreman-packaging git:(rpm/develop) cat /home/asharvit/.nvm/versions/node/v10.15.0/lib/node_modules/npm2rpm/package.json | grep version
"version": "3.1.0"
2. Try to create a bundled rpm:
➜ foreman-packaging git:(rpm/develop) ./add_npm_package.sh patternfly-react 2.29.0 bundle
Detected update...Making directory...rm 'packages/foreman/nodejs-patternfly-react/nodejs-patternfly-react.spec'
rm 'packages/foreman/nodejs-patternfly-react/patternfly-react-2.25.5.tgz'
FINISHED
Creating specs and downloading sources...---- npm2rpm ----
-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-
- Starting npm module download: https://registry.npmjs.org/patternfly-react/-/patternfly-react-2.29.0.tgz
- Unpacking in /tmp/npm2rpm-80821Y4QJmfKZbV4 ...
- Finished extracting for patternfly-react
- Reading package.json for patternfly-react
Warning: No README data
- Finished reading package.json for patternfly-react
- Fetching flattened list of production dependencies for patternfly-react
Callback must be a function
FINISHED
Copying specs...cp: cannot stat 'npm2rpm/SPECS/*': No such file or directory
3. Try to create a single rpm:
➜ foreman-packaging git:(rpm/develop) ./add_npm_package.sh patternfly-react 2.29.0 single
Detected update...Making directory...rm 'packages/foreman/nodejs-patternfly-react/nodejs-patternfly-react.spec'
rm 'packages/foreman/nodejs-patternfly-react/patternfly-react-2.25.5.tgz'
FINISHED
Creating specs and downloading sources...---- npm2rpm ----
-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-
- Starting npm module download: https://registry.npmjs.org/patternfly-react/-/patternfly-react-2.29.0.tgz
- Unpacking in /tmp/npm2rpm-8272ocTndxYzUrhe ...
- Finished extracting for patternfly-react
- Reading package.json for patternfly-react
Warning: No README data
- Finished reading package.json for patternfly-react
fs.js:129
throw new ERR_INVALID_CALLBACK();
^
TypeError [ERR_INVALID_CALLBACK]: Callback must be a function
at maybeCallback (fs.js:129:9)
at Object.writeFile (fs.js:1159:14)
at writeSpecFile (/home/asharvit/.nvm/versions/node/v10.15.0/lib/node_modules/npm2rpm/bin/npm2rpm.js:87:6)
at Extract.tar_extract.stream.on (/home/asharvit/.nvm/versions/node/v10.15.0/lib/node_modules/npm2rpm/bin/npm2rpm.js:78:5)
at Extract.emit (events.js:187:15)
at DirWriter.<anonymous> (/home/asharvit/.nvm/versions/node/v10.15.0/lib/node_modules/npm2rpm/node_modules/tar/lib/extract.js:81:8)
at DirWriter.emit (events.js:187:15)
at end (/home/asharvit/.nvm/versions/node/v10.15.0/lib/node_modules/npm2rpm/node_modules/fstream/lib/writer.js:324:14)
at /home/asharvit/.nvm/versions/node/v10.15.0/lib/node_modules/npm2rpm/node_modules/fstream/lib/writer.js:314:34
at endUtimes (/home/asharvit/.nvm/versions/node/v10.15.0/lib/node_modules/npm2rpm/node_modules/fstream/lib/writer.js:238:46)
Any help would be appreciated.
Thanks!