quarto-dev / quarto-cli

Open-source scientific and technical publishing system built on Pandoc.
https://quarto.org
Other
3.74k stars 305 forks source link

[FR]: Easily add a new post in a blog e.g `quarto create post` #3917

Open cderv opened 1 year ago

cderv commented 1 year ago

This comes from https://github.com/quarto-dev/quarto-r/issues/22

R users have such feature with blogdown::new_post() and a RStudio Addin build upon it. I believe it would be a nice feature to have in our quarto create ... suites of features.

This would help

jthomasmock commented 1 year ago

A few functions/packages have been created by community:

But a current limitation is that all are R focused rather than general quarto CLI tooling.

smach commented 1 year ago

The one thing these personal R packages are missing (including mine) is the ability to see existing blog categories. It's usually not a good idea to add freeform text to what should be structured data!

cderv commented 1 year ago

@dragonstyle do you think we could target adding new quarto create feature for 1.4 ?

petzi53 commented 1 year ago

With quartopost I tried to simulate the very missed blogdown "new post" RStudio Addin by Yihui Xie using a shiny dialog window with some configurations and offering a list of already used tags as commented by @smach.

dragonstyle commented 1 year ago

@cderv I'm not sure if we'll have time to get to this in 1.4 - I think doing a good job will be a few days worth of work...

mcanouil commented 1 year ago

I would argue that first, #5421 and #598 need to be resolved, before adding new commands.

EDIT: easy workaround is to define code snippet in your favourite IDE to create a new post (although it won't create parent directory itself before saving, at least VSCode creates parent directory on save).

cderv commented 1 year ago

@dragonstyle let's consider this for later then.

@mcanouil yes, this would be better to clean the current state first.

Regarding the workaround, I believe @petzi53 work on https://github.com/petzi53/quartopost is really good ! It is targeting RStudio's user only though but that is still a really good solution ! Thanks @petzi53 !

astrowonk commented 11 months ago

Yes, please! I miss hugo new posts/something_new/index.md and having the basic metadata like date and draft: true set for me.

astrowonk commented 6 months ago

I created the very simple Python based quarto-new-content command line utility to replicate hugo new content command line functionality. One can do:

quarto-new-content posts/star-trek-is-cool/index.qmd 

and it will make the new file in the new directory, with a very minimal set of yaml headers, ready for editing.