Skip to content

Commit 6b35d5a

Browse files
authored
Merge pull request #32 from JuliaAI/dev
For a 0.3.3 release
2 parents fcfd2ff + 070bfa3 commit 6b35d5a

File tree

12 files changed

+130
-100
lines changed

12 files changed

+130
-100
lines changed

.github/workflows/CI.yml

Lines changed: 13 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -15,23 +15,22 @@ jobs:
1515
fail-fast: false
1616
matrix:
1717
julia-version:
18-
- "1.6"
18+
- "lts"
1919
- "1"
20-
- "nightly"
2120
os:
2221
- ubuntu-latest
2322
- macos-latest
2423
- windows-latest
2524
julia-arch:
2625
- x64
2726
steps:
28-
- uses: actions/checkout@v2
29-
- uses: julia-actions/setup-julia@v1
27+
- uses: actions/checkout@v6
28+
- uses: julia-actions/setup-julia@v2
3029
with:
3130
version: ${{ matrix.julia-version }}
3231
arch: ${{ matrix.julia-arch }}
3332
- name: Cache artifacts
34-
uses: actions/cache@v2
33+
uses: julia-actions/cache@v2
3534
env:
3635
cache-name: cache-artifacts
3736
with:
@@ -54,67 +53,17 @@ jobs:
5453
runs-on: ubuntu-latest
5554
steps:
5655
- uses: actions/checkout@v2
57-
- uses: julia-actions/setup-julia@v1
56+
- uses: julia-actions/setup-julia@v2
5857
with:
5958
version: '1'
60-
- run: |
61-
julia -e '
62-
function set_environment_variable(name::AbstractString, value::AbstractString)
63-
github_env = ENV["GITHUB_ENV"]
64-
touch(github_env)
65-
open(github_env, "a") do io
66-
println(io, "$(name)=$(value)")
67-
end
68-
end
69-
event_name = "${{ github.event_name }}"
70-
if event_name == "pull_request"
71-
base_ref = "${{ github.base_ref }}"
72-
head_ref = "${{ github.head_ref }}"
73-
base_repository = "${{ github.repository }}"
74-
head_repository = "${{ github.event.pull_request.head.repo.full_name }}"
75-
build_docs = (base_ref == "master") && (head_ref == "dev") && (base_repository == head_repository)
76-
elseif event_name == "push"
77-
ref = "${{ github.ref }}"
78-
build_docs = (ref == "refs/heads/master") || (startswith(ref, "refs/tags/"))
79-
elseif event_name == "schedule"
80-
build_docs = ref == "refs/heads/master"
81-
elseif event_name == "workflow_dispatch"
82-
build_docs = ref == "refs/heads/master"
83-
else
84-
build_docs = false
85-
end
86-
if build_docs
87-
@info("We will build the docs")
88-
set_environment_variable("BUILD_DOCS", "true")
89-
else
90-
@info("We will NOT build the docs")
91-
set_environment_variable("BUILD_DOCS", "false")
92-
end'
93-
- run: |
94-
julia --project=docs -e '
95-
if ENV["BUILD_DOCS"] == "true"
96-
using Pkg
97-
Pkg.develop(PackageSpec(path=pwd()))
98-
Pkg.instantiate()
99-
end'
100-
- run: |
101-
julia --project=docs -e '
102-
if ENV["BUILD_DOCS"] == "true"
103-
using Documenter: doctest
104-
using OpenML
105-
@info "attempting to run the doctests"
106-
doctest(OpenML)
107-
else
108-
@info "skipping the doctests"
109-
end'
110-
- run: julia --project=docs -e '
111-
if ENV["BUILD_DOCS"] == "true"
112-
@info "attempting to build the docs"
113-
run(`julia --project=docs docs/make.jl`)
114-
@info "successfully built the docs"
115-
else
116-
@info "skipping the docs build"
117-
end'
59+
- uses: julia-actions/julia-buildpkg@latest
60+
- uses: julia-actions/julia-docdeploy@latest
11861
env:
11962
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
12063
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
64+
- run: |
65+
julia --project=docs -e '
66+
using Documenter: DocMeta, doctest
67+
using OpenML
68+
DocMeta.setdocmeta!(OpenML, :DocTestSetup, :(using OpenML); recursive=true)
69+
doctest(OpenML)'

.github/workflows/TagBot.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,22 @@ on:
44
types:
55
- created
66
workflow_dispatch:
7+
inputs:
8+
lookback:
9+
default: "3"
10+
permissions:
11+
actions: read
12+
checks: read
13+
contents: write
14+
deployments: read
15+
issues: read
16+
discussions: read
17+
packages: read
18+
pages: read
19+
pull-requests: read
20+
repository-projects: read
21+
security-events: read
22+
statuses: read
723
jobs:
824
TagBot:
925
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
@@ -12,4 +28,6 @@ jobs:
1228
- uses: JuliaRegistries/TagBot@v1
1329
with:
1430
token: ${{ secrets.GITHUB_TOKEN }}
31+
# Edit the following line to reflect the actual name of the GitHub Secret containing your private key
1532
ssh: ${{ secrets.DOCUMENTER_KEY }}
33+
# ssh: ${{ secrets.NAME_OF_MY_SSH_PRIVATE_KEY_SECRET }}

