Skip to content

Commit

Permalink
Standardize yml (#25)
Browse files Browse the repository at this point in the history
* Standardize make.jl

* Standardize yml

* fix typo

* Add _typos
  • Loading branch information
JeffFessler authored May 12, 2024
1 parent 78ab35e commit 8a48ea6
Show file tree
Hide file tree
Showing 6 changed files with 43 additions and 8 deletions.
18 changes: 17 additions & 1 deletion .github/workflows/CompatHelper.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,26 @@
name: CompatHelper

on:
schedule:
- cron: 0 0 * * 0 # weekly
workflow_dispatch:

permissions:
contents: write
pull-requests: write
jobs:
CompatHelper:
runs-on: ubuntu-latest
steps:
- name: Check if Julia is already available in the PATH
id: julia_in_path
run: which julia
continue-on-error: true
- name: Install Julia, but only if it is not already available in the PATH
uses: julia-actions/setup-julia@latest
with:
version: '1'
# arch: ${{ runner.arch }}
if: steps.julia_in_path.outcome != 'success'
- name: "Add the General registry via Git"
run: |
import Pkg
Expand All @@ -30,3 +43,6 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}

# based on:
# https://github.com/JuliaRegistries/CompatHelper.jl
13 changes: 13 additions & 0 deletions .github/workflows/SpellCheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Spell Check

on: [pull_request]

jobs:
typos-check:
name: Spell Check with Typos
runs-on: ubuntu-latest
steps:
- name: Checkout Actions Repository
uses: actions/checkout@v4
- name: Check spelling
uses: crate-ci/typos@master
2 changes: 2 additions & 0 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
name: TagBot

on:
issue_comment:
types:
- created
workflow_dispatch:

jobs:
TagBot:
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
Expand Down
4 changes: 4 additions & 0 deletions _typos.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[default]
extend-ignore-identifiers-re = [
"GridOT",
]
10 changes: 5 additions & 5 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ execute = isempty(ARGS) || ARGS[1] == "run"

org, reps = :JuliaArrays, :LazyGrids
eval(:(using $reps))
using Documenter
using Literate
import Documenter
import Literate

# https://juliadocs.github.io/Documenter.jl/stable/man/syntax/#@example-block
ENV["GKSwstype"] = "100"
Expand All @@ -23,7 +23,7 @@ binder_root_url =


repo = eval(:($reps))
DocMeta.setdocmeta!(repo, :DocTestSetup, :(using $reps); recursive=true)
Documenter.DocMeta.setdocmeta!(repo, :DocTestSetup, :(using $reps); recursive=true)

# preprocessing
inc1 = "include(\"../../../inc/reproduce.jl\")"
Expand Down Expand Up @@ -77,7 +77,7 @@ format = Documenter.HTML(;
assets = ["assets/custom.css"],
)

makedocs(;
Documenter.makedocs(;
modules = [repo],
authors = "Jeff Fessler and contributors",
sitename = "$repo.jl",
Expand All @@ -90,7 +90,7 @@ makedocs(;
)

if isci
deploydocs(;
Documenter.deploydocs(;
repo = "github.com/$base",
devbranch = "main",
devurl = "dev",
Expand Down
4 changes: 2 additions & 2 deletions src/ndgrid-step-range-len.jl
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ struct GridSL{T,d,D, R, S} <: AbstractGrid{T,d,D}

function GridSL(dims::Dims{D}, v::StepRangeLen{T,R,S}, d::Int) where {D, T, R, S}
1 d D || throw(ArgumentError("$d for $dims"))
eltype(v.len) == Int || throw("non-Int v.len unsuported")
eltype(v.offset) == Int || throw("non-Int v.offset unsuported")
eltype(v.len) == Int || throw("non-Int v.len unsupported")
eltype(v.offset) == Int || throw("non-Int v.offset unsupported")
new{T,d,D,R,S}(dims, v.ref, v.step, v.len, v.offset)
end
end
Expand Down

0 comments on commit 8a48ea6

Please sign in to comment.