Hexo: 最新版hexo在deploy之后会收到一封GitHub pages不支持jekyll主题的邮件

Created on 29 May 2017  ·  10Comments  ·  Source: hexojs/hexo

Environment Info

Node version(node -v):

Your site _config.yml (Optional):

# Hexo Configuration
## Docs: https://hexo.io/docs/configuration.html
## Source: https://github.com/hexojs/hexo/

# Site
title: Hexo
subtitle:
description:
author: John Doe
language:
timezone:

# URL
## If your site is put in a subdirectory, set url as 'http://yoursite.com/child' and root as '/child/'
url: http://yoursite.com
root: /
permalink: :year/:month/:day/:title/
permalink_defaults:

# Directory
source_dir: source
public_dir: public
tag_dir: tags
archive_dir: archives
category_dir: categories
code_dir: downloads/code
i18n_dir: :lang
skip_render:

# Writing
new_post_name: :title.md # File name of new posts
default_layout: post
titlecase: false # Transform title into titlecase
external_link: true # Open external links in new tab
filename_case: 0
render_drafts: false
post_asset_folder: false
relative_link: false
future: true
highlight:
  enable: true
  line_number: true
  auto_detect: false
  tab_replace:

# Category & Tag
default_category: uncategorized
category_map:
tag_map:

# Date / Time format
## Hexo uses Moment.js to parse and display date
## You can customize the date format as defined in
## http://momentjs.com/docs/#/displaying/format/
date_format: YYYY-MM-DD
time_format: HH:mm:ss

# Pagination
## Set per_page to 0 to disable pagination
per_page: 10
pagination_dir: page

# Extensions
## Plugins: https://hexo.io/plugins/
## Themes: https://hexo.io/themes/
theme: landscape

# Deployment
## Docs: https://hexo.io/docs/deployment.html
deploy:
  type: git
  repo: https://github.com/lxh56b/lxh56b.github.io.git
  brunch: master

Your theme _config.yml (Optional):

# Header
menu:
  Home: /
  Archives: /archives
rss: /atom.xml

# Content
excerpt_link: Read More
fancybox: true

# Sidebar
sidebar: right
widgets:
- category
- tag
- tagcloud
- archive
- recent_posts

# display widgets at the bottom of index pages (pagination == 2)
index_widgets:
# - category
# - tagcloud
# - archive

# widget behavior
archive_type: 'monthly'
show_count: false

# Miscellaneous
google_analytics:
favicon: /favicon.png
twitter:
google_plus:
fb_admins:
fb_app_id:

Hexo and Plugin version(npm ls --depth 0):

├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
└── [email protected]

For BUG


deploy之后显示404,并且收到邮件说GitHub pages 不支持Jekyll theme,邮件原文:
you are attempting to use a jekyll theme, "landscape", which is not supported by github pages. Please visit https://pages.github.com/themes for a list of supported themes.

For question


是不是我少安装了插件?
之前在PC上用3.3.1版本,并没有出现这个问题,换到mac上安装3.3.7就出现了这个问题

For feature request

Most helpful comment

好了,更换到3.3.0之后没有任何问题了。
希望安装新版本hexo的同学遇到此类问题可以切换到旧版本。
解决办法:
退回3.3.0版本hexo。
在本地文件夹中的package.json文件

{
  "name": "hexo-site",
  "version": "0.0.0",
  "private": true,
  "hexo": {
    "version": "3.3.7"
  },
  "dependencies": {
    "hexo": "^3.2.0",
    "hexo-generator-archive": "^0.1.4",
    "hexo-generator-category": "^0.1.3",
    "hexo-generator-index": "^0.2.0",
    "hexo-generator-tag": "^0.2.0",
    "hexo-renderer-ejs": "^0.2.0",
    "hexo-renderer-stylus": "^0.3.1",
    "hexo-renderer-marked": "^0.2.10",
    "hexo-server": "^0.2.0"
  }
}

中更改dependence下面的hexo版本信息:

