JuliaDocs/Documenter.jl

Documentation previews not deployed using v1

Open

#2,278 opened on 2023年9月21日

GitHub で見る
 (6 comments) (0 reactions) (0 assignees)Julia (910 stars) (513 forks)batch import
Type: Enhancementhelp wanted

説明

After updating Documenter to v1 documentation previews of PRs are no longer deployed:

 Warning: GITHUB_TOKEN is missing, unable to verify if PR comes from destination repository -- assuming it doesn't.
└ @ Documenter ~/.julia/packages/Documenter/Meee1/src/deployconfig.jl:518
┌ Info: Deployment criteria for deploying preview build from GitHub Actions:
│ - ✔ ENV["GITHUB_REPOSITORY"]="github.com/Hirlam/HarmonieSystemDocumentation.git" occurs in repo="github.com/Hirlam/HarmonieSystemDocumentation.git"
│ - ✔ ENV["GITHUB_REF"] corresponds to a PR number
│ - ✘ PR originates from the same repository
│ - ✔ `push_preview` keyword argument to deploydocs is `true`
│ - ✔ ENV["GITHUB_ACTOR"] exists and is non-empty
│ - ✔ ENV["DOCUMENTER_KEY"] exists and is non-empty
└ Deploying: ✘

The setup is perhaps slightly non-standard because the github action is running in github.com/Hirlam/Harmonie (a private repo) but documentation should be public so the html pages are deployed to github.com/Hirlam/HarmonieSystemDocumentation.git in make.jl by:

withenv("GITHUB_REPOSITORY" => "github.com/Hirlam/HarmonieSystemDocumentation.git") do 
    deploydocs(
        repo = "github.com/Hirlam/HarmonieSystemDocumentation.git",
        devbranch = "dev-CY46h1",   
        devurl = "dev",       
        push_preview=true
    )
end 

This worked in v0.27. I am using a DOCUMENTER_KEY secret in Hirlam/Harmonie and a Documenter Deploy key in Hirlam/HarmonieSystemDocumentation

コントリビューターガイド