diff --git a/NAMESPACE b/NAMESPACE index 47df11e..4c3e83e 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -2,3 +2,4 @@ export(add_registration_glue) import(rprojroot) +import(stringi) diff --git a/R/add-reg-glue.R b/R/add-reg-glue.R index 5ce2498..d5e805d 100644 --- a/R/add-reg-glue.R +++ b/R/add-reg-glue.R @@ -94,6 +94,10 @@ init_file_auto_generated <- function(src_dir) { } +#' This examines a package swift file and builds the necessary registration glue code +#' +#' @param package where the package lives +#' @return nothing directly, but has a side effect of creating `init.c` #' @export add_registration_glue <- function(package = ".") { diff --git a/README.md b/README.md new file mode 100644 index 0000000..cc3e8c2 --- /dev/null +++ b/README.md @@ -0,0 +1,65 @@ + +[![Project Status: Active – The project has reached a stable, usable +state and is being actively +developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active) +[![Signed +by](https://img.shields.io/badge/Keybase-Verified-brightgreen.svg)](https://keybase.io/hrbrmstr) +![Signed commit +%](https://img.shields.io/badge/Signed_Commits-100%25-lightgrey.svg) +[![Linux build +Status](https://travis-ci.org/hrbrmstr/swiftr.svg?branch=master)](https://travis-ci.org/hrbrmstr/swiftr) +![Minimal R +Version](https://img.shields.io/badge/R%3E%3D-3.6.0-blue.svg) +![License](https://img.shields.io/badge/License-MIT-blue.svg) + +# swiftr + +Seamless R and Swift Integration + +## Description + +eamless R and Swift Integration + +## What’s Inside The Tin + +The following functions are implemented: + +- `add_registration_glue`: This examines a package swift file and + builds the necessary registration glue code + +## Installation + +``` r +remotes::install_git("https://git.rud.is/hrbrmstr/swiftr.git") +# or +remotes::install_gitlab("hrbrmstr/swiftr") +``` + +NOTE: To use the ‘remotes’ install options you will need to have the +[{remotes} package](https://github.com/r-lib/remotes) installed. + +## Usage + +``` r +library(swiftr) + +# current version +packageVersion("swiftr") +## [1] '0.1.0' +``` + +## swiftr Metrics + +| Lang | \# Files | (%) | LoC | (%) | Blank lines | (%) | \# Lines | (%) | +|:-----|---------:|-----:|----:|-----:|------------:|-----:|---------:|-----:| +| R | 3 | 0.38 | 87 | 0.46 | 32 | 0.34 | 15 | 0.17 | +| Rmd | 1 | 0.12 | 8 | 0.04 | 15 | 0.16 | 28 | 0.33 | +| SUM | 4 | 0.50 | 95 | 0.50 | 47 | 0.50 | 43 | 0.50 | + +clock Package Metrics for swiftr + +## Code of Conduct + +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. diff --git a/man/add_registration_glue.Rd b/man/add_registration_glue.Rd new file mode 100644 index 0000000..a2afb94 --- /dev/null +++ b/man/add_registration_glue.Rd @@ -0,0 +1,17 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/add-reg-glue.R +\name{add_registration_glue} +\alias{add_registration_glue} +\title{This examines a package swift file and builds the necessary registration glue code} +\usage{ +add_registration_glue(package = ".") +} +\arguments{ +\item{package}{where the package lives} +} +\value{ +nothing directly, but has a side effect of creating \code{init.c} +} +\description{ +This examines a package swift file and builds the necessary registration glue code +}