मैं इस साल पेड़ के नीचे रास्पबेरी पाई पाने के लिए काफी भाग्यशाली था और मैंने डिवाइस पर Node.js के साथ खेलने में थोड़ा मज़ा किया है। हालाँकि, जब आप संकुल को खींच सकते हैं और उन्हें अपने अनुप्रयोगों में प्लग कर सकते हैं, तो Node.js बहुत अधिक दिलचस्प है - और यह वह जगह है जहाँ मुझे कुछ परेशानी हो रही है।
यदि मैं Node.js के साथ एनपीएम को निम्नलिखित कमांड के साथ स्थापित करने का प्रयास करता हूं:
sudo apt-get install nodejs npm
मुझे निम्नलिखित त्रुटि मिलती है:
pi@raspberrypi ~ $ sudo apt-get install nodejs npm
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
nodejs : Breaks: npm (< 1.1.4~dfsg-2~) but 1.1.4~dfsg-1 is to be installed
npm : Depends: node-semver but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
मैं बहुत नया हूं कि डेबियन-आधारित लिनक्स ऑपरेटिंग सिस्टम के साथ पैकेज प्रबंधन कैसे काम करता है और यह बिल्कुल नहीं जानता कि नोड.जेएस समुदाय ने अपने विशिष्ट पैकेजों को कैसे संरचित किया है। यह ध्यान देने योग्य है कि अपने आप ही नोड.जेएस स्थापित करना ठीक काम करता है, और अगर मैं एनपीएम को केवल अपने आप से स्थापित करने का प्रयास करता हूं तो मुझे यही मिलता है।
pi@raspberrypi ~ $ sudo apt-get install npm
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
npm : Depends: nodejs but it is not going to be installed
Depends: nodejs-dev but it is not going to be installed
Depends: node-request but it is not going to be installed
Depends: node-mkdirp but it is not going to be installed
Depends: node-minimatch but it is not going to be installed
Depends: node-semver but it is not going to be installed
Depends: node-ini but it is not going to be installed
Depends: node-graceful-fs but it is not going to be installed
Depends: node-abbrev but it is not going to be installed
Depends: node-nopt but it is not going to be installed
Depends: node-fstream but it is not going to be installed
Depends: node-rimraf but it is not going to be installed
Depends: node-tar but it is not going to be installed
Depends: node-which but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
मुझे यकीन नहीं है, लेकिन मेरी आंत मुझे बता रही है कि node-semver
पैकेज के साथ कुछ करना है । अगर मैं nodejs
पैकेज को खुद से स्थापित करता हूं और फिर इसे स्थापित करने का प्रयास node-semver
करता हूं जो मुझे मिलता है।
pi@raspberrypi ~ $ sudo apt-get install node-semver
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
node-semver : Depends: nodejs but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
कोई संकेत?