Return all the paths to the tutorials in a package
Source:R/return_tutorial_paths.R
return_tutorial_paths.Rd
Takes a package name and returns a character vector of all the paths to tutorials in the installed package. Assumes that every Rmd file in inst/tutorials/*/ is a tutorial, which should be true.
Examples
return_tutorial_paths('learnr')
#> [1] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/ex-data-basics/ex-data-basics.Rmd"
#> [2] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/ex-data-filter/ex-data-filter.Rmd"
#> [3] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/ex-data-mutate/ex-data-mutate.Rmd"
#> [4] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/ex-data-summarise/ex-data-manip-summarise.Rmd"
#> [5] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/ex-setup-r/ex-setup-r.Rmd"
#> [6] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/hello/hello.Rmd"
#> [7] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/polyglot/polyglot.Rmd"
#> [8] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/quiz_question/quiz_question.Rmd"
#> [9] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/setup-chunks/setup-chunks.Rmd"
#> [10] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/slidy/slidy.Rmd"
#> [11] "/home/runner/.cache/R/renv/library/tutorial.helpers-cdd4ef10/linux-ubuntu-jammy/R-4.4/x86_64-pc-linux-gnu/learnr/tutorials/sql-exercise/sql-exercise.Rmd"