【问题标题】:I am having issue seeing jekyll in browser. Nothing appears when I type 'localhost:4000' into url我在浏览器中看到 jekyll 时遇到问题。当我在 url 中输入 'localhost:4000' 时什么都没有出现
【发布时间】:2014-10-23 21:07:37
【问题描述】:

我是新手,所以希望当我问这个问题时我是有道理的。

我在 Windows 7 上通过命令提示符执行此操作。

我已经安装了 jekyll,但无法查看 jekyll 网页。什么都没有出现。我在写“jekkyl serve”时看到的是:

c:\users\spiridon\desktop\portfolio\jekyll serve
Configuration file: c:users/spiridon/desktop/portfolio/_config.yml
source:  c:users/spiridon/desktop/portfolio
destination: : c:users/spiridon/desktop/portfolio/_site
generating...
c:/ruby193/lib/ruby/gems/1.9.1/gems/posix-spawn-0.3.9/lib/posix/spawn.rb:164: warning: cannot close fd before spawn
'which' is not recognized as an internal or external command, operable program or batch file.
←[31m Liquid Exception: no such file or directory - python c:/ruby193/lib/ruby/gems/1.9.1/gems/pygments/mentos.py in _posts/2014-10-23-welcome-to-jekyll.markdown←[0m
done.
Please add the following to your Gemfile to avoid polling for changes:
require 'rbconfig'
if RBConfig: :CONFIG['target_os'] =~ /mswin|mingw|cygwin/i
gem 'wdm', >= 0.1.0'
end
Auto-regeneration: enabled for 'c:/users/spiridon/desktop/portfolio'
Configuration file: c:/users/spiridon/desktop/portfolio/_config.yml
server address: http://0.0.0.0:4000/
server running... press ctrl-c to stop.

我正在使用 ruby​​193 杰基尔 2.4.0

这是我的 _config.yml:

# Site settings
title: Your awesome title
email: your-email@domain.com
description: > # this means to ignore newlines until "baseurl:"
Write an awesome description for your new site here. You can edit this
line in _config.yml. It will appear in your document head meta (for
Google search results) and in your feed.xml site description.
baseurl: "" # the subpath of your site, e.g. /blog/
url: "http://yourdomain.com" # the base hostname & protocol for your site
twitter_username: jekyllrb
github_username:  jekyll

# Build settings
markdown: kramdown

我对这种语言和大多数其他编程语言都是全新的。我还观看了 youtube 视频并在线搜索解决方案,但找不到任何东西。谢谢。

【问题讨论】:

    标签: ruby rubygems jekyll


    【解决方案1】:

    来自 Jekyll 主页

    虽然 Windows 不是官方支持的平台,但它可以使用 通过适当的调整来运行 Jekyll。

    请按照this page dedicated to hints to get Jekyll running on Windows 上的所有说明操作或试试这个Jekyll Windows project

    一旦您遵循上述提示之一,您得到的错误可能会消失,但仍然是一个简短的解释:

    'which' is not recognized as an internal or external command, operable program or batch file.

    即windows没有名为which的程序。 这在 Windows 系统上不存在。在 unixoid 系统上,它用于解析当您运行作为属性给定的命令时究竟执行了什么。

    来自维基百科:

    在 Internet 协议版本 4 中,地址 0.0.0.0 是不可路由的元地址,用于指定无效、未知或不适用的目标。

    所以在浏览器中打开它不起作用也就不足为奇了。 Jekyll 无法启动服务器,因为它遇到错误。所以它将这个通用 IP 显示为服务器地址。

    【讨论】:

      猜你喜欢
      • 2021-10-14
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2022-01-12
      • 1970-01-01
      • 2022-11-11
      • 1970-01-01
      • 2013-09-01
      相关资源
      最近更新 更多