.Rmd 帖子不会在多语言配置中使用“wowchemy/starter-academic"在 Blogdown 中呈现 [英] .Rmd posts do not render in Blogdown using 'wowchemy/starter-academic' in multilingual configuration

查看:79
本文介绍了.Rmd 帖子不会在多语言配置中使用“wowchemy/starter-academic"在 Blogdown 中呈现的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我通过 Rstudio 安装了一个使用wowchemy/starter-academic"主题(又名 Hugo-academic)的 Blogdown.我改为将多语言配置放在 language.tom 中.我将初始文件夹 homepost 放在文件夹 content/encontent/es

I installed via Rstudio a Blogdown using 'wowchemy/starter-academic' theme (aka hugo-academic). I changed to put the multilingual configuration in language.tom. And I put the initial folders home and post in the folders content/en and content/es

[en]
  languageCode = "en-us"
  contentDir = "content/en"  # Uncomment for multi-lingual sites, and move English content into `en` sub-folder.

# Uncomment the lines below to configure your website in a second language.
[es]
  languageCode = "es-ES"
  contentDir = "content/es"

然而,我使用插件 blogdown::serve_site() 来呈现网站,但我系统地获得了 .Rmd 帖子的这个错误:

However, I use the addin blogdown:::serve_site() to render the site but I obtain systematically this error for the .Rmd posts:

WARN 2020/12/01 20:25:25 Alert shortcode will be deprecated in future. Use Callout instead. Rename `alert` to `callout` in "post/writing-technical-content/index.md"

ERROR 2020/12/01 20:25:25 [en] REF_NOT_FOUND: Ref "en/post/2015-07-23-r-rmarkdown/index.html": "/Users/fabio/Desktop/BLog/Test 3 blogdown/content/en/post/2015-07-23-r-rmarkdown/index.html:9:14": page not found

我测试了以下选项:在 R 3.5 blogdown:::serve_site() 中无法呈现 .Rmd 文件

也许我遗漏了什么,非常感谢您的帮助无论如何感谢@Yihui 提供了很棒的 rmarkdown 和 blogdown 包

Maybe I am missing something, any help is really appreciated Thanks @Yihui anyway for the great rmarkdown and blogdown package

我的配置:HUGO_VERSION = "0.79.0"

my configuration: HUGO_VERSION = "0.79.0"

─ Session info ──────────────────────────────────────────────────────────────────────────────────
 setting  value                       
 version  R version 4.0.2 (2020-06-22)
 os       macOS Catalina 10.15.7      
 system   x86_64, darwin17.0          
 ui       RStudio                     
 language (EN)                        
 collate  en_US.UTF-8                 
 ctype    en_US.UTF-8                 
 tz       Europe/Paris                
 date     2020-12-01                  

─ Packages ──────────────────────────────────────────────────────────────────────────────────────
 package   * version  date       lib source                            
 base64enc   0.1-3    2015-07-28 [1] CRAN (R 4.0.0)                    
 BH          1.72.0-3 2020-01-08 [1] CRAN (R 4.0.0)                    
 blogdown    0.21.48  2020-12-01 [1] Github (rstudio/blogdown@ece8b58) 
 bookdown    0.21     2020-10-13 [1] CRAN (R 4.0.2)                    
 digest      0.6.27   2020-10-24 [1] CRAN (R 4.0.2)                    
 evaluate    0.14     2019-05-28 [1] CRAN (R 4.0.0)                    
 glue        1.4.2    2020-08-27 [1] CRAN (R 4.0.2)                    
 highr       0.8      2019-03-20 [1] CRAN (R 4.0.0)                    
 htmltools   0.5.0    2020-06-16 [1] CRAN (R 4.0.0)                    
 httpuv      1.5.4    2020-06-06 [1] CRAN (R 4.0.0)                    
 jsonlite    1.7.1    2020-09-07 [1] CRAN (R 4.0.0)                    
 knitr       1.30     2020-09-22 [1] CRAN (R 4.0.2)                    
 later       1.1.0.1  2020-06-05 [1] CRAN (R 4.0.0)                    
 magrittr    2.0.1    2020-11-17 [1] CRAN (R 4.0.2)                    
 markdown    1.1      2019-08-07 [1] CRAN (R 4.0.0)                    
 mime        0.9      2020-02-04 [1] CRAN (R 4.0.0)                    
 promises    1.1.1    2020-06-09 [1] CRAN (R 4.0.0)                    
 R6          2.5.0    2020-10-28 [1] CRAN (R 4.0.2)                    
 Rcpp        1.0.5    2020-07-06 [1] CRAN (R 4.0.0)                    
 rlang       0.4.9    2020-11-26 [1] CRAN (R 4.0.2)                    
 rmarkdown   2.5.3    2020-12-01 [1] Github (rstudio/rmarkdown@beed481)
 servr       0.20     2020-10-19 [1] CRAN (R 4.0.2)                    
 stringi     1.5.3    2020-09-09 [1] CRAN (R 4.0.2)                    
 stringr     1.4.0    2019-02-10 [1] CRAN (R 4.0.0)                    
 tinytex     0.27     2020-11-01 [1] CRAN (R 4.0.2)                    
 xfun        0.19     2020-10-30 [1] CRAN (R 4.0.2)                    
 yaml        2.2.1    2020-02-01 [1] CRAN (R 4.0.0)      

推荐答案

这个问题已经解决 在当前 blogdown 的开发版本中:

This issue has been resolved in the current development version of blogdown:

remotes::install_github('rstudio/blogdown')

重启R,删除content/en/post/2015-07-23-r-rmarkdown/index.html,再次运行blogdown::serve_site(),并且错误应该消失了.

Restart R, delete content/en/post/2015-07-23-r-rmarkdown/index.html, run blogdown::serve_site() again, and the error should be gone.

这篇关于.Rmd 帖子不会在多语言配置中使用“wowchemy/starter-academic"在 Blogdown 中呈现的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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