Files
bank-fraud-baf-lakehouse/deploy.R
Rob Wiederstein 7a1a8e0053 Add Phase 4: code quality, CI/CD, and formatting
- testthat infrastructure with 15 tests covering env-var guards,
  return types for all format/save functions, and spelling
- inst/WORDLIST with 52 domain terms (LightGBM, MinIO, Parquet, etc.)
- Spelling test wired into devtools::test() via test-spelling.R
- styler::style_file() added as step 0 in deploy.R (auto-fixes before ship)
- .gitea/workflows/test.yaml: runs testthat suite on push
- .gitea/workflows/lint.yaml: lychee link check + styler dry-run on push
- Removed internal IP address from comment in train_production_model()
- Language: en-US added to DESCRIPTION

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-22 04:41:37 -05:00

25 lines
758 B
R

# deploy.R
message("🎨 0. Styling R/functions.R...")
styler::style_file("R/functions.R")
message("📝 1. Updating package documentation and namespace...")
devtools::document()
message("🚀 2. Running targets pipeline...")
targets::tar_make()
message("🏗️ 3. Building pkgdown website...")
pkgdown::build_site()
message("📦 4. Injecting slides into public docs/ folder...")
# Create target directories
fs::dir_create("docs/slides/reports/figures")
# Copy the HTML and index_files
fs::dir_copy("reports/slides/", "docs/slides/", overwrite = TRUE)
# Copy the figures so the slides can see them
fs::dir_copy("reports/figures/", "docs/slides/reports/figures/", overwrite = TRUE)
message("✅ DONE: Site and slides successfully deployed to docs/")