Open maelle opened 4 years ago
Good suggestion. Any chance you'd consider giving us a PR for this?
It feels to me like there is a little bit of overlap here with some of things I found confusing or frustrating as a new user trying out distill. See #129 . I am sorry if that's not helpful.
I don't think its currently possible to import multiple posts from one GitHub repo, and it would have saved me some time if this was called out in the documentation
Note, however, that you can manually point at just the raw HTML file if it is a stand alone distill article:
distill::import_post("https://raw.githubusercontent.com/<user>/<repo>/main/<article>.html")
So I was able to workaround this limitation by importing multiple posts from the same repo manually. It may be nice if the import function handled this scenario, or if we document this workaround.
I've just tried out the importing functionality from a GitHub repository which worked well. "You want posts to be contained within their own Git repositories" sounds really nice.
Here's my repo: https://github.com/maelle/distill-standalone-post (and the website where I imported it https://github.com/maelle/maelle-distill)
In the docs https://rstudio.github.io/distill/blog_workflow.html#importing-a-post I'd have liked to see
How to create the standalone post. I created a new RStudio project, in that project from the new file menu I chose from template, distill article; then I ran
usethis::use_github()
. Is it the intended workflow? What felt a bit suboptimal is that there was no guessing of my name (could it work with whoami + a fallback on options like blogdown New Post Addin).An example of a standalone post and its imported version in the repo of a Distill website. It could be created for the docs but it'd be even more interesting if it were a live website with such a workflow. :-) Edit: I saw https://blogs.rstudio.com/ai/contributing.html