草庐IT

chef_gem

全部标签

windows - Chef - Powershell 输出

我最近升级到Windows10,在运行knife命令时我注意到一个非常奇怪/恼人的问题。当我在powershell控制台中运行它时:$nodes=knifenodelist$nodes的值为$null并且我所有的节点都列在控制台窗口中,而不是被捕获并存储在$nodes变量。当我从PowershellISE运行相同的命令时,它按预期运行,其中$nodes的值包含我的节点列表。我尝试了几种变体,结果都是一样的......$nodes=&knifenodelist$nodes=Invoke-Expression-Command'knifenodelist'$nodes=$(Invoke-Ex

ruby - GemCutter rake build 现在抛出 "undefined method ' write' for #<Syck::Emitter:...."在 Windows 上的 ruby​​ 1.9.2 上更新到 ruby​​gems 1.5.0 之后

我刚刚将我的Windows2008Serverx64box更新为ruby​​gems1.5.0,现在我无法使用Gemcutter提供的rake任务(rakeclobberbuild)构建gem。我收到以下错误:rakeaborted!undefinedmethod`write'for#C:/Ruby192/lib/ruby/1.9.1/psych/visitors/emitter.rb:17:in`end_document'C:/Ruby192/lib/ruby/1.9.1/psych/visitors/emitter.rb:17:in`visit_Psych_Nodes_Docume

ruby - 我无法在 Windows 上安装 rmagick gem

我使用了ruby​​1.9.2和rails3.0.3。我正在尝试安装rmagickgem,但是当我运行bundleinstall时,我收到一条错误消息:Installingrmagick(2.12.1)withnativeextensionsc:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:529:in`rescueinblockinbuild_extensions':ERROR:Failedtobuildgemnativeextension.(Gem::Installer::ExtensionBuildError)c:

ruby - 在 Windows 8.1 中使用 gem 安装 sass 时出错

我在windows8.1专业版中安装ruby​​ruby2.1.3p242(2014-09-19revision47630)[x64-mingw32]和gem版本2.2.2在执行gem安装时抛出这个错误:ERROR:Loadingcommand:install(ArgumentError)unknownencodingname-CP720ERROR:Whileexecutinggem...(NoMethodError)undefinedmethod`invoke_with_build_args'fornil:NilClass 最佳答案

windows - 如何阻止 'gem' 实用程序访问我的主目录?

当我运行时geminstall命令gem实用程序尝试访问我的主目录。它包含一些非拉丁字符,因此安装失败。例如:E:\ruby\bin>geminstallERROR:Whileexecutinggem...(Errno::ENOENT)Nosuchfileordirectory-C:\DocumentsandSettings\如果我切换到另一个用户名包含ASCII字符的用户帐户,只有gem可以正常工作。有人知道如何告诉gem不要检查我的主目录吗?更新:我尝试按照下面的建议设置GEM_HOME,但没有帮助(仍然检查用户主目录) 最佳答案

ruby-on-rails - Windows 7 64 位 : Could not find a valid gem 'compass' (>= 0), 这里就是为什么 : Unable to download data from https://rubygems. org/

我无法安装compass。我想在我的项目上安装compass,所以当我尝试更新时,我得到了这个:c:\wamp\www\danjasnowski.com>geminstallcompassERROR:Couldnotfindavalidgem'compass'(>=0),hereiswhy:Unabletodownloaddatafromhttps://rubygems.org/-SSL_connectreturned=1errno=0state=SSLv3readservercertificateB:certificateverifyfailed(https://api.rubyge

ruby-on-rails - 如何卸载 Windows 上的所有 ruby gem ?

如何在Windows上卸载所有ruby​​gem?是否可以使用单个命令? 最佳答案 一条线来统治他们。不需要电源外壳。从命令提示符运行:ruby-e"`gemlist`.split(/$/).each{|line|puts`gemuninstall-Iax#{line.split('')[0]}`unlessline.empty?}"只需复制/粘贴即可! 关于ruby-on-rails-如何卸载Windows上的所有rubygem?,我们在StackOverflow上找到一个类似的问题:

ruby-on-rails - 无法在 Windows 上安装 pg gem

我有2个Ruby版本:1.8.7和1.9.2以及PostgreSQL8.3。我无法在其中任何一个上安装pggem。收到此错误:C:/Development/Ruby187/bin/ruby.exeextconf.rbcheckingforpg_config...yesnotrecordedcheckingforlibpq-fe.h...noCan'tfindthe'libpq-fe.hheader***extconf.rbfailed***CouldnotcreateMakefileduetosomereason,probablylackofnecessarylibrariesand/

windows - 如何为 gem 设置代理服务器?

我无法通过命令提示符安装SASS。我尝试了以下步骤c:\geminstallsass我遇到以下错误:ERROR:Couldnotfindavalidgem'sass'(>=0),hereiswhy:Unabletodownloaddatafromhttps://rubygems.org/-Errno::ECONNREFUSED:Noconnectioncouldbemadebecausethetargetmachineactivelyrefusedit.-connect(2)(https://rubygems.org/latest_specs.4.8.gz)请帮帮我,

ruby-on-rails - 如何在 Redis 对象 gem 中使用 hash_key?

我需要使用redis-objects将哈希存储到Redis中gem。从README中,他们有hash_key。但是没有这方面的例子。我得到一个错误:NoMethodError:undefinedmethod`fantasy_points_details='for#当我这样做时:inning_player_instance.fantasy_points_details={a:1}对于这样的模型:classInningPlayer但是setter/getter起作用了:>inning_player_instance.fantasy_points_details=>#