Skip to content

Commit 4d6a8eb

Browse files
committed
Update common package maintenance functions to be called using 'devtools'.
1 parent 92acd86 commit 4d6a8eb

1 file changed

Lines changed: 12 additions & 12 deletions

File tree

Makefile

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,23 @@
44
##
55
## #######################################################################################
66

7+
R_EXEC := /usr/bin/R --no-save --quiet
8+
79
# Build package
8-
pkg-build:
9-
@R CMD build ./;
10+
build:
11+
@$(R_EXEC) -e "devtools::build()"
1012

11-
# Get latest built package
12-
pkg-latest-version:
13-
@ls versioning*.tar.gz | tail -1;
13+
# Build and install package
14+
install:
15+
@$(R_EXEC) -e "devtools::install()"
1416

15-
# Install the latest package version locally
16-
pkg-install:
17-
@R CMD build ./
18-
@R CMD INSTALL $$(ls versioning*.tar.gz | tail -1);
17+
# Build man pages
18+
build-docs:
19+
@$(R_EXEC) -e "devtools::document()"
1920

2021
# Check package for CRAN
21-
pkg-check:
22-
@R CMD build ./
23-
@R CMD check --as-cran $$(ls versioning*.tar.gz | tail -1);
22+
check:
23+
@$(R_EXEC) -e "devtools::check(cran = TRUE)"
2424

2525
# Convenience target to print all of the available targets in this file
2626
# From https://stackoverflow.com/questions/4219255

0 commit comments

Comments
 (0)