"dependencies": {
"hexo": "^3.2.0",
改为
"dependencies": {
"hexo": "3.3.0",
然后在本地执行

npm install

即可deploy。
注意一定要把^去掉

All 10 comments

是否尝试过使用3.3.1版本会解决问题?
或者尝试此文中的,不要生成git submodule试试? https://liguanghe.github.io/2017/05/21/blogRebuilt/

  1. 试着卸载hexo重新安装,命令为:
#卸载
npm uninstall hexo hexo-cli hexo-server hexo-generator-index hexo-generator-archive hexo-generator-category hexo-generator-tag hexo-deployer-git hexo-generator-feed hexo-generator-sitemap hexo-renderer-marked hexo-renderer-stylus
#安装
npm install [email protected]

安装完之后在package.json 中发现hexo的版本还是显示3.3.7
环境为MacOS
2.按照 https://liguanghe.github.io/2017/05/21/blogRebuilt/ 做完之后仍会收到邮件提示不支持jekyll theme。
按照文中方法做完deploy 之后的提示:

INFO  Deploying: git
INFO  Clearing .deploy_git folder...
INFO  Copying files from public folder...
INFO  Copying files from extend dirs...
On branch gh-pages
nothing to commit, working tree clean
Everything up-to-date
Branch gh-pages set up to track remote branch master from https://github.com/lxh56b/lxh56b.github.io.git.
INFO  Deploy done: git

需要修改package.json中的hexo版本,可以使用3.3.1来lock版本号

在填入3.3.1之后 执行

hexo s

会发现又成了 3.3.7

改完后需要运行npm install,来更新node_module中cache的packages.

还是无效
我更改的是本地文件夹中的package.json文件中的

{
  "name": "hexo-site",
  "version": "0.0.0",
  "private": true,
  "hexo": {
    "version": "**3.3.7**"
  },
  "dependencies": {
    "hexo": "^3.2.0",
    "hexo-generator-archive": "^0.1.4",
    "hexo-generator-category": "^0.1.3",
    "hexo-generator-index": "^0.2.0",
    "hexo-generator-tag": "^0.2.0",
    "hexo-renderer-ejs": "^0.2.0",
    "hexo-renderer-stylus": "^0.3.1",
    "hexo-renderer-marked": "^0.2.10",
    "hexo-server": "^0.2.0"
  }
}

hexo的version(加粗部分)
改为3.3.1
更改之后在本地文件夹执行

npm install

然后执行 hexo s
打开package.json发现又成了3.3.7

需要改dependencies下面的hexo version。

好了,更换到3.3.0之后没有任何问题了。
希望安装新版本hexo的同学遇到此类问题可以切换到旧版本。
解决办法:
退回3.3.0版本hexo。
在本地文件夹中的package.json文件

{
  "name": "hexo-site",
  "version": "0.0.0",
  "private": true,
  "hexo": {
    "version": "3.3.7"
  },
  "dependencies": {
    "hexo": "^3.2.0",
    "hexo-generator-archive": "^0.1.4",
    "hexo-generator-category": "^0.1.3",
    "hexo-generator-index": "^0.2.0",
    "hexo-generator-tag": "^0.2.0",
    "hexo-renderer-ejs": "^0.2.0",
    "hexo-renderer-stylus": "^0.3.1",
    "hexo-renderer-marked": "^0.2.10",
    "hexo-server": "^0.2.0"
  }
}

中更改dependence下面的hexo版本信息:

"dependencies": {
"hexo": "^3.2.0",
改为
"dependencies": {
"hexo": "3.3.0",
然后在本地执行

npm install

即可deploy。
注意一定要把^去掉

建议使用3.3.1, 3.3.0有一个bug在linux系统下。

OK,我一会就改成3.3.1

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lushijie picture lushijie  ·  3Comments

netcan picture netcan  ·  3Comments

jo4x962k7JL picture jo4x962k7JL  ·  3Comments

Helihua1992 picture Helihua1992  ·  3Comments

leoli-dev picture leoli-dev  ·  3Comments