如何设置代理命令提示符? [英] how to set proxy for command prompt?

查看:269
本文介绍了如何设置代理命令提示符?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我无法通过命令提示符安装SASS。



我尝试了以下步骤



c:\gem install sass



我得到以下错误。



错误:找不到有效的gem'sass'(> = 0),这是为什么:
无法从 https://rubygems.org/ 下载数据 - Errno :: ECONNREFUSED:无法建立连接,因为目标计算机主动拒绝了。 - connect(2)( https://rubygems.org/latest_specs.4.8.gz



对于具有或不具有身份验证的http / https代理,

解决方案

p>

在cmd.exe中运行以下命令之一

  set http_proxy = http:// your_proxy:your_port 
set http_proxy = http:// username:password @ your_proxy:your_port
set https_proxy = https:// your_proxy:your_port
set https_proxy = https:// username:password @ your_proxy:your_port


I am unable to install SASS through command prompt.

I tried below steps

c:\gem install sass

I am getting below error.

ERROR: Could not find a valid gem 'sass' (>= 0), here is why: Unable to download data from https://rubygems.org/ - Errno::ECONNREFUSED: No connection could be made because the target machine actively refused it. - connect(2) (https://rubygems.org/latest_specs.4.8.gz)

Please help me,

解决方案

For http/https proxy with or without authentication:

Run one of the following commands in cmd.exe

set http_proxy=http://your_proxy:your_port
set http_proxy=http://username:password@your_proxy:your_port
set https_proxy=https://your_proxy:your_port
set https_proxy=https://username:password@your_proxy:your_port

这篇关于如何设置代理命令提示符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