Giter Club home page Giter Club logo

Comments (1)

kdorheim avatar kdorheim commented on June 17, 2024

The documentation has been consolidated on the gh-pages branch!

So it turns out that adding the docs file to the master branch while easy to do can increase the size of the repo. There is a work around however it is some what convoluted. Instead of the regular pkgdown::build_site() you will need to use the deploy_to_branch() see https://pkgdown.r-lib.org/reference/deploy_to_branch.html. I ran into a lot of issues with git hub permissions and ended up using something like as recommend by Alexey.

The ability to run the following from command line depends on having pandoc installed.

# Create gh-pages branch
git checkout --orphan gh-pages
# Make sure this works before running next command!
git rm -rf .
git commit --allow-empty -m "Initialize gh-pages"
git push -u origin gh-pages
# Create a new worktree
git worktree add ../fldgen-pkgdown gh-pages
# Launch R
R
# From R, run pkgdown
library(pkgdown)
pkg <- as_pkgdown(".", override = list(destination = "../fldgen-pkgdown"))
build_site(pkg, devel = FALSE, preview = FALSE, install = FALSE)
quit()
# Back to command line
cd ../fldgen-pkgdown
git push

from fldgen.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.