Skip to content

Commit

Permalink
use julia-docdeploy action (#312)
Browse files Browse the repository at this point in the history
* use `julia-docdeploy` action

* don't use latest

* update reference tests

* add docs note about reference test Julia version

* bump version

* Update docs/src/developer.md

Co-authored-by: Nick Robinson <[email protected]>

Co-authored-by: Nick Robinson <[email protected]>
  • Loading branch information
ericphanson and nickrobinson251 authored Sep 28, 2021
1 parent 792243d commit 12fb463
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 32 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "PkgTemplates"
uuid = "14b8a8f1-9102-5b29-a752-f990bacb7fe1"
authors = ["Chris de Graaf", "Invenia Technical Computing Corporation"]
version = "0.7.18"
version = "0.7.19"

[deps]
Dates = "ade2ca70-3891-5945-98fb-dc099432e06a"
Expand Down
3 changes: 2 additions & 1 deletion docs/src/developer.md
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,8 @@ Here are some testing tips to ensure that your PR goes through as smoothly as po
### Updating Reference Tests & Fixtures

If you've added or modified plugins, you should update the reference tests and the associated test fixtures.
In `test/reference.jl`, you'll find a "Reference tests" test set that basically generates a bunch of packages, and then checks each file against a reference file, which is stored somewhere in `test/fixtures`.
In `test/reference.jl`, you'll find a "Reference tests" test set that basically generates a bunch of packages, and then checks each file against a reference file, which is stored somewhere in `test/fixtures`.
Note the reference tests only run on one specific version of Julia; check `test/runtests.jl` to see the current version used.

For new plugins, you should add an instance of your plugin to the "All plugins" and "Wacky options" test sets, then run the tests with `Pkg.test`.
They should pass, and there will be new files in `test/fixtures`.
Expand Down
15 changes: 5 additions & 10 deletions templates/github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,20 +69,15 @@ jobs:
- uses: julia-actions/setup-julia@v1
with:
version: '1'
- run: |
julia --project=docs -e '
using Pkg
Pkg.develop(PackageSpec(path=pwd()))
Pkg.instantiate()'
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-docdeploy@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
- run: |
julia --project=docs -e '
using Documenter: DocMeta, doctest
using <<&PKG>>
DocMeta.setdocmeta!(<<&PKG>>, :DocTestSetup, :(using <<&PKG>>); recursive=true)
doctest(<<&PKG>>)'
- run: julia --project=docs docs/make.jl
env:
JULIA_PKG_SERVER: ""
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
<</HAS_DOCUMENTER>>
15 changes: 5 additions & 10 deletions test/fixtures/DocumenterGitHubActions/.github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,14 @@ jobs:
- uses: julia-actions/setup-julia@v1
with:
version: '1'
- run: |
julia --project=docs -e '
using Pkg
Pkg.develop(PackageSpec(path=pwd()))
Pkg.instantiate()'
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-docdeploy@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
- run: |
julia --project=docs -e '
using Documenter: DocMeta, doctest
using DocumenterGitHubActions
DocMeta.setdocmeta!(DocumenterGitHubActions, :DocTestSetup, :(using DocumenterGitHubActions); recursive=true)
doctest(DocumenterGitHubActions)'
- run: julia --project=docs docs/make.jl
env:
JULIA_PKG_SERVER: ""
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
15 changes: 5 additions & 10 deletions test/fixtures/WackyOptions/.github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,14 @@ jobs:
- uses: julia-actions/setup-julia@v1
with:
version: '1'
- run: |
julia --project=docs -e '
using Pkg
Pkg.develop(PackageSpec(path=pwd()))
Pkg.instantiate()'
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-docdeploy@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
- run: |
julia --project=docs -e '
using Documenter: DocMeta, doctest
using WackyOptions
DocMeta.setdocmeta!(WackyOptions, :DocTestSetup, :(using WackyOptions); recursive=true)
doctest(WackyOptions)'
- run: julia --project=docs docs/make.jl
env:
JULIA_PKG_SERVER: ""
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}

2 comments on commit 12fb463

@nickrobinson251
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/45673

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.7.19 -m "<description of version>" 12fb46347be56f2fca954edf24c895f890544c8a
git push origin v0.7.19

Please sign in to comment.