Project.toml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
name = "OpenML"
22
uuid = "8b6db2d4-7670-4922-a472-f9537c81ab66"
33
authors = ["Diego Arenas <[email protected]>", "Anthony D. Blaom <[email protected]>"]
4-
version = "0.3.1"
4+
version = "0.3.3"
55

66
[deps]
77
ARFFFiles = "da404889-ca92-49ff-9e8b-0aa6b4d38dc8"
8+
Downloads = "f43a241f-c20a-4ad4-852c-f6b1247861c6"
89
HTTP = "cd3eb016-35fb-5094-929b-558a96fad6f3"
910
JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
1011
Markdown = "d6f4376e-aef5-505a-96c1-9c027394607a"
@@ -13,15 +14,16 @@ Scratch = "6c6a2e73-6563-6170-7368-637461726353"
1314

1415
[compat]
1516
ARFFFiles = "1.4.1"
17+
Downloads = "1.6.0"
1618
HTTP = "0.8, 0.9, 1"
17-
JSON = "0.21"
19+
JSON = "0.21, 1"
1820
Scratch = "1.1"
1921
julia = "1.6"
2022

2123
[extras]
24+
Logging = "56ddb016-857b-54e1-b83d-db4d58db5568"
2225
Tables = "bd369af6-aec1-5ad0-b16a-f7cc5008161c"
2326
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
24-
Logging = "56ddb016-857b-54e1-b83d-db4d58db5568"
2527

2628
[targets]
2729
test = ["Tables", "Test", "Logging"]

README.md

Lines changed: 0 additions & 21 deletions
This file was deleted.

docs/Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ OpenML = "8b6db2d4-7670-4922-a472-f9537c81ab66"
55
ScientificTypes = "321657f4-b219-11e9-178b-2701a2544e81"
66

77
[compat]
8-
Documenter = "~0.26"
8+
Documenter = "1"

docs/README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
Contains both the original `Documenter.jl` documentation and the same documentation rendered as markdown to include in the harmonized OpenML docs.
2+
3+
Generating the markdown is done as follows:
4+
5+
* Install [DocumenterMarkDown](https://documentermarkdown.juliadocs.org/dev/).
6+
* Note: currently this only works with version 0.27 of Documenter.jl
7+
* In Julia, open the package manager (type ']') and run `add [email protected]` and `add DocumenterMarkdown`.
8+
* Run `julia make-md.jl` in the `docs` folder to generate the markdown filew
9+
* These appear in the `build` folder
10+
* Run `mkdocs serve` in the root folder to build the markdown docs.
11+

docs/make-md.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
using OpenML, DataFrames, ScientificTypes, DocumenterMarkdown, Documenter
2+
3+
makedocs(
4+
format = Markdown(),
5+
modules = [OpenML,],
6+
sitename = "OpenML.jl",
7+
)

docs/make.jl

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
using Documenter, OpenML, DataFrames
22

3+
const REPO = Remotes.GitHub("JuliaAI", "OpenML.jl")
4+
35
makedocs(
46
modules = [OpenML,],
57
sitename = "OpenML.jl",
8+
warnonly = [:cross_references, :missing_docs],
9+
repo = Remotes.GitHub("JuliaAI", "LearnAPI.jl"),
610
)
711

812
deploydocs(
9-
repo = "github.com/JuliaAI/OpenML.jl",
10-
push_preview = true
13+
repo = "github.com/JuliaAI/OpenML.jl.git",
14+
devbranch="dev",
1115
)

mkdocs.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
site_name: OpenML.jl
2+
repo_url: https://github.com/openml/OpenML.jl
3+
site_description: "This is the reference documentation of OpenML.jl"
4+
5+
theme:
6+
name: "material"
7+
language: "en"
8+
palette:
9+
# Light mode
10+
- media: "(prefers-color-scheme: light)"
11+
scheme: default
12+
primary: indigo
13+
accent: indigo
14+
toggle:
15+
icon: material/toggle-switch-off-outline
16+
name: Switch to dark mode
17+
# Dark mode
18+
- media: "(prefers-color-scheme: dark)"
19+
primary: indigo
20+
accent: indigo
21+
scheme: slate
22+
toggle:
23+
icon: material/toggle-switch
24+
name: Switch to light mode
25+
font:
26+
text: "Roboto"
27+
code: "Roboto Mono"
28+
icon:
29+
edit: material/pencil
30+
view: material/eye
31+
32+
extra_css:
33+
- assets/Documenter.css
34+
35+
extra_javascript:
36+
- https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS_HTML
37+
- assets/mathjaxhelper.js
38+
39+
markdown_extensions:
40+
- extra
41+
- tables
42+
- fenced_code
43+
- admonition
44+
- codehilite
45+
- attr_list
46+
- pymdownx.details
47+
- pymdownx.highlight:
48+
anchor_linenums: true
49+
line_spans: __span
50+
pygments_lang_class: true
51+
- pymdownx.inlinehilite
52+
- pymdownx.snippets
53+
- pymdownx.superfences
54+
55+
56+
docs_dir: 'docs/build'
57+
58+
nav:
59+
- Home: index.md

src/OpenML.jl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ using JSON
55
import ARFFFiles
66
using Markdown
77
using Scratch
8+
import Downloads
89

910
export OpenML
1011

@@ -17,3 +18,4 @@ function __init__()
1718
end
1819

1920
end # module
21+

0 commit comments

Comments
 (0)