Skip to content

Commit 69ffaa7

Browse files
authored
ci: update ci config (#28)
1 parent db79c84 commit 69ffaa7

File tree

7 files changed

+114
-60
lines changed

7 files changed

+114
-60
lines changed

.codecov.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
comment: false # Disable the comment that is posted on pull requests.
2+
coverage:
3+
status:
4+
patch:
5+
default:
6+
only_pulls: true # Only show the `codecov/patch` commit status on pull requests.
7+
project:
8+
default:
9+
only_pulls: true # Only show the `codecov/project` commit status on pull requests.
10+
github_checks:
11+
annotations: false # Disable the annotations in the "Files Changed" view of a pull request.

.github/dependabot.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
2+
version: 2
3+
updates:
4+
- package-ecosystem: "github-actions"
5+
directory: "/" # Location of package manifests
6+
schedule:
7+
# weekly, monthly
8+
interval: "monthly"

.github/workflows/CompatHelper.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: CompatHelper
2+
on:
3+
schedule:
4+
- cron: '0 0 * * *' # Everyday at midnight
5+
workflow_dispatch:
6+
jobs:
7+
CompatHelper:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Pkg.add("CompatHelper")
11+
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
12+
- name: CompatHelper.main()
13+
env:
14+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
15+
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
16+
run: julia -e 'using CompatHelper; CompatHelper.main()'

.github/workflows/ci.yml

Lines changed: 55 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,76 +1,95 @@
11
name: CI
22
on:
3-
pull_request:
4-
branches:
5-
- 'main'
6-
- 'release-*'
73
push:
84
branches:
95
- 'main'
106
- 'release-*'
11-
tags: '*'
7+
tags: ['*']
8+
pull_request:
9+
workflow_dispatch:
1210
concurrency:
1311
# Skip intermediate builds: all builds except for builds on the `main` or `release-*` branches
1412
# Cancel intermediate builds: only pull request builds
1513
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-') || github.run_number }}
1614
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
1715
jobs:
1816
test:
19-
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
17+
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
2018
runs-on: ${{ matrix.os }}
19+
permissions: # needed to allow julia-actions/cache to proactively delete old caches that it has created
20+
actions: write
21+
contents: read
2122
strategy:
2223
fail-fast: false
2324
matrix:
24-
version:
25-
- '1.6'
26-
- '1.7'
27-
- 'nightly'
2825
os:
2926
- ubuntu-latest
30-
- macOS-latest
27+
- macos-13 # Intel
3128
- windows-latest
3229
arch:
33-
- x64
34-
- x86
30+
- 'x64'
31+
- 'x86'
32+
version:
33+
- '1.6' # compat
34+
- 'lts'
35+
- 'nightly'
3536
exclude:
36-
- os: macOS-latest
37+
- os: macos-13 # Intel
3738
arch: x86
39+
include:
40+
# macos-latest -> Apple Silicon (Need julia >= v1.8)
41+
- os: macos-latest # Apple Silicon
42+
arch: 'aarch64'
43+
version: 'lts'
44+
- os: macos-latest # Apple Silicon
45+
arch: 'aarch64'
46+
version: 'nightly'
3847
steps:
39-
- uses: actions/checkout@v2
40-
- uses: julia-actions/setup-julia@v1
48+
- uses: actions/checkout@v4
49+
- uses: julia-actions/setup-julia@v2
4150
with:
4251
version: ${{ matrix.version }}
4352
arch: ${{ matrix.arch }}
44-
- uses: actions/cache@v1
45-
env:
46-
cache-name: cache-artifacts
47-
with:
48-
path: ~/.julia/artifacts
49-
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
50-
restore-keys: |
51-
${{ runner.os }}-test-${{ env.cache-name }}-
52-
${{ runner.os }}-test-${{ matrix.os }}
53-
${{ runner.os }}-
53+
- uses: julia-actions/cache@v2
5454
- run: julia --color=yes .ci/test_and_change_uuid.jl
5555
- uses: julia-actions/julia-buildpkg@v1
5656
- uses: julia-actions/julia-runtest@v1
5757
- uses: julia-actions/julia-processcoverage@v1
58-
- uses: codecov/codecov-action@v1
58+
- uses: codecov/codecov-action@v5
5959
with:
60-
file: lcov.info
60+
token: ${{ secrets.CODECOV_TOKEN }}
61+
files: lcov.info
62+
6163
docs:
62-
permissions: write-all
64+
name: Documentation
6365
runs-on: ubuntu-latest
66+
permissions:
67+
# needed to allow julia-actions/cache to proactively delete old caches that it has created
68+
actions: write
69+
contents: write
70+
statuses: write
6471
steps:
65-
- uses: actions/checkout@v2
66-
- uses: julia-actions/setup-julia@latest
72+
- uses: actions/checkout@v4
73+
- uses: julia-actions/setup-julia@v2
6774
with:
68-
# version: '1.6'
6975
version: 'nightly'
70-
- name: Generate docs
76+
- uses: julia-actions/cache@v2
77+
- run: julia --color=yes .ci/test_and_change_uuid.jl
78+
- name: Configure doc environment
79+
shell: julia --project=docs --color=yes {0}
80+
run: |
81+
using Pkg
82+
Pkg.develop(PackageSpec(path=pwd()))
83+
Pkg.instantiate()
84+
- uses: julia-actions/julia-buildpkg@v1
85+
- name: Run doctests
86+
shell: julia --project=docs --color=yes {0}
7187
run: |
72-
julia --color=yes -e 'write("Project.toml", replace(read("Project.toml", String), r"uuid = .*?\n" =>"uuid = \"9bb1440f-4735-579b-a4ab-409b98df4dab\"\n"));'
73-
julia --project --color=yes -e 'using Pkg; Pkg.activate("docs"); Pkg.instantiate(); Pkg.develop(PackageSpec(path = pwd()))'
74-
julia --project=docs --color=yes docs/make.jl pdf
88+
using Documenter: DocMeta, doctest
89+
using DelimitedFiles
90+
DocMeta.setdocmeta!(DelimitedFiles, :DocTestSetup, :(using DelimitedFiles); recursive=true)
91+
doctest(DelimitedFiles)
92+
- uses: julia-actions/julia-docdeploy@v1
7593
env:
94+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
7695
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
docs/build
2+
docs/Manifest.toml
3+
/Manifest.toml

README.md

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,7 @@
11
# DelimitedFiles
22

3-
| **Documentation** | **Build Status** |
4-
|:-----------------------------------------------------------------:|:-----------------------------------------------------------------------------------------------:|
5-
| [![][docs-img]][docs-url] | [![][ci-img]][ci-url] [![][codecov-img]][codecov-url] |
6-
7-
[docs-img]: https://img.shields.io/badge/docs-blue.svg
8-
[docs-url]: http://delimitedfiles.juliadata.org/dev/
9-
10-
[docs-v1-img]: https://img.shields.io/badge/docs-v1-blue.svg
11-
[docs-v1-url]: https://julialang.github.io/delimitedfiles/v1/
12-
13-
[ci-img]: https://github.com/JuliaLang/delimitedfiles.jl/workflows/CI/badge.svg?branch=main
14-
[ci-url]: https://github.com/JuliaLang/delimitedfiles.jl/actions?query=workflow%3A%22CI%22
15-
16-
[codecov-img]: https://codecov.io/gh/JuliaLang/delimitedfiles.jl/branch/main/graph/badge.svg
17-
[codecov-url]: https://codecov.io/gh/JuliaLang/delimitedfiles.jl
3+
[![](https://img.shields.io/badge/docs-dev-blue.svg)](http://delimitedfiles.juliadata.org/dev/)
4+
[![CI](https://github.com/JuliaData/DelimitedFiles.jl/actions/workflows/ci.yml/badge.svg)](https://github.com/JuliaData/DelimitedFiles.jl/actions/workflows/ci.yml)
5+
[![codecov](https://codecov.io/gh/JuliaLang/delimitedfiles.jl/graph/badge.svg?token=t34xJrFp7a)](https://codecov.io/gh/JuliaLang/delimitedfiles.jl)
186

197
This package ships as part of the Julia stdlib.

docs/make.jl

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,25 @@
11
using DelimitedFiles
2-
using Documenter: DocMeta, makedocs, deploydocs
2+
using Documenter
33

44
DocMeta.setdocmeta!(DelimitedFiles, :DocTestSetup, :(using DelimitedFiles); recursive=true)
55

6-
makedocs(
6+
makedocs(;
77
modules = [DelimitedFiles],
8-
sitename = "DelimitedFiles",
8+
sitename = "DelimitedFiles.jl",
9+
format=Documenter.HTML(
10+
prettyurls = get(ENV, "CI", nothing) == "true",
11+
canonical = "https://delimitedfiles.juliadata.org/",
12+
edit_link="main",
13+
assets=String[],
14+
),
915
pages = Any[
10-
"DelimitedFiles" => "index.md"
11-
];
12-
# strict = true,
13-
strict = Symbol[:doctest],
14-
)
16+
"Home" => "index.md"
17+
],
18+
warnonly = :missing_docs,
19+
)
1520

16-
deploydocs(repo = "github.com/JuliaData/DelimitedFiles.jl.git")
21+
deploydocs(;
22+
repo = "github.com/JuliaData/DelimitedFiles.jl",
23+
versions = ["v#.#", "dev" => "dev"],
24+
push_preview = true,
25+
)

0 commit comments

Comments
 (0)