xdan / datetimepicker

jQuery Plugin Date and Time Picker
https://xdsoft.net/jqplugins/datetimepicker/
MIT License
3.5k stars 1.51k forks source link

Issues building datetimepicker #556

Open NiclasEsser1 opened 7 years ago

NiclasEsser1 commented 7 years ago

Hello, i followed the instructions of the Readme.md to install the datetimepicker. All works fine until i want to 'npm run buld'. The Errormessage below cames out:

root@raspberrypi:/var/www/html/bootstrap/datetimepicker# npm run build

jquery-datetimepicker@2.5.4 build /var/www/html/bootstrap/datetimepicker npm run minify && npm run concat && npm run minifyconcat

jquery-datetimepicker@2.5.4 minify /var/www/html/bootstrap/datetimepicker uglifyjs jquery.datetimepicker.js -c -m -o build/jquery.datetimepicker.min.js && uglifycss jquery.datetimepicker.css > build/jquery.datetimepicker.min.css

WARN: Dropping unused function argument pseudo [jquery.datetimepicker.js:676,42] WARN: Dropping unused function argument dTime [jquery.datetimepicker.js:1309,37] WARN: Dropping unused variable throttle [jquery.datetimepicker.js:935,4] (node:20001) DeprecationWarning: util.error is deprecated. Use console.error instead.

jquery-datetimepicker@2.5.4 concat /var/www/html/bootstrap/datetimepicker concat-cli -f bower_components/php-date-formatter/js/php-date-formatter.js jquery.datetimepicker.js

bower_components/jquery-mousewheel/jquery.mousewheel.js -o build/jquery.datetimepicker.full.js

/var/www/html/bootstrap/datetimepicker/node_modules/concat-cli/concatFunctions/index.js:11 throw new Error(error); ^

Error: Error: ENOENT: no such file or directory, open 'bower_components/php-date-formatter/js/php-date-formatter.js' at errorHandler (/var/www/html/bootstrap/datetimepicker/node_modules/concat-cli/concatFunctions/index.js:11:15) at /var/www/html/bootstrap/datetimepicker/node_modules/concat-cli/concatFunctions/index.js:23:9 at next (/var/www/html/bootstrap/datetimepicker/node_modules/serial-loop/index.js:10:25) at ReadFileContext.callback (/var/www/html/bootstrap/datetimepicker/node_modules/concat/index.js:14:27) at FSReqWrap.readFileAfterOpen [as oncomplete] (fs.js:357:13)

npm ERR! Linux 4.4.38-v7+ npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "run" "concat" npm ERR! node v7.6.0 npm ERR! npm v4.1.2 npm ERR! code ELIFECYCLE npm ERR! jquery-datetimepicker@2.5.4 concat: concat-cli -f bower_components/php-date-formatter/js/php-date-formatter.js jquery.datetimepicker.js bower_components/jquery-mousewheel/jquery.mousewheel.js -o build/jquery.datetimepicker.full.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the jquery-datetimepicker@2.5.4 concat script 'concat-cli -f bower_components/php-date-formatter/js/php-date-formatter.js jquery.datetimepicker.js bower_components/jquery-mousewheel/jquery.mousewheel.js -o build/jquery.datetimepicker.full.js'. 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 jquery-datetimepicker package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! concat-cli -f bower_components/php-date-formatter/js/php-date-formatter.js jquery.datetimepicker.js bower_components/jquery-mousewheel/jquery.mousewheel.js -o build/jquery.datetimepicker.full.js npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs jquery-datetimepicker npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm owner ls jquery-datetimepicker npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /var/www/html/bootstrap/datetimepicker/npm-debug.log

npm ERR! Linux 4.4.38-v7+ npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "run" "build" npm ERR! node v7.6.0 npm ERR! npm v4.1.2 npm ERR! code ELIFECYCLE npm ERR! jquery-datetimepicker@2.5.4 build: npm run minify && npm run concat && npm run minifyconcat npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the jquery-datetimepicker@2.5.4 build script 'npm run minify && npm run concat && npm run minifyconcat'. 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 jquery-datetimepicker package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! npm run minify && npm run concat && npm run minifyconcat npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs jquery-datetimepicker npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm owner ls jquery-datetimepicker npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /var/www/html/bootstrap/datetimepicker/npm-debug.log

I'm a bit desperite, cause I used bootstrap for a few HTML-formular and i really need this datetimepicker. I use a RaspberryPi3 with the Debian distribution Jessie, npm and nodejs are on the latest version. I really need to solve this problem, big thanks for every help!

ycx0303 commented 7 years ago

I hava the same problem with the step "npm run build", the Errormessage is: E:\project\test> npm run build npm ERR! Windows_NT 6.1.7601 npm ERR! argv "E:\project\nodejs\node.exe" "E:\project\nodejs\node_modules\npm\bin\npm-cli.js" "run" "build" npm ERR! node v6.10.0 npm ERR! npm v3.10.10

npm ERR! missing script: build npm ERR! npm ERR! If you need help, you may report this error at: npm ERR! https://github.com/npm/npm/issues npm ERR! Please include the following file with any support request: npm ERR! E:\project\test\npm-debug.log

what should I do ??

NiclasEsser1 commented 7 years ago

Hi,

I could not fix this Error, but it seems like you're running an Linux command on a Windows? Am I wrong?

I have found an other solution to use the DateTimePicker! It is not the best, because you need to refer the CSS and JS via an Internetadress and also have access to the Internet, but the the two different datetimepicker running without issues. Try this: http://pastebin.com/uAtScGnZ

akincer commented 7 years ago

I fixed it by running bower install php-date-formatter