Giter Site home page Giter Site logo

jekyllthat's Introduction

lifecycle

jekyllthat

Basic RMarkdown to Github Flavored Jekyll, usefull for writting posts on a blog hosted on GitHub, straight from RStudio.

About

If ever you start a blog today, you definitely should use Blogdown, which is the best tool to create a blog within RStudio. As Yuhui pointed out on Twitter, you can generate Jekyll with {blogdown}, and here’s how to: https://bookdown.org/yihui/blogdown/jekyll.html. I strongly advice you use this method.

But if (as me), you haven’t taken the time to convert to Blogdown, this package is here to help you being more efficient with RStudio and Jekyll. This is the package I use for colinfay.me.

{jekyllthat} contains :

  • An RStudio Rmd template that you can get from New File > RMarkdown > From Template

  • A Markdown format to turn Rmd into a github md for Jekyll. If you’re not using the template, add to your Rmd yaml :

output: jekyllthat::jekylldown

Worflow

Before using

The easier worflow is to keep your Rmd inside the _posts folder. If you want to do that, you should specify jekyll to ignore this in your config.yml. You can manually specifiy this in the exclude part, by adding :

  • “*.Rmd"

You can also use the config_rmd(), that takes as argument the path to your config.yml. But as it is a 15 seconds job to do it manually, you should definitely do it manually.

How to use

With the addin

  • Open the addin

  • Fill the widget

  • You’ve got your post with the right Rmd name \o/

With template

  • Create a new post with New File > RMarkdown > From Template

  • Fill / Modify the yaml as usual.

  • Write and save into the _posts folder

Knit and send

  • Knit to jekylldown

  • Push to github

If you’ve followed the step described in “Before using”, you can push everything (Rmd, folders, md), only the .md will be built for your website.

To Do

  • A better shiny widget

  • Write tests

Contact

Questions and feedbacks welcome!

You want to contribute ? Open a PR :) If you encounter a bug or want to suggest an enhancement, please open an issue.

Please note that this project is released with a Contributor Code of Conduct. By participating in this project you agree to abide by its terms.

jekyllthat's People

Contributors

colinfay avatar privefl avatar

Stargazers

Zeke Marshall avatar Pedro Pinto da Silva avatar Anthony R Davidson avatar James Kondilios avatar  avatar John MacKintosh avatar timelyportfolio avatar Naupaka Zimmerman avatar John Blischak avatar Shinya Uryu avatar amrrs avatar Maëlle Salmon avatar Roel Hogervorst avatar A. Domingues avatar Leo Lee avatar

Watchers

James Cloos avatar  avatar  avatar

jekyllthat's Issues

Images in posts

First of all, thank you for making this package available. I was struggling with the same issue as you, jekyll blog but writing in markdown, and this is a godsend.

I have started using it, but ran into an issue with the images missing from the posts. I am not sure if this is a jekyll or a jekyllthat issue, so feel free to tell me to look elsewhere for a solution.

Issue

Following the instructions in the readme, I saved the Rmd file in in _posts, and knitted in Rstudio. The resulting md file has links to images in format ![]({{ site.url }}/_posts/visual_cv_files/figure-gfm/base-plot-1.png)<!-- -->, and the image file exists in that location. However when serving the blog no image appears. As a test, I moved the images to assets, replace the link locations, and voilá, the images appear in the generated pages.

I then also poked in some of the markdown files or your blog, just so see what I've wrong, and noticed that the images are in assets:

![](../assets/img/unnamed-chunk-4-1.png)<!-- -->

https://raw.githubusercontent.com/ColinFay/colinfay.github.io/36844845a6f0d6148fcc321a77a95c68ee1867bd/_posts/2019-01-02-12-months-cranlogs.md

The question is now, should I be knitting the Rmd in assets and move the md to _posts afterwards? On the same note, can I knit to jekyllthat::jekylldown outside of Rstudio (and how)? That would streamline my workflow.

Cheers


The yaml header of my Rmd:

layout: post
title: My visual CV
date: 2020-11-25 23:50:22.000000000 +01:00
categories: []
tags:
- R
- Tidy
- visualization
- CV
status: publish
type: post
published: true
output: jekyllthat::jekylldown

Date as prefix

With Jekyll, you need to prefix the date to the name of the post.
It doesn't seem to be done automatically using this package (from the date in the yaml).
Should I specify it myself in the name of the Rmd?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.