-
Notifications
You must be signed in to change notification settings - Fork 328
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This merge introduces v8.0.0 of MPAS-Atmosphere. For a summary of significant changes, please see the annotation of the v8.0.0 tag.
- Loading branch information
Showing
171 changed files
with
41,977 additions
and
15,048 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,141 @@ | ||
trigger: | ||
branches: | ||
include: | ||
- master | ||
- develop | ||
- ocean/develop | ||
- lanice/develop | ||
- ocean/coastal | ||
tags: | ||
include: | ||
- '*' | ||
pr: | ||
branches: | ||
include: | ||
- master | ||
- develop | ||
- ocean/develop | ||
- lanice/develop | ||
- ocean/coastal | ||
|
||
jobs: | ||
- job: | ||
displayName: docs | ||
pool: | ||
vmImage: 'ubuntu-16.04' | ||
strategy: | ||
matrix: | ||
Python38: | ||
python.version: '3.8' | ||
|
||
steps: | ||
- bash: echo "##vso[task.prependpath]$CONDA/bin" | ||
displayName: Add conda to PATH | ||
|
||
- bash: | | ||
set -e | ||
eval "$(conda shell.bash hook)" | ||
conda config --add channels conda-forge | ||
conda config --set channel_priority strict | ||
displayName: Configure conda | ||
- bash: | | ||
set -e | ||
eval "$(conda shell.bash hook)" | ||
conda create -y -n docs python=$PYTHON_VERSION sphinx mock sphinx_rtd_theme m2r | ||
displayName: Create docs environment | ||
- bash: | | ||
set -e | ||
eval "$(conda shell.bash hook)" | ||
conda activate docs | ||
echo "source branch: $(Build.SourceBranch)" | ||
echo "repository: $(Build.Repository.Name)" | ||
tag=$(git describe --tags $(git rev-list --tags --max-count=1)) | ||
echo "tag: $tag" | ||
REPO_PATH=$PWD | ||
if [[ "$(Build.SourceBranch)" == refs/tags/* ]]; then | ||
echo "this is a tag build" | ||
export DOCS_VERSION="$tag" | ||
deploy=True | ||
run=True | ||
elif [[ "$(Build.SourceBranch)" == refs/heads/* ]]; then | ||
branch="$(Build.SourceBranchName)" | ||
echo "this is a merge build of $branch" | ||
deploy=True | ||
elif [[ "$(Build.SourceBranch)" == refs/pull/*/merge ]]; then | ||
branch="$(System.PullRequest.TargetBranch)" | ||
echo "this is a pull request into $branch" | ||
deploy=False | ||
fi | ||
if [ -n ${branch} ]; then | ||
echo "This build is for branch $branch" | ||
if [[ ${branch} == "master" ]]; then | ||
export DOCS_VERSION="stable" | ||
run=True | ||
elif [[ ${branch} == "develop" ]]; then | ||
export DOCS_VERSION="latest" | ||
run=True | ||
elif [[ ${branch} == "ocean/develop" ]]; then | ||
export DOCS_VERSION="latest ocean" | ||
run=True | ||
elif [[ ${branch} == "ocean/coastal" ]]; then | ||
export DOCS_VERSION="latest coastal" | ||
run=True | ||
elif [[ ${branch} == "landice/develop" ]]; then | ||
export DOCS_VERSION="latest landice" | ||
run=True | ||
else | ||
echo "We don't build docs for $branch" | ||
deploy=False | ||
run=False | ||
fi | ||
fi | ||
if [[ "${run}" == "False" ]]; then | ||
echo "Not building docs for branch ${branch}" | ||
exit 0 | ||
fi | ||
echo "Docs version: $DOCS_VERSION" | ||
echo "Deploy to gh-pages? $deploy" | ||
cd docs || exit 1 | ||
make html | ||
cd "$REPO_PATH" || exit 1 | ||
if [[ "$deploy" == "False" ]]; then | ||
exit 0 | ||
fi | ||
PUBLICATION_BRANCH=gh-pages | ||
DOCS_PATH="${DOCS_VERSION// /_}" | ||
# Checkout the branch | ||
pushd $HOME || exit 1 | ||
git clone --branch=$PUBLICATION_BRANCH https://$(GitHubToken)@github.com/$(Build.Repository.Name) publish | ||
cd publish || exit 1 | ||
# Update pages | ||
if [[ -d "$DOCS_PATH" ]]; then | ||
git rm -rf "$DOCS_PATH" > /dev/null | ||
fi | ||
mkdir "$DOCS_PATH" | ||
cp -r "$REPO_PATH"/docs/_build/html/* "$DOCS_PATH" | ||
# Commit and push latest version | ||
git add . | ||
if git diff-index --quiet HEAD; then | ||
echo "No changes in the docs." | ||
else | ||
git config --local user.name "Azure Pipelines" | ||
git config --local user.email "[email protected]" | ||
git commit -m "[skip ci] Update $DOCS_VERSION" | ||
git push -fq origin $PUBLICATION_BRANCH | ||
fi | ||
popd || exit 1 | ||
displayName: build and deploy docs | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Minimal makefile for Sphinx documentation | ||
# | ||
|
||
# You can set these variables from the command line. | ||
SPHINXOPTS = | ||
SPHINXBUILD = sphinx-build | ||
SPHINXPROJ = mpas_model | ||
SOURCEDIR = . | ||
BUILDDIR = _build | ||
|
||
# Put it first so that "make" without argument is like "make help". | ||
help: | ||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
||
.PHONY: help Makefile | ||
|
||
# Catch-all target: route all unknown targets to Sphinx using the new | ||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
%: Makefile | ||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,182 @@ | ||
# -*- coding: utf-8 -*- | ||
# | ||
# MPAS-Model documentation build configuration file, created by | ||
# sphinx-quickstart on Sat Mar 25 14:39:11 2017. | ||
# | ||
# This file is execfile()d with the current directory set to its | ||
# containing dir. | ||
# | ||
# Note that not all possible configuration values are present in this | ||
# autogenerated file. | ||
# | ||
# All configuration values have a default; values that are commented out | ||
# serve to show the default. | ||
|
||
import os | ||
|
||
# -- General configuration ------------------------------------------------ | ||
|
||
# If your documentation needs a minimal Sphinx version, state it here. | ||
# | ||
# needs_sphinx = '1.0' | ||
|
||
# Add any Sphinx extension module names here, as strings. They can be | ||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom | ||
# ones. | ||
extensions = ['sphinx.ext.autodoc', | ||
'sphinx.ext.autosummary', | ||
'sphinx.ext.intersphinx', | ||
'sphinx.ext.mathjax', | ||
'sphinx.ext.viewcode', | ||
'sphinx.ext.napoleon'] | ||
|
||
autosummary_generate = True | ||
|
||
# Otherwise, the Return parameter list looks different from the Parameters list | ||
napoleon_use_rtype = False | ||
# Otherwise, the Attributes parameter list looks different from the Parameters | ||
# list | ||
napoleon_use_ivar = True | ||
|
||
# Add any paths that contain templates here, relative to this directory. | ||
templates_path = ['_templates'] | ||
|
||
# The suffix(es) of source filenames. | ||
# You can specify multiple suffix as a list of string: | ||
# | ||
source_suffix = ['.rst'] | ||
# source_suffix = '.rst' | ||
|
||
# The master toctree document. | ||
master_doc = 'index' | ||
|
||
# General information about the project. | ||
project = u'MPAS-Model' | ||
copyright = u'Copyright (c) 2013-2020, Los Alamos National Security, LLC (LANS) (Ocean: LA-CC-13-047;' \ | ||
u'Land Ice: LA-CC-13-117) and the University Corporation for Atmospheric Research (UCAR).' | ||
author = u'Xylar Asay-Davis, Doug Jacobsen, Michael Duda, Mark Petersen, ' \ | ||
u'Matt Hoffman, Adridan Turner, Philip Wolfram' | ||
|
||
# The version info for the project you're documenting, acts as replacement for | ||
# |version| and |release|, also used in various other places throughout the | ||
# built documents. | ||
if 'DOCS_VERSION' in os.environ: | ||
version = os.environ.get('DOCS_VERSION') | ||
release = version | ||
else: | ||
# The short X.Y.Z version. | ||
version = '7.0' | ||
# The full version, including alpha/beta/rc tags. | ||
release = '7.0' | ||
|
||
# The language for content autogenerated by Sphinx. Refer to documentation | ||
# for a list of supported languages. | ||
# | ||
# This is also used if you do content translation via gettext catalogs. | ||
# Usually you set "language" from the command line for these cases. | ||
language = None | ||
|
||
# List of patterns, relative to source directory, that match files and | ||
# directories to ignore when looking for source files. | ||
# This patterns also effect to html_static_path and html_extra_path | ||
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', | ||
'design_docs/template.md'] | ||
|
||
# The name of the Pygments (syntax highlighting) style to use. | ||
pygments_style = 'sphinx' | ||
|
||
# If true, `todo` and `todoList` produce output, else they produce nothing. | ||
todo_include_todos = False | ||
|
||
|
||
# -- Options for HTML output ---------------------------------------------- | ||
|
||
# The theme to use for HTML and HTML Help pages. See the documentation for | ||
# a list of builtin themes. | ||
# | ||
|
||
# on_rtd is whether we are on readthedocs.org, this line of code grabbed from | ||
# docs.readthedocs.org | ||
on_rtd = os.environ.get('READTHEDOCS', None) == 'True' | ||
|
||
if not on_rtd: # only import and set the theme if we're building docs locally | ||
import sphinx_rtd_theme | ||
html_theme = 'sphinx_rtd_theme' | ||
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] | ||
|
||
# Theme options are theme-specific and customize the look and feel of a theme | ||
# further. For a list of options available for each theme, see the | ||
# documentation. | ||
# | ||
# html_theme_options = {} | ||
|
||
# Add any paths that contain custom static files (such as style sheets) here, | ||
# relative to this directory. They are copied after the builtin static files, | ||
# so a file named "default.css" will overwrite the builtin "default.css". | ||
html_static_path = ['_static'] | ||
|
||
|
||
# -- Options for HTMLHelp output ------------------------------------------ | ||
|
||
# Output file base name for HTML help builder. | ||
htmlhelp_basename = 'mpas_model_doc' | ||
|
||
|
||
# -- Options for LaTeX output --------------------------------------------- | ||
|
||
latex_elements = { | ||
# The paper size ('letterpaper' or 'a4paper'). | ||
# | ||
# 'papersize': 'letterpaper', | ||
|
||
# The font size ('10pt', '11pt' or '12pt'). | ||
# | ||
# 'pointsize': '10pt', | ||
|
||
# Additional stuff for the LaTeX preamble. | ||
# | ||
# 'preamble': '', | ||
|
||
# Latex figure (float) alignment | ||
# | ||
# 'figure_align': 'htbp', | ||
} | ||
|
||
# Grouping the document tree into LaTeX files. List of tuples | ||
# (source start file, target name, title, | ||
# author, documentclass [howto, manual, or own class]). | ||
latex_documents = [ | ||
(master_doc, 'mpas_model.tex', u'MPAS-Model Documentation', | ||
author, 'manual'), | ||
] | ||
|
||
|
||
# -- Options for manual page output --------------------------------------- | ||
|
||
# One entry per manual page. List of tuples | ||
# (source start file, name, description, authors, manual section). | ||
man_pages = [ | ||
(master_doc, 'mpas_model', u'MPAS-Model Documentation', | ||
[author], 1) | ||
] | ||
|
||
|
||
# -- Options for Texinfo output ------------------------------------------- | ||
|
||
# Grouping the document tree into Texinfo files. List of tuples | ||
# (source start file, target name, title, author, | ||
# dir menu entry, description, category) | ||
texinfo_documents = [ | ||
(master_doc, 'mpas_model', u'MPAS-Model Documentation', | ||
author, 'MPAS-Model', 'One line description of project.', | ||
'Miscellaneous'), | ||
] | ||
|
||
# Example configuration for intersphinx: refer to the Python standard library. | ||
intersphinx_mapping = { | ||
'python': ('https://docs.python.org/', None), | ||
'numpy': ('http://docs.scipy.org/doc/numpy/', None), | ||
'xarray': ('http://xarray.pydata.org/en/stable/', None)} | ||
|
||
|
||
github_doc_root = 'https://github.com/rtfd/recommonmark/tree/master/doc/' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
MPAS-Model | ||
========== | ||
|
||
The Model for Prediction Across Scales (MPAS) is a collaborative project for | ||
developing atmosphere, ocean, and other earth-system simulation components for | ||
use in climate, regional climate, and weather studies. The primary development | ||
partners are the climate modeling group at Los Alamos National Laboratory | ||
(COSIM) and the National Center for Atmospheric Research. Both primary | ||
partners are responsible for the MPAS framework, operators, and tools common to | ||
the applications; LANL has primary responsibility for the ocean, sea-ice and | ||
land-ice models, and NCAR has primary responsibility for the atmospheric model. | ||
|
||
The MPAS framework facilitates the rapid development and prototyping of models | ||
by providing infrastructure typically required by model developers, including | ||
high-level data types, communication routines, and I/O routines. By using MPAS, | ||
developers can leverage pre-existing code and focus more on development of | ||
|
||
.. toctree:: | ||
:titlesonly: | ||
|
||
ocean/index | ||
|
||
|
Oops, something went wrong.