Coder Social home page Coder Social logo

Multiple docs versions about yadism HOT 3 CLOSED

nnpdf avatar nnpdf commented on August 22, 2024
Multiple docs versions

from yadism.

Comments (3)

alecandido avatar alecandido commented on August 22, 2024

Strategy for multiple goals

develop docs

First choose one of the following:

  1. Write a new workflow to run from develop branch only
  2. Use the variable GITHUB_REF to separate from master

Than set the TARGET_FOLDER variable in the github-pages-deploy-action, by:

  1. choosing your favourite name for develop docs
  2. use a conditional github expression, e.g.:
          TARGET_FOLDER: ${{ github.ref }}

or

      - name: Deploy 🚀
        if: github.ref == 'master'
        uses: JamesIves/github-pages-deploy-action@releases/v3
        with:
          TARGET_FOLDER: ${{ github.ref }}
      - name: Deploy 🚀
        if: github.ref == 'develop'
        uses: JamesIves/github-pages-deploy-action@releases/v3
        with:
          TARGET_FOLDER: "dontrelymeimunstable"

version docs only

if using the strategy 1. try using 2. for the master only workflow, i.e. use TARGET_FOLDER: ${{ github.ref }}

redirect

put a redirect (maybe an HTML one) from base domain to /stable, not to be updated never by any workflow (nor deleted)

navigate docs version

Something like this:
image
image

from yadism.

alecandido avatar alecandido commented on August 22, 2024

Since the content of ${{ github.ref }} is too raw, and it's not possible to elaborate the string directly in TARGET_FOLDER field, nor it's possible to use anything else, move to a completely different action, add-and-commit, to make the workflow more flexible.

Summary: instead of using a specific "deploying" action, just use a generic "commit" action and load manually the file in the gh-pages branch with git

(git is more flexible and reliable than a specific action)

from yadism.

felixhekhorn avatar felixhekhorn commented on August 22, 2024

stable branch is recovered

from yadism.

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.