upload_assets: Synchronize media assets with the cloud

upload_assetsR Documentation

Synchronize media assets with the cloud

Description

Upload lesson assets to galacticPubs Google Cloud Storage bucket. It looks for the following patterns in the following folders:

  • SponsorLogo | assets/_banners_logos_etc: anything with 'logo' and .png, .jpg, .webp suffix

  • LessonBanner | assets/_banners_logos_etc: ideally just named banner.png; should work with 'ShortTitle_banner.png' and exclude 'old_banner.png'

  • LessonTiles | assets/_banners_logos_etc: must be format 'L1_tile.png'; other img formats also supported: .png, .jpeg, .webp

  • UnitCard | assets/_banners_logos_etc: format 'card.png' or 'ShortTitle.png'

  • QR-code | assets/_banners_logos_etc: format 'ProjTitle_QR-code.png'

  • LearningChart| assets/_learning-plots: file must be called 'GP-Learning-Chart.png' (autogenerated from learningChart())

  • LearningEpaulette | assets/_learning-plots: file must be called 'GP-Learning-Epaulette.png' (autogenerated from learningEpaulette())

  • LearningEpaulette_vert | assets/_learning-plots: file must be called 'GP-Learning-Epaulette_vert.png' (autogenerated from learningEpaulette())

  • SupportingMedia | assets/_other-media-to-publish: anything except help.txt found in this folder

Alias for upload_assets

Usage

upload_assets(WD = "?", bucket = "gp-cloud", clear = FALSE)

gcs_upload_assets(WD = "?", bucket = "gp-cloud", clear = FALSE)

Arguments

WD

WD working directory, passed to parse_wd()

bucket

which bucket? default= "gp-cloud"

clear

do you want to clear all existing files for this project before uploading? default=FALSE

Value

invisibly returns a Tibble with filenames and download links

Functions

  • gcs_upload_assets(): alias

See Also

Other google cloud storage: gcs_add(), gcs_contents(), gcs_delete()

Other google cloud storage: gcs_add(), gcs_contents(), gcs_delete()


galacticpolymath/GPpub documentation built on April 5, 2025, 6:04 p.m.