Skip to content

Commit

Permalink
Merge pull request #36 from annacasavant/ac_docs_updates
Browse files Browse the repository at this point in the history
Documentation Updates
  • Loading branch information
jd-lara authored Feb 12, 2025
2 parents fff5404 + a77b687 commit 38b350a
Show file tree
Hide file tree
Showing 12 changed files with 66 additions and 73 deletions.
5 changes: 4 additions & 1 deletion docs/Project.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
[deps]
DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8"
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
DocumenterTools = "35a29f4d-8980-5a13-9543-d66fff28ecb8"
Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306"
PowerAnalytics = "56ce1300-00bc-47e4-ba8c-b166ccc19f51"
PowerSimulations = "e690365d-45e2-57bb-ac84-44ba829e73c4"
StyledStrings = "f489334b-da3d-4c2e-b8f0-e476e12c162b"

[compat]
Documenter = "~0.27"
Documenter = "^1.7"
60 changes: 23 additions & 37 deletions docs/make.jl
Original file line number Diff line number Diff line change
@@ -1,53 +1,39 @@
using Documenter
using PowerAnalytics
using Literate
import DataStructures: OrderedDict

folders = Dict()

for (name, folder) in folders
for file in folder
outputdir = joinpath(pwd(), "docs/src/howto")
inputfile = joinpath(pwd(), "docs/src/$name/$file")
Literate.markdown(inputfile, outputdir)
end
end
if isfile("docs/src/howto/.DS_Store.md")
rm("docs/src/howto/.DS_Store.md")
end
pages = OrderedDict(
"Welcome Page" => "index.md",
"Tutorials" => Any["stub" => "tutorials/stub.md"],
"How to..." => Any["stub" => "how_to_guides/stub.md"],
"Explanation" => Any["stub" => "explanation/stub.md"],
"Reference" => Any[
"Public API" => "reference/public.md",
"Developers" => ["Developer Guidelines" => "reference/developer_guidelines.md",
"Internals" => "reference/internal.md"]]

)


makedocs(
sitename = "PowerAnalytics.jl",
format = Documenter.HTML(
mathengine = Documenter.MathJax(),
prettyurls = get(ENV, "CI", nothing) == "true",
),
modules = [PowerAnalytics],
authors = "Clayton Barrows",
pages = Any[
"Introduction" => "index.md",
#"Quick Start Guide" => "qs_guide.md",
#"Logging" => "man/logging.md",
# "Operation Model" => "man/op_problem.md",
# "How To" => Any[
# "Set Up Plots" => "howto/3.0_set_up_plots.md",
# "Make Stack Plots" => "howto/3.1_make_stack_plots.md",
# "Make Bar Plots" => "howto/3.2_make_bar_plots.md",
# "Make Fuel Plots" => "howto/3.3_make_fuel_plots.md",
# "Make Forecast Plots" => "howto/3.4_make_forecast_plots.md",
# "Plot Fewer Variables" => "howto/3.5_plot_fewer_variables.md",
# "Plot Multiple Results" => "howto/3.6_plot_multiple_results.md",
# ],
#"Simulation Recorder" => "man/simulation_recorder.md",
#"Model References" => Any["Hydro Models" => "ref/hydro.md"],
"API" => Any["PowerAnalytics" => "api/PowerAnalytics.md"],
],
format = Documenter.HTML(
prettyurls = haskey(ENV, "GITHUB_ACTIONS"),
size_threshold = nothing,),
sitename = "PowerAnalytics.jl",
authors = "Gabriel Konar-Steenberg and Clayton Barrows",
pages = Any[p for p in pages],
draft = false,
)


deploydocs(
repo="github.com/NREL-Sienna/PowerAnalytics.jl.git",
repo= "github.com/NREL-Sienna/PowerAnalytics.jl",
target="build",
branch="gh-pages",
devbranch="main",
devurl="dev",
push_preview=true,
versions=["stable" => "v^", "v#.#"],
)
34 changes: 0 additions & 34 deletions docs/src/api/PowerAnalytics.md

This file was deleted.

Binary file modified docs/src/assets/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions docs/src/explanation/stub.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## Explanation

Refer here to find context and further explanation of the workings of `PowerAnalytics`.
3 changes: 3 additions & 0 deletions docs/src/how_to_guides/stub.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## How-to Guides

How-to's can be be referenced when looking for guidance for specific scenarios and issues in `PowerAnalytics`.
12 changes: 12 additions & 0 deletions docs/src/reference/developer_guidelines.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Developer Guidelines

In order to contribute to `PowerSystems.jl` repository please read the following sections of
[`InfrastructureSystems.jl`](https://github.com/NREL-Sienna/InfrastructureSystems.jl) and [`SiennaTemplate.jl`](https://github.com/NREL-Sienna/SiennaTemplate.jl)
documentation in detail:

1. [Style Guide](https://nrel-sienna.github.io/InfrastructureSystems.jl/stable/style/)
2. [Contributing Guidelines](https://github.com/NREL-Sienna/SiennaTemplate.jl/blob/main/CONTRIBUTING.md)

Pull requests are always welcome to fix bugs or add additional modeling capabilities.

**All the code contributions need to include tests with a minimum coverage of 70%**
8 changes: 8 additions & 0 deletions docs/src/reference/internal.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
## Internal

```@autodocs
Modules = [PowerAnalytics,
PowerAnalytics.Metrics,
PowerAnalytics.Selectors]
Public = false
```
8 changes: 8 additions & 0 deletions docs/src/reference/public.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
## Exported

```@autodocs
Modules = [PowerAnalytics,
PowerAnalytics.Metrics,
PowerAnalytics.Selectors]
Private = false
```
3 changes: 3 additions & 0 deletions docs/src/tutorials/stub.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## Tutorials

Refer here for step-by-step tutorials that will guide you through the different capabilities of `PowerAnalytics`.
1 change: 1 addition & 0 deletions scripts/formatter/formatter_code.jl
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@ for main_path in main_paths
end
end
end

2 changes: 1 addition & 1 deletion src/input_utils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ values are loaded results datasets.
- `scenarios::Union{Vector{AbstractString}, Nothing} = nothing`: a list of scenario
subdirectories to load, or `nothing` to load all the subdirectories
- `kwargs...`: keyword arguments to pass through to
[`PSI.get_decision_problem_results`](@ref)
`get_decision_problem_results`
"""
function create_problem_results_dict(
results_dir::AbstractString,
Expand Down

0 comments on commit 38b350a

Please sign in to comment.