소스 정보
- 저장소
- Morrison-Lab/ai-config
- 최근 소스 활동
- 2026년 8월 27일 04:45
- 감지된 SKILL.md 언어
- 영어
- 스타
- 1
- 포크
- 0
설치 방법
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
소스 파일 검토
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
메뉴
기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.
설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
직접 명령은 검토 Prompt를 거치지 않습니다. 실행하기 전에 소스를 확인하세요.
npx skills add https://github.com/Morrison-Lab/ai-config --skill cran-extrachecks명령은 한 줄로 유지됩니다. 복사하기 전에 가로로 스크롤해 전체 내용을 확인하세요.
로컬 사본을 원하시나요? SkillsMP에서 현재 제공할 수 있는 파일을 다운로드하세요.
SKILL.md 표시 중
| name | cran-extrachecks |
| description | CRAN submission checklist beyond devtools::check(). |
| user-invocable | true |
| allowed-tools | ["Read","Edit","Write","Bash"] |
| metadata | {"author":"Garrick Aden-Buie (@gadenbuie)","version":"1.0"} |
| license | MIT |
Help R package developers prepare packages for CRAN submission by systematically checking for common ad-hoc requirements that CRAN reviewers enforce but devtools::check() doesn't catch.
Work through these items systematically:
usethis::use_news_md() if not already presentusethis::use_cran_comments() if not already presentinstall.packages("pkgname")).devtools::build_readme() to re-render README.mdTitle: and Description: fields (see detailed guidance below)@return and @examples (see detailed guidance below)Authors@R: includes a copyright holder with role [cph]urlchecker::url_check() and fix any issuesReturn Value Documentation (Strictly Enforced)
CRAN now strictly requires @return documentation for all exported functions.
Use the roxygen2 tag @return to document what the function returns.
@keywords internal@return None or similarExample:
# Missing @return - WILL BE REJECTED
#' Calculate sum
#' @export
my_sum <- function(x, y) {
x + y
}
# Correct - includes @return
#' Calculate sum
#' @param x First number
#' @param y Second number
#' @return A numeric value
#' @export
my_sum <- function(x, y) {
x + y
}
# For functions with no return value
#' Print message
#' @param msg Message to print
#' @return None, called for side effects
#' @export
print_msg <- function(msg) {
cat(msg, "\n")
}
Examples for Exported Functions
If your exported function has a meaningful return value, it will almost definitely require an @examples section.
Use the roxygen2 tag @examples.
@keywords internalUn-exported Functions with Examples
If you write roxygen examples for un-exported functions, you must either:
::: notation: pkg:::my_fun()@noRd tag to suppress .Rd file creationUsing \dontrun{} Sparingly
\dontrun{} should only be used if the example really cannot be executed (e.g., missing additional software, API keys, etc.).
try() insteadgooglesheets4::sheets_has_token()) with if () blocksinteractive() can be used as the condition\donttest{}Never Comment Out Code in Examples
# BAD - Will be rejected
#' @examples
#' # my_function(x) # Don't do this!
CRAN's guidance: "Examples/code lines in examples should never be commented out. Ideally find toy examples that can be regularly executed and checked."
Guarding Examples with Suggested Packages
Use @examplesIf for entire example sections requiring suggested packages:
#' @examplesIf rlang::is_installed("dplyr")
#' library(dplyr)
#' my_data %>% my_function()
For individual code blocks within examples:
#' @examples
#' if (rlang::is_installed("dplyr")) {
#' library(dplyr)
#' my_data %>% my_function()
#' }
CRAN enforces strict Title requirements:
Use Title Case
Capitalize all words except articles like 'a', 'the'.
Use tools::toTitleCase() to help format.
Avoid Redundancy
Common phrases that get flagged:
Examples:
# BAD
Title: A Toolkit for the Construction of Modeling Packages for R
# GOOD
Title: Construct Modeling Packages
# BAD
Title: Command Argument Parsing for R
# GOOD
Title: Command Argument Parsing
Quote Software/Package Names
Put all software and R package names in single quotes:
# GOOD
Title: Interface to 'Tiingo' Stock Price API
Length Limit
Keep titles under 65 characters.
Never Start With Forbidden Phrases
CRAN will reject descriptions starting with:
# BAD
Description: This package provides functions for rendering slides.
Description: Functions for rendering slides to different formats.
# GOOD
Description: Render slides to different formats including HTML and PDF.
Expand to 3-4 Sentences
Single-sentence descriptions are insufficient. Provide a broader description of:
# BAD (too short)
Description: Render slides to different formats.
# GOOD
Description: Render slides to different formats including HTML and PDF.
Supports custom themes and progressive disclosure patterns. Integrates
with 'reveal.js' for interactive presentations. Designed for technical
presentations and teaching materials.
Quote Software Names, Not Functions
# BAD
Description: Uses 'case_when()' to process data.
# GOOD
Description: Uses case_when() to process data with 'dplyr'.
Software, package, and API names get single quotes (including 'R'). Function names do not.
Expand All Acronyms
All acronyms must be fully expanded on first mention:
# BAD
Description: Implements X-SAMPA processing.
# GOOD
Description: Implements Extended Speech Assessment Methods Phonetic
Alphabet (X-SAMPA) processing.
Publication Titles Only in Double Quotes
Only use double quotes for publication titles, not for phrases or emphasis:
# BAD
Description: Handles dates like "the first Monday of December".
# GOOD
Description: Handles dates like the first Monday of December.
All URLs Must Use HTTPS
CRAN requires https:// protocol for all URLs.
HTTP links will be rejected.
# BAD
URL: http://paleobiodb.org/
# GOOD
URL: https://paleobiodb.org/
No Redirecting URLs
CRAN rejects URLs that redirect to other locations. Example rejection:
Found the following (possibly) invalid URLs:
URL: https://h3geo.org/docs/core-library/coordsystems#faceijk-coordinates
(moved to https://h3geo.org/docs/core-library/coordsystems/)
Use urlchecker Package
# Find redirecting URLs
urlchecker::url_check()
# Automatically update to final destinations
urlchecker::url_update()
Ignore URLs That Will Exist After Publication
Some URLs that don't currently resolve will exist once the package is published on CRAN. These should NOT be changed:
https://cran.r-project.org/package=pkgname)https://www.r-pkg.org/badges/version/pkgname)https://cranchecks.info/badges/pkgname)When urlchecker::url_check() flags these URLs, leave them as-is.
They are aspirational URLs that will work once the package is on CRAN.
Check for Invalid File URIs
Relative links in README must exist after package build. Common issue:
Found the following (possibly) invalid file URI:
URI: CODE_OF_CONDUCT.md
From: README.md
This occurs when files are in .Rbuildignore.
Solutions:
.Rbuildignoreusethis::use_code_of_conduct() which generates sections without relative linksCopyright Holder Role
Always add [cph] role to Authors field, even if you're the only author:
# Required
Authors@R: person("John", "Doe", role = c("aut", "cre", "cph"))
Posit-Supported Packages
For packages in Posit-related GitHub organizations (posit-dev, rstudio, r-lib, tidyverse, tidymodels) or maintained by someone with a @posit.co email address, include Posit Software, PBC as copyright holder and funder:
Authors@R: c(
person("Jane", "Doe", role = c("aut", "cre"),
email = "jane.doe@posit.co"),
person("Posit Software, PBC", role = c("cph", "fnd"),
comment = c(ROR = "03wc8by49"))
)
LICENSE Year
Update LICENSE year to current submission year:
# If LICENSE shows 2024 but submitting in 2026
# Update: 2024 → 2026
Method References
CRAN may ask:
If there are references describing the methods in your package, please add these in the description field...
If there are no references, reply to the email explaining this.
Consider adding a preemptive note in cran-comments.md:
## Method References
There are no published references describing the methods in this package.
The package implements original functionality for [brief description].
Work through these files systematically:
@return, @examples, @examplesIf, @noRd)devtools::build_readme()DESCRIPTION Title:
# Before
Title: A Toolkit for the Construction of Modeling Packages for R
# After
Title: Construct Modeling Packages
DESCRIPTION Description:
# Before
Description: This package provides functions for rendering slides.
# After
Description: Render slides to different formats including HTML and PDF.
Supports custom themes and progressive disclosure. Integrates with
'reveal.js' for interactive presentations.
Function Documentation:
# Before - Missing @return
#' Calculate total
#' @param x Values
#' @export
calc_total <- function(x) sum(x)
# After - Complete documentation
#' Calculate total
#' @param x Numeric values to sum
#' @return A numeric value representing the sum
#' @examples
#' calc_total(1:10)
#' @export
calc_total <- function(x) sum(x)
tools::toTitleCase() - Format titles with proper capitalizationurlchecker::url_check() - Find problematic URLsurlchecker::url_update() - Fix redirecting URLsusethis::use_news_md() - Create NEWS.mdusethis::use_cran_comments() - Create cran-comments.mddevtools::build_readme() - Re-render README.md from README.Rmdusethis::use_code_of_conduct() - Add CoC without relative linksusethis::use_build_ignore() - Ignore files in R package buildusethis::use_package() - Add a package dependency to DESCRIPTIONusethis::use_tidy_description() - Tidy up DESCRIPTION formattingUse this checklist to ensure nothing is missed before submission:
NEWS.md exists and documents changes for this versioncran-comments.md exists with submission notesdevtools::build_readme() was runinstall.packages("pkgname"))Title: uses title caseTitle: has no redundant phrases ("A Toolkit for", "Tools for", "for R")Title: quotes all software/package names in single quotesTitle: is under 65 charactersDescription: does NOT start with "This package", package name, or "Functions for"Description: is 3-4 sentences explaining purpose and utilityDescription: quotes software/package/API names (including 'R') but NOT function namesDescription: expands all acronyms on first mentionDescription: uses double quotes only for publication titlesAuthors@R: includes copyright holder with [cph] roleperson("Posit Software, PBC", role = c("cph", "fnd"), comment = c(ROR = "03wc8by49"))@return documentation@examples\dontrun{} unless truly necessary@examplesIf or if guards::: notation or @noRdurlchecker::url_check() was run.Rbuildignore filescran-comments.mdThis is the ad-hoc / stylistic checklist (Title case, @return tags, \dontrun{} usage, URL hygiene) that devtools::check() doesn't catch on its own.
r-pkg-cran-checklist covers the release mechanics this skill does not: win-builder, revdep checks, and devtools::release().
Run both for a CRAN submission --- neither subsumes the other.