$ nvm install stable
######################################################################## 100.0%
mv: cannot move ‘/home/me/.nvm/bin/node-v0.12.7-linux-x64’ to ‘/home/me/.nvm/versions/v0.12.7’: No such file or directory
Binary download failed, trying source.
######################################################################## 100.0%
File "./configure", line 362
'''
^
SyntaxError: Missing parentheses in call to 'print'
nvm: install v0.12.7 failed!
This is on a manjaro linux box, running nvm version 0.20.0.
I tried directly with
nvm install v0.12.7 or
nvm install 0.12.7 and also
nvm install 0.12.6
all reported the same error.
I also tried re-running the nvm installation script, but it told me it already had nvm installed. I am a bit reluctant to delete .nvm and re-install it (for no obvious reason ;) )
I don't know what causes the first problem:
mv: cannot move ‘/home/me/.nvm/bin/node-v0.12.7-linux-x64’ to ‘/home/me/.nvm/versions/v0.12.7’: No such file or directory
Binary download failed, trying source.
But then it tries from source and tries to compile, using python. The error :
SyntaxError: Missing parentheses in call to 'print'
is from python - python3. By temporarily changin the symlink in manjaro from
/usr/bin/python -> python3 to
/usr/bin/python -> python2
I seam to have "solved" the issue....
Related
can anyone please help me with this issue? I had node installed then I uninstalled and rm -rf the file as well following some online suggestions. Then now I am trying to install it like i had done before using nvm install node
but now i am getting the following error:
Downloading and installing node v15.2.1...
Local cache found: ${NVM_DIR}/.cache/bin/node-v15.2.1-linux-x64/node-v15.2.1-linux-x64.tar.xz
Checksums match! Using existing downloaded archive ${NVM_DIR}/.cache/bin/node-v15.2.1-linux-x64/node-v15.2.1-linux-x64.tar.xz
mv: cannot move '/home/jan/.nvm/.cache/bin/node-v15.2.1-linux-x64/files/bin' to '/home/jan/.nvm/versions/node/v15.2.1/bin': Directory not empty
mv: cannot move '/home/jan/.nvm/.cache/bin/node-v15.2.1-linux-x64/files/include' to '/home/jan/.nvm/versions/node/v15.2.1/include': Directory not empty
mv: cannot move '/home/jan/.nvm/.cache/bin/node-v15.2.1-linux-x64/files/lib' to '/home/jan/.nvm/versions/node/v15.2.1/lib': Directory not empty
mv: cannot move '/home/jan/.nvm/.cache/bin/node-v15.2.1-linux-x64/files/share' to '/home/jan/.nvm/versions/node/v15.2.1/share': Directory not empty
Binary download failed, trying source.
Local cache found: ${NVM_DIR}/.cache/src/node-v15.2.1/node-v15.2.1.tar.xz
Checksums match! Using existing downloaded archive ${NVM_DIR}/.cache/src/node-v15.2.1/node-v15.2.1.tar.xz
$>./configure --prefix=/home/jan/.nvm/versions/node/v15.2.1 <
Traceback (most recent call last):
File "./configure", line 20, in <module>
from distutils.spawn import find_executable
ModuleNotFoundError: No module named 'distutils.spawn'
nvm: install v15.2.1 failed!
Thanks
To get this version, you can use the apt package manager. Refresh your local package index by typing:
sudo apt-get update
Install Node.js from the repositories:
sudo apt-get install nodejs
To check which version of Node.js you have installed after these initial steps, type:
nodejs -v
You just need to uninstall that version of node via nvm before reinstalling it.
nvm uninstall 15.2.1
nvm install 15.2.1
I'm aware that the error is because node.js and npm weren't installed in /usr/bin
its in /file/file/nodejs/bin
but editing the .bash_profile and adding :/file/file/nodejs/bin to $PATH is still returning the same error.
PATH=$PATH:$HOME/.local/bin:$HOME/bin:/file/file/nodejs/bin
export PATH
any help would be greatly appreciated, I can't move where it was installed because it's on a VM that I don't have full access to, but I can edit the bash_profile
In ubuntu:
apt install nodejs
if you run nvm which, will see something similar /usr/bin/node
for install node version 16 run below commands:
nvm install 16
nvm use 16
node --version
/root/.nvm/versions/node/v16.15.0/bin/node
and so for install node version 10 run below commands:
nvm install 10
nvm use 10
node --version
/root/.nvm/versions/node/v10.x.y/bin/node
Hi I am trying to install nodejs in ubuntu 14 but getting following error.
E: Cannot get debconf version. Is debconf installed?
debconf: apt-extracttemplates failed: No such file or directory
Extracting templates from packages: 62%E: Cannot get debconf version. Is debconf installed?
debconf: apt-extracttemplates failed: No such file or directory
Extracting templates from packages: 100%
dpkg: cannot scan updates directory `/var/lib/dpkg/updates/': No such file or directory
E: Sub-process /usr/bin/dpkg returned an error code (2)
when trying to installing with software updated I am getting following error.
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/aptdaemon/worker.py", line 300, in _process_transaction
not self.is_dpkg_journal_clean()):
File "/usr/lib/python3/dist-packages/aptdaemon/worker.py", line 1111, in is_dpkg_journal_clean
for dentry in os.listdir(status_updates):
FileNotFoundError: [Errno 2] No such file or directory: '/var/lib/dpkg/updates/'
I had this problem previously, I removed any variables equivalent to zero and it solved it, perhaps try that.
Add the Node.js-maintained repositories to your Ubuntu package source list with this command:
curl -sL https://deb.nodesource.com/setup | sudo bash -
Then install Node.js with apt-get:
sudo apt-get install nodejs
Optionally we can create a symbolic link for node (for reasons mentioned earlier):
sudo ln -s /usr/bin/nodejs /usr/bin/node
Using this install option, we end up with newer versions of Node.js and npm:
$ node -v
$ npm -v
to check node version and npm version
I suggest installing nvm (node version manager)
https://github.com/creationix/nvm
it allows you to install and use ANY node version, and this may be way better, because ubuntu is bound to one specific version. In web development, every project is prepared using dofferen node, so switching it might be necessary
I've got NVM installed via homebrew, and I can execute an installation command just fine:
nvm install v5
Downloading https://nodejs.org/dist/v5.0.0/node-v5.0.0-darwin-x64.tar.xz...
######################################################################## 100.0%
WARNING: checksums are currently disabled for node.js v4.0 and later
But when I attempt to do nvm use v5, I get:
N/A: version "v5.0.0" is not yet installed
This occurs whether or not I make an alias for v5. I've uninstalled nvm, cleared out/re-added references in my dotfiles, etc.
I couldn't get the native shell script to work, so I just ended up installing n instead (https://github.com/tj/n)
When I run the command:
nvm install 0.10
I get this error:
tar: Error opening archive: Failed to open '-xzf'
Binary download failed, trying source.
######################################################################## 100.0%
tar: Error opening archive: Failed to open '-xzf'
nvm: install v0.10.26 failed!
What should I do to correct this?
Did you find your answer?
If not, you can try:
$ nvm install -s 0.10
The -s flag is used to compile from source and it worked for me.
I also wrote a blog post about that, if it can be helpful :)
Setting up nvm, node & npm on Mavericks
Hope it helps! :)