Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Editorial Workflow script #2

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

steffilazerte
Copy link
Collaborator

@maelle, @yabellini This is what all the fuss has been about 🤣

This is the Editorial Workflow script I want to find a home for. It works well here as an example of workflows that can be useful. But for me, I'll keep it locally in the ropensci/roweb3 project as I need to use it inside that git repository.

Copy link

@maelle maelle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

really cool!! and not a function indeed 😂 it reminds me of "RStudio snippets"

- For the spell check, we ignore words which are:
- the name of an rOpenSci package
- in a local WORDLIST stored in "inst/WORDLIST" (and locally git-ignored i.e. `.git/info/exclude`)
- We use the `rstudioapi::navigateToFile()` function to open files in RStudio as
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a shorter alternative: file.edit()

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(in RStudio it opens the file in RStudio)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't know that, so cool!

pkg <- FALSE # <--- Is this a post about a Peer-Reviewed Package?

# Get the relevant md file (and check)
(b <- gert::git_diff("HEAD^")$new |> stringr::str_subset("\\.md$"))
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just curious: how does this work if there's also an author file?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(but I really like this strategy! I'd have thought of the API first, using Git is so much quicker)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a good point! I'll have to test it out!

This is a copy of the Editorial workflow used by editors when reviewing staff
or community blog posts to the [rOpenSci blog](https://ropensci.org/blog).

This is a relatively simple workflow and a script is not even necessary.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is all really nice ✨ in a tech note I'm sure there'll be aha moments for readers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants