0

I try to install angularJs (https://docs.angularjs.org/tutorial) When i do npm install some package can't install and i got error

I don't handle protocol '[https'

I tried to write :

{ "proxy" : "http://<host>:<port>", "https-proxy" : "http://<host>:<port>" }

into .bowerrc and the command git config --global url."https://".insteadOf git:// but not working neither

If i install manually the package with git clone, some packages pass, some won't and still saying

I don't handle protocol '[https'

I don't handle protocol '[https'

full error :

bower ECMDERR Failed to execute "git ls-remote --tags --heads git://github.com/angular/bower-angular-mocks.git", exit code of #128 fatal: I don't handle protocol '[https'

i'm on kubuntu

npm config get

; cli configs
registry = "https://registry.npmjs.org/"

; builtin config undefined
# DO NOT MODIFY THIS FILE - use /etc/npmrc instead. = true
globalconfig = "/etc/npmrc"
globalignorefile = "/etc/npmignore"
prefix = "/usr/local"

; node bin location = /usr/bin/nodejs
; cwd = /home/marvin/angular-phonecat
; HOME = /home/marvin
; 'npm config ls -l' to show all defaults.

npm config ls -l

; cli configs
long = true
registry = "https://registry.npmjs.org/"

; builtin config undefined
# DO NOT MODIFY THIS FILE - use /etc/npmrc instead. = true
globalconfig = "/etc/npmrc"
globalignorefile = "/etc/npmignore"
prefix = "/usr/local"

; default values
always-auth = false
bin-links = true
browser = null
cache = "/home/marvin/.npm"
cache-lock-retries = 10
cache-lock-stale = 60000
cache-lock-wait = 10000
cache-max = null
cache-min = 10
color = true
coverage = false
depth = null
description = true
dev = false
editor = "vi"
engine-strict = false
fetch-retries = 2
fetch-retry-factor = 10
fetch-retry-maxtimeout = 60000
fetch-retry-mintimeout = 10000
force = false
git = "git"
global = false
; globalconfig = "/usr/local/etc/npmrc" (overridden)
; globalignorefile = "/usr/local/etc/npmignore" (overridden)
group = 1000
https-proxy = null
ignore = ""
init-module = "/home/marvin/.npm-init.js"
init.author.email = ""
init.author.name = ""
init.author.url = ""
init.version = "0.0.0"
json = false
link = false
loglevel = "http"
; long = false (overridden)
message = "%s"
node-version = "v0.10.25"
npat = false
npaturl = "http://npat.npmjs.org/"
onload-script = false
optional = true
parseable = false
pre = false
; prefix = "/usr" (overridden)
production = false
proprietary-attribs = true
proxy = null
rebuild-bundle = true
registry = "https://registry.npmjs.org/"
rollback = true
save = false
save-bundle = false
save-dev = false
save-optional = false
searchexclude = null
searchopts = ""
searchsort = "name"
shell = "/bin/bash"
shrinkwrap = true
sign-git-tag = false
strict-ssl = true
tag = "latest"
tmp = "/home/marvin/tmp"
umask = 18
unicode = true
unsafe-perm = true
usage = false
user = 0
user-agent = "node/v0.10.25 linux x64"
userconfig = "/home/marvin/.npmrc"
userignorefile = "/home/marvin/.npmignore"
username = ""
version = false
versions = false
viewer = "man"
yes = null
ramsey_lewis
  • 558
  • 8
  • 25
  • Did you set npm proxy as well? – Shaohao Feb 11 '16 at 19:16
  • Hello, I don't have proxy server...i guess. I'm conneccted directlyto internet. thanks – ramsey_lewis Feb 11 '16 at 19:24
  • Oh, what I mean is you might have a proxy for the internet. And if you do have proxy, you need to set up `npm` and `bower` by pass the proxy to install anything from the internet. Please check if you have proxy set up for your environment or not. – Shaohao Feb 11 '16 at 19:30
  • It seem i have a proxy at home, from my ISP. But i tried with 3 differents internet connection, even with my 4G network, do you think proxies can block me on every connection ? – ramsey_lewis Feb 11 '16 at 21:09
  • try `npm config get` in the command line. And post your result. – Shaohao Feb 11 '16 at 21:13
  • i edited my post, thanks for your help – ramsey_lewis Feb 11 '16 at 21:59

1 Answers1

2

I finally found a way to make it work :

git: convert "git" urls to "http" urls

Here's an example of rewriting the default protocol for GitHub: git config --global url.https://github.com/.insteadOf git://github.com/

Community
  • 1
  • 1
ramsey_lewis
  • 558
  • 8
  • 25