启动 Clojure 应用程序的 foreman 时出现问题

发布于 2024-11-27 09:46:52 字数 2256 浏览 0 评论 0原文

我尝试按照在 Heroku 上获取 Clojure 应用程序的指南进行操作。除了在本地运行之外,一切正常。我使用的是 Windows 7。

该步骤显示:

  1. gem install foreman
  2. foreman start

On 1 我必须是管理员,但安装正常

当我执行 2 时,我得到:

C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': no such file to load -- pty (LoadError)
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1/gems/foreman-0.19.0/lib/foreman/engine.rb:4:in `<top (required)>'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1/gems/foreman-0.19.0/lib/foreman/cli.rb:2:in `<top (required)>'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1/gems/foreman-0.19.0/bin/foreman:5:in `<top (required)>'
        from C:/Program Files (x86)/Ruby192/bin/foreman:19:in `load'
        from C:/Program Files (x86)/Ruby192/bin/foreman:19:in `<main>'

我缺少什么?

当我运行 gem 环境时,我得到:

RubyGems Environment:
  - RUBYGEMS VERSION: 1.8.6
  - RUBY VERSION: 1.9.2 (2011-02-18 patchlevel 180) [i386-mingw32]
  - INSTALLATION DIRECTORY: C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1
  - RUBY EXECUTABLE: "C:/Program Files (x86)/Ruby192/bin/ruby.exe"
  - EXECUTABLE DIRECTORY: C:/Program Files (x86)/Ruby192/bin
  - RUBYGEMS PLATFORMS:
    - ruby
    - x86-mingw32
  - GEM PATHS:
     - C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1
     - C:/Users/henrik/.gem/ruby/1.9.1
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :benchmark => false
     - :backtrace => false
     - :bulk_threshold => 1000
  - REMOTE SOURCES:
     - http://rubygems.org/

I'm tried to follow the guide on getting a Clojure app on Heroku. Everything works fine except running it locally. I'm using Windows 7.

The step says:

  1. gem install foreman
  2. foreman start

On 1 I had to be admin, but the installation went ok

When I execute 2 I get:

C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': no such file to load -- pty (LoadError)
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1/gems/foreman-0.19.0/lib/foreman/engine.rb:4:in `<top (required)>'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1/gems/foreman-0.19.0/lib/foreman/cli.rb:2:in `<top (required)>'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1/gems/foreman-0.19.0/bin/foreman:5:in `<top (required)>'
        from C:/Program Files (x86)/Ruby192/bin/foreman:19:in `load'
        from C:/Program Files (x86)/Ruby192/bin/foreman:19:in `<main>'

What am I missing?

When I run gem environment I get:

RubyGems Environment:
  - RUBYGEMS VERSION: 1.8.6
  - RUBY VERSION: 1.9.2 (2011-02-18 patchlevel 180) [i386-mingw32]
  - INSTALLATION DIRECTORY: C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1
  - RUBY EXECUTABLE: "C:/Program Files (x86)/Ruby192/bin/ruby.exe"
  - EXECUTABLE DIRECTORY: C:/Program Files (x86)/Ruby192/bin
  - RUBYGEMS PLATFORMS:
    - ruby
    - x86-mingw32
  - GEM PATHS:
     - C:/Program Files (x86)/Ruby192/lib/ruby/gems/1.9.1
     - C:/Users/henrik/.gem/ruby/1.9.1
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :benchmark => false
     - :backtrace => false
     - :bulk_threshold => 1000
  - REMOTE SOURCES:
     - http://rubygems.org/

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

冷血 2024-12-04 09:46:52

替换我的第一个答案,因为它完全不合时宜。

看起来 pty 是标准 Ruby 的一部分: http ://ruby-doc.org/stdlib/libdoc/pty/rdoc/index.html

但是,根据 这篇旧论坛帖子,看起来 Ruby 的 pty 需要一些在 Windows 上实现起来不太简单的东西,所以很可能它在 Windows 上不可用Windows此时也可以。

Replacing my first answer, as it was entirely off-the-mark.

Looks like pty is part of standard Ruby: http://ruby-doc.org/stdlib/libdoc/pty/rdoc/index.html

However, based on a cursory glance of this old forum post, it looks like Ruby's pty requires some things which are less-than-straightforward to implement on Windows, so it's very possible it's not available on Windows at this point either.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文