Package 'pkgmkr'

Title: Create an R Package with One Simple Function
Description: Simplifies the process of creating R packages by providing a single, straightforward function that handles package initialization, Git integration, license selection, README generation, and pkgdown site setup. Package creation can also be configured using YAML or JSON configuration files.
Authors: Shaurita Hutchins [aut, cre] (ORCID: <https://orcid.org/0000-0002-7687-0059>)
Maintainer: Shaurita Hutchins <[email protected]>
License: MIT + file LICENSE
Version: 0.1.0
Built: 2026-06-09 19:15:48 UTC
Source: https://github.com/sdhutchins/pkgmkr

Help Index


Package Config

Description

Import configuration data from a file.

Usage

import_config(path, file_type = "yaml")

Arguments

path

character. The path to the configuration file.

file_type

character. The file type of the configuration file (either "yaml" or "json").

Value

A list containing the configuration data.


Make Package

Description

Create a new R package with the specified parameters

Usage

mk_pkg(
  path,
  author,
  email,
  git = TRUE,
  git_username = NULL,
  git_email = NULL,
  readme_md = TRUE,
  check_pkg_name = TRUE,
  license = "MIT",
  pkgdown = TRUE
)

Arguments

path

character. The path to create the package at.

author

character. The name of the package author.

email

character. The email to use for Git and GitHub.

git

logical. Whether to initialize a Git repository for the package.

git_username

character. The username to use for Git and GitHub.

git_email

character. The email to use for Git and GitHub.

readme_md

logical. Whether to create a README file in markdown format.

check_pkg_name

logical. Whether to check that the package name is available on CRAN.

license

character. The license to use for the package (either "MIT" or "GPL-3").

pkgdown

logical. Whether to create a pkgdown site for the package.


Make Package from Config

Description

Create a package based on a configuration file.

Usage

mk_pkg_from_config(config_path, file_type = "yaml")

Arguments

config_path

character. The path to the configuration file.

file_type

character. The file type of the configuration file (either "yaml" or "json").


Write Config

Description

Write configuration data to a file.

Usage

write_config(path, config_data)

Arguments

path

character. The path to write the configuration file to.

config_data

list. The configuration data to write to the file.