From d81bd47b6a5cd55b8e67ed16108635fb6a8b9e0a Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:07:08 -0500
Subject: [PATCH 01/34] Add CC-BY-4.0 License

---
 LICENSE   | 395 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 README.md |   6 +
 2 files changed, 401 insertions(+)
 create mode 100644 LICENSE

diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..52bd145
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,395 @@
+Attribution 4.0 International
+
+=======================================================================
+
+Creative Commons Corporation ("Creative Commons") is not a law firm and
+does not provide legal services or legal advice. Distribution of
+Creative Commons public licenses does not create a lawyer-client or
+other relationship. Creative Commons makes its licenses and related
+information available on an "as-is" basis. Creative Commons gives no
+warranties regarding its licenses, any material licensed under their
+terms and conditions, or any related information. Creative Commons
+disclaims all liability for damages resulting from their use to the
+fullest extent possible.
+
+Using Creative Commons Public Licenses
+
+Creative Commons public licenses provide a standard set of terms and
+conditions that creators and other rights holders may use to share
+original works of authorship and other material subject to copyright
+and certain other rights specified in the public license below. The
+following considerations are for informational purposes only, are not
+exhaustive, and do not form part of our licenses.
+
+     Considerations for licensors: Our public licenses are
+     intended for use by those authorized to give the public
+     permission to use material in ways otherwise restricted by
+     copyright and certain other rights. Our licenses are
+     irrevocable. Licensors should read and understand the terms
+     and conditions of the license they choose before applying it.
+     Licensors should also secure all rights necessary before
+     applying our licenses so that the public can reuse the
+     material as expected. Licensors should clearly mark any
+     material not subject to the license. This includes other CC-
+     licensed material, or material used under an exception or
+     limitation to copyright. More considerations for licensors:
+	wiki.creativecommons.org/Considerations_for_licensors
+
+     Considerations for the public: By using one of our public
+     licenses, a licensor grants the public permission to use the
+     licensed material under specified terms and conditions. If
+     the licensor's permission is not necessary for any reason--for
+     example, because of any applicable exception or limitation to
+     copyright--then that use is not regulated by the license. Our
+     licenses grant only permissions under copyright and certain
+     other rights that a licensor has authority to grant. Use of
+     the licensed material may still be restricted for other
+     reasons, including because others have copyright or other
+     rights in the material. A licensor may make special requests,
+     such as asking that all changes be marked or described.
+     Although not required by our licenses, you are encouraged to
+     respect those requests where reasonable. More_considerations
+     for the public:
+	wiki.creativecommons.org/Considerations_for_licensees
+
+=======================================================================
+
+Creative Commons Attribution 4.0 International Public License
+
+By exercising the Licensed Rights (defined below), You accept and agree
+to be bound by the terms and conditions of this Creative Commons
+Attribution 4.0 International Public License ("Public License"). To the
+extent this Public License may be interpreted as a contract, You are
+granted the Licensed Rights in consideration of Your acceptance of
+these terms and conditions, and the Licensor grants You such rights in
+consideration of benefits the Licensor receives from making the
+Licensed Material available under these terms and conditions.
+
+
+Section 1 -- Definitions.
+
+  a. Adapted Material means material subject to Copyright and Similar
+     Rights that is derived from or based upon the Licensed Material
+     and in which the Licensed Material is translated, altered,
+     arranged, transformed, or otherwise modified in a manner requiring
+     permission under the Copyright and Similar Rights held by the
+     Licensor. For purposes of this Public License, where the Licensed
+     Material is a musical work, performance, or sound recording,
+     Adapted Material is always produced where the Licensed Material is
+     synched in timed relation with a moving image.
+
+  b. Adapter's License means the license You apply to Your Copyright
+     and Similar Rights in Your contributions to Adapted Material in
+     accordance with the terms and conditions of this Public License.
+
+  c. Copyright and Similar Rights means copyright and/or similar rights
+     closely related to copyright including, without limitation,
+     performance, broadcast, sound recording, and Sui Generis Database
+     Rights, without regard to how the rights are labeled or
+     categorized. For purposes of this Public License, the rights
+     specified in Section 2(b)(1)-(2) are not Copyright and Similar
+     Rights.
+
+  d. Effective Technological Measures means those measures that, in the
+     absence of proper authority, may not be circumvented under laws
+     fulfilling obligations under Article 11 of the WIPO Copyright
+     Treaty adopted on December 20, 1996, and/or similar international
+     agreements.
+
+  e. Exceptions and Limitations means fair use, fair dealing, and/or
+     any other exception or limitation to Copyright and Similar Rights
+     that applies to Your use of the Licensed Material.
+
+  f. Licensed Material means the artistic or literary work, database,
+     or other material to which the Licensor applied this Public
+     License.
+
+  g. Licensed Rights means the rights granted to You subject to the
+     terms and conditions of this Public License, which are limited to
+     all Copyright and Similar Rights that apply to Your use of the
+     Licensed Material and that the Licensor has authority to license.
+
+  h. Licensor means the individual(s) or entity(ies) granting rights
+     under this Public License.
+
+  i. Share means to provide material to the public by any means or
+     process that requires permission under the Licensed Rights, such
+     as reproduction, public display, public performance, distribution,
+     dissemination, communication, or importation, and to make material
+     available to the public including in ways that members of the
+     public may access the material from a place and at a time
+     individually chosen by them.
+
+  j. Sui Generis Database Rights means rights other than copyright
+     resulting from Directive 96/9/EC of the European Parliament and of
+     the Council of 11 March 1996 on the legal protection of databases,
+     as amended and/or succeeded, as well as other essentially
+     equivalent rights anywhere in the world.
+
+  k. You means the individual or entity exercising the Licensed Rights
+     under this Public License. Your has a corresponding meaning.
+
+
+Section 2 -- Scope.
+
+  a. License grant.
+
+       1. Subject to the terms and conditions of this Public License,
+          the Licensor hereby grants You a worldwide, royalty-free,
+          non-sublicensable, non-exclusive, irrevocable license to
+          exercise the Licensed Rights in the Licensed Material to:
+
+            a. reproduce and Share the Licensed Material, in whole or
+               in part; and
+
+            b. produce, reproduce, and Share Adapted Material.
+
+       2. Exceptions and Limitations. For the avoidance of doubt, where
+          Exceptions and Limitations apply to Your use, this Public
+          License does not apply, and You do not need to comply with
+          its terms and conditions.
+
+       3. Term. The term of this Public License is specified in Section
+          6(a).
+
+       4. Media and formats; technical modifications allowed. The
+          Licensor authorizes You to exercise the Licensed Rights in
+          all media and formats whether now known or hereafter created,
+          and to make technical modifications necessary to do so. The
+          Licensor waives and/or agrees not to assert any right or
+          authority to forbid You from making technical modifications
+          necessary to exercise the Licensed Rights, including
+          technical modifications necessary to circumvent Effective
+          Technological Measures. For purposes of this Public License,
+          simply making modifications authorized by this Section 2(a)
+          (4) never produces Adapted Material.
+
+       5. Downstream recipients.
+
+            a. Offer from the Licensor -- Licensed Material. Every
+               recipient of the Licensed Material automatically
+               receives an offer from the Licensor to exercise the
+               Licensed Rights under the terms and conditions of this
+               Public License.
+
+            b. No downstream restrictions. You may not offer or impose
+               any additional or different terms or conditions on, or
+               apply any Effective Technological Measures to, the
+               Licensed Material if doing so restricts exercise of the
+               Licensed Rights by any recipient of the Licensed
+               Material.
+
+       6. No endorsement. Nothing in this Public License constitutes or
+          may be construed as permission to assert or imply that You
+          are, or that Your use of the Licensed Material is, connected
+          with, or sponsored, endorsed, or granted official status by,
+          the Licensor or others designated to receive attribution as
+          provided in Section 3(a)(1)(A)(i).
+
+  b. Other rights.
+
+       1. Moral rights, such as the right of integrity, are not
+          licensed under this Public License, nor are publicity,
+          privacy, and/or other similar personality rights; however, to
+          the extent possible, the Licensor waives and/or agrees not to
+          assert any such rights held by the Licensor to the limited
+          extent necessary to allow You to exercise the Licensed
+          Rights, but not otherwise.
+
+       2. Patent and trademark rights are not licensed under this
+          Public License.
+
+       3. To the extent possible, the Licensor waives any right to
+          collect royalties from You for the exercise of the Licensed
+          Rights, whether directly or through a collecting society
+          under any voluntary or waivable statutory or compulsory
+          licensing scheme. In all other cases the Licensor expressly
+          reserves any right to collect such royalties.
+
+
+Section 3 -- License Conditions.
+
+Your exercise of the Licensed Rights is expressly made subject to the
+following conditions.
+
+  a. Attribution.
+
+       1. If You Share the Licensed Material (including in modified
+          form), You must:
+
+            a. retain the following if it is supplied by the Licensor
+               with the Licensed Material:
+
+                 i. identification of the creator(s) of the Licensed
+                    Material and any others designated to receive
+                    attribution, in any reasonable manner requested by
+                    the Licensor (including by pseudonym if
+                    designated);
+
+                ii. a copyright notice;
+
+               iii. a notice that refers to this Public License;
+
+                iv. a notice that refers to the disclaimer of
+                    warranties;
+
+                 v. a URI or hyperlink to the Licensed Material to the
+                    extent reasonably practicable;
+
+            b. indicate if You modified the Licensed Material and
+               retain an indication of any previous modifications; and
+
+            c. indicate the Licensed Material is licensed under this
+               Public License, and include the text of, or the URI or
+               hyperlink to, this Public License.
+
+       2. You may satisfy the conditions in Section 3(a)(1) in any
+          reasonable manner based on the medium, means, and context in
+          which You Share the Licensed Material. For example, it may be
+          reasonable to satisfy the conditions by providing a URI or
+          hyperlink to a resource that includes the required
+          information.
+
+       3. If requested by the Licensor, You must remove any of the
+          information required by Section 3(a)(1)(A) to the extent
+          reasonably practicable.
+
+       4. If You Share Adapted Material You produce, the Adapter's
+          License You apply must not prevent recipients of the Adapted
+          Material from complying with this Public License.
+
+
+Section 4 -- Sui Generis Database Rights.
+
+Where the Licensed Rights include Sui Generis Database Rights that
+apply to Your use of the Licensed Material:
+
+  a. for the avoidance of doubt, Section 2(a)(1) grants You the right
+     to extract, reuse, reproduce, and Share all or a substantial
+     portion of the contents of the database;
+
+  b. if You include all or a substantial portion of the database
+     contents in a database in which You have Sui Generis Database
+     Rights, then the database in which You have Sui Generis Database
+     Rights (but not its individual contents) is Adapted Material; and
+
+  c. You must comply with the conditions in Section 3(a) if You Share
+     all or a substantial portion of the contents of the database.
+
+For the avoidance of doubt, this Section 4 supplements and does not
+replace Your obligations under this Public License where the Licensed
+Rights include other Copyright and Similar Rights.
+
+
+Section 5 -- Disclaimer of Warranties and Limitation of Liability.
+
+  a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE
+     EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS
+     AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF
+     ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS,
+     IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION,
+     WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR
+     PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS,
+     ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT
+     KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT
+     ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU.
+
+  b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE
+     TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION,
+     NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT,
+     INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES,
+     COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR
+     USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN
+     ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR
+     DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR
+     IN PART, THIS LIMITATION MAY NOT APPLY TO YOU.
+
+  c. The disclaimer of warranties and limitation of liability provided
+     above shall be interpreted in a manner that, to the extent
+     possible, most closely approximates an absolute disclaimer and
+     waiver of all liability.
+
+
+Section 6 -- Term and Termination.
+
+  a. This Public License applies for the term of the Copyright and
+     Similar Rights licensed here. However, if You fail to comply with
+     this Public License, then Your rights under this Public License
+     terminate automatically.
+
+  b. Where Your right to use the Licensed Material has terminated under
+     Section 6(a), it reinstates:
+
+       1. automatically as of the date the violation is cured, provided
+          it is cured within 30 days of Your discovery of the
+          violation; or
+
+       2. upon express reinstatement by the Licensor.
+
+     For the avoidance of doubt, this Section 6(b) does not affect any
+     right the Licensor may have to seek remedies for Your violations
+     of this Public License.
+
+  c. For the avoidance of doubt, the Licensor may also offer the
+     Licensed Material under separate terms or conditions or stop
+     distributing the Licensed Material at any time; however, doing so
+     will not terminate this Public License.
+
+  d. Sections 1, 5, 6, 7, and 8 survive termination of this Public
+     License.
+
+
+Section 7 -- Other Terms and Conditions.
+
+  a. The Licensor shall not be bound by any additional or different
+     terms or conditions communicated by You unless expressly agreed.
+
+  b. Any arrangements, understandings, or agreements regarding the
+     Licensed Material not stated herein are separate from and
+     independent of the terms and conditions of this Public License.
+
+
+Section 8 -- Interpretation.
+
+  a. For the avoidance of doubt, this Public License does not, and
+     shall not be interpreted to, reduce, limit, restrict, or impose
+     conditions on any use of the Licensed Material that could lawfully
+     be made without permission under this Public License.
+
+  b. To the extent possible, if any provision of this Public License is
+     deemed unenforceable, it shall be automatically reformed to the
+     minimum extent necessary to make it enforceable. If the provision
+     cannot be reformed, it shall be severed from this Public License
+     without affecting the enforceability of the remaining terms and
+     conditions.
+
+  c. No term or condition of this Public License will be waived and no
+     failure to comply consented to unless expressly agreed to by the
+     Licensor.
+
+  d. Nothing in this Public License constitutes or may be interpreted
+     as a limitation upon, or waiver of, any privileges and immunities
+     that apply to the Licensor or You, including from the legal
+     processes of any jurisdiction or authority.
+
+
+=======================================================================
+
+Creative Commons is not a party to its public
+licenses. Notwithstanding, Creative Commons may elect to apply one of
+its public licenses to material it publishes and in those instances
+will be considered the “Licensor.” The text of the Creative Commons
+public licenses is dedicated to the public domain under the CC0 Public
+Domain Dedication. Except for the limited purpose of indicating that
+material is shared under a Creative Commons public license or as
+otherwise permitted by the Creative Commons policies published at
+creativecommons.org/policies, Creative Commons does not authorize the
+use of the trademark "Creative Commons" or any other trademark or logo
+of Creative Commons without its prior written consent including,
+without limitation, in connection with any unauthorized modifications
+to any of its public licenses or any other arrangements,
+understandings, or agreements concerning use of licensed material. For
+the avoidance of doubt, this paragraph does not form part of the
+public licenses.
+
+Creative Commons may be contacted at creativecommons.org.
\ No newline at end of file
diff --git a/README.md b/README.md
index 0ab01a7..5a4ecd8 100644
--- a/README.md
+++ b/README.md
@@ -1 +1,7 @@
 # GMT Examples
+
+## License
+
+[![Creative Commons License](https://i.creativecommons.org/l/by/4.0/88x31.png)](http://creativecommons.org/licenses/by/4.0/)
+This work is licensed under a
+[Creative Commons Attribution 4.0 International License](http://creativecommons.org/licenses/by/4.0/).

From ca09682c9938f62bb2e95fef8c3e629df86cec67 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:07:56 -0500
Subject: [PATCH 02/34] Add short description

---
 README.md | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/README.md b/README.md
index 5a4ecd8..d46f7dd 100644
--- a/README.md
+++ b/README.md
@@ -1,5 +1,8 @@
 # GMT Examples
 
+This repository contains tutorials and gallery examples for the Generic Mapping
+Tools.
+
 ## License
 
 [![Creative Commons License](https://i.creativecommons.org/l/by/4.0/88x31.png)](http://creativecommons.org/licenses/by/4.0/)

From 23e0066265df2078da9d5d59b53c1cc80b717d32 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:09:36 -0500
Subject: [PATCH 03/34] Add environment.yml

---
 environment.yml | 7 +++++++
 1 file changed, 7 insertions(+)
 create mode 100644 environment.yml

diff --git a/environment.yml b/environment.yml
new file mode 100644
index 0000000..0de97c1
--- /dev/null
+++ b/environment.yml
@@ -0,0 +1,7 @@
+name: gmt-examples
+  - conda-forge
+dependencies:
+  - gmt
+  - sphinx
+  - sphinx_gmt
+  - sphinx_rtd_theme

From 5fc15f97f6c98decac4f4080af28e960166f3fd1 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:10:24 -0500
Subject: [PATCH 04/34] Add .gitignore

---
 .gitignore | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
 create mode 100644 .gitignore

diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..d807264
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,15 @@
+# Sphinx documentation
+docs/_build/
+
+# Visual Studio Code
+.vscode/
+
+# Environments
+.env
+
+# Backup copies / swap files
+*~
+.*.swp
+
+# macOS
+.DS_Store

From 8372f96db2887c409e14e840b217782f3dcbeff6 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:21:22 -0500
Subject: [PATCH 05/34] Fix environment.yml

---
 environment.yml | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/environment.yml b/environment.yml
index 0de97c1..6bedf07 100644
--- a/environment.yml
+++ b/environment.yml
@@ -1,5 +1,7 @@
 name: gmt-examples
-  - conda-forge
+channels:
+    - conda-forge
+    - defaults
 dependencies:
   - gmt
   - sphinx

From eef7bb985e9988a834f6c0e7285d1c760aeb495f Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:38:25 -0500
Subject: [PATCH 06/34] Add requirements.txt

---
 requirements.txt | 4 ++++
 1 file changed, 4 insertions(+)
 create mode 100644 requirements.txt

diff --git a/requirements.txt b/requirements.txt
new file mode 100644
index 0000000..495bf86
--- /dev/null
+++ b/requirements.txt
@@ -0,0 +1,4 @@
+gmt
+sphinx
+sphinx_gmt
+sphinx_rtd_theme

From 2eaaaca1b2768b5403365f950f8624b4b58b8670 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:39:12 -0500
Subject: [PATCH 07/34] Add vercel.json

---
 vercel.json | 6 ++++++
 1 file changed, 6 insertions(+)
 create mode 100644 vercel.json

diff --git a/vercel.json b/vercel.json
new file mode 100644
index 0000000..7d1e698
--- /dev/null
+++ b/vercel.json
@@ -0,0 +1,6 @@
+{
+    "github": {
+      "silent": true
+    }
+  }
+  
\ No newline at end of file

From 0e474aba74c50b6f9c332cb5cca5126487bef825 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:47:25 -0500
Subject: [PATCH 08/34] Setup sphinx documentation for gmt-examples

---
 README.md                                     |  16 +++
 docs/Makefile                                 |  20 +++
 docs/_static/favicon.png                      | Bin 0 -> 4025 bytes
 .../Atkinson-Hyperlegible-Bold-102a.woff2     | Bin 0 -> 16484 bytes
 ...tkinson-Hyperlegible-BoldItalic-102a.woff2 | Bin 0 -> 18068 bytes
 .../Atkinson-Hyperlegible-Italic-102a.woff2   | Bin 0 -> 17712 bytes
 .../Atkinson-Hyperlegible-Regular-102a.woff2  | Bin 0 -> 15884 bytes
 docs/_static/fonts/LICENSE                    |  46 +++++++
 docs/_static/style.css                        | 123 ++++++++++++++++++
 docs/conf.py                                  |  63 +++++++++
 .../gallery/3d_plots/grdview_surface.rst      |  24 ++++
 docs/examples/tutorials/basics/coastlines.rst |  81 ++++++++++++
 docs/index.rst                                |  82 ++++++++++++
 docs/make.bat                                 |  35 +++++
 14 files changed, 490 insertions(+)
 create mode 100644 docs/Makefile
 create mode 100644 docs/_static/favicon.png
 create mode 100644 docs/_static/fonts/Atkinson-Hyperlegible-Bold-102a.woff2
 create mode 100644 docs/_static/fonts/Atkinson-Hyperlegible-BoldItalic-102a.woff2
 create mode 100644 docs/_static/fonts/Atkinson-Hyperlegible-Italic-102a.woff2
 create mode 100644 docs/_static/fonts/Atkinson-Hyperlegible-Regular-102a.woff2
 create mode 100644 docs/_static/fonts/LICENSE
 create mode 100644 docs/_static/style.css
 create mode 100644 docs/conf.py
 create mode 100644 docs/examples/gallery/3d_plots/grdview_surface.rst
 create mode 100644 docs/examples/tutorials/basics/coastlines.rst
 create mode 100644 docs/index.rst
 create mode 100644 docs/make.bat

diff --git a/README.md b/README.md
index d46f7dd..b9009aa 100644
--- a/README.md
+++ b/README.md
@@ -3,6 +3,22 @@
 This repository contains tutorials and gallery examples for the Generic Mapping
 Tools.
 
+## Building the documentation
+
+Building the documentation requires the dependencies listed in requirements.txt.
+Using conda, these can be installed with the provided environment.yml file.
+
+Run:
+
+    cd docs
+    make html
+
+## Acknowledgements
+
+The gmt-examples structure is based on [PyGMT](https://github.com/GenericMappingTools/pygmt)
+with style from [GMT](https://github.com/GenericMappingTools/gmt). Many examples
+are translated from the [PyGMT user guide](https://pygmt.org).
+
 ## License
 
 [![Creative Commons License](https://i.creativecommons.org/l/by/4.0/88x31.png)](http://creativecommons.org/licenses/by/4.0/)
diff --git a/docs/Makefile b/docs/Makefile
new file mode 100644
index 0000000..d4bb2cb
--- /dev/null
+++ b/docs/Makefile
@@ -0,0 +1,20 @@
+# Minimal makefile for Sphinx documentation
+#
+
+# You can set these variables from the command line, and also
+# from the environment for the first two.
+SPHINXOPTS    ?=
+SPHINXBUILD   ?= sphinx-build
+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)
diff --git a/docs/_static/favicon.png b/docs/_static/favicon.png
new file mode 100644
index 0000000000000000000000000000000000000000..d0de14d1e7fbc59c88760fcad77ff633a77e3b5d
GIT binary patch
diff --git a/docs/_static/fonts/Atkinson-Hyperlegible-Bold-102a.woff2 b/docs/_static/fonts/Atkinson-Hyperlegible-Bold-102a.woff2
new file mode 100644
index 0000000000000000000000000000000000000000..19a58eace2f37f645b2e724046288a979efafd84
GIT binary patch
diff --git a/docs/_static/fonts/Atkinson-Hyperlegible-BoldItalic-102a.woff2 b/docs/_static/fonts/Atkinson-Hyperlegible-BoldItalic-102a.woff2
new file mode 100644
index 0000000000000000000000000000000000000000..43f253e52c22ddc961267a7422f4f0a3fbdad3ff
GIT binary patch
diff --git a/docs/_static/fonts/Atkinson-Hyperlegible-Italic-102a.woff2 b/docs/_static/fonts/Atkinson-Hyperlegible-Italic-102a.woff2
new file mode 100644
index 0000000000000000000000000000000000000000..d35d3a78dc5df918f102b566115f22845bfcce31
GIT binary patch
diff --git a/docs/_static/fonts/Atkinson-Hyperlegible-Regular-102a.woff2 b/docs/_static/fonts/Atkinson-Hyperlegible-Regular-102a.woff2
new file mode 100644
index 0000000000000000000000000000000000000000..99b3c6f5e440bc94bb70b1727928066cadfd1bbf
GIT binary patch
diff --git a/docs/_static/fonts/LICENSE b/docs/_static/fonts/LICENSE
new file mode 100644
index 0000000..f3d445a
--- /dev/null
+++ b/docs/_static/fonts/LICENSE
@@ -0,0 +1,46 @@
+ATKINSON HYPERLEGIBLE FONT LICENSE
+Copyright © 2020, Braille Institute of America, Inc., https://www.brailleinstitute.org/freefont with Reserved Typeface
+Name Atkinson Hyperlegible Font.
+GENERAL
+Copyright Holder allows the Font to be used, studied, modified and redistributed freely as long as it is not sold by
+itself. The Font, including any derivative works, may be bundled, embedded, redistributed and/or sold with any software
+or other work provided that the Reserved Typeface Name is not used on, in or by any derivative work. The Font and
+derivatives, however, cannot be released under any other type of license. The requirement for the Font to remain under
+this license does not apply to any document created using the Font or any of its derivatives.
+DEFINITIONS
+"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font
+Software.
+“Copyright Holder” refers to Braille Institute of America, Inc.
+“Font” refers to the Atkinson Hyperlegible Font developed by Copyright Holder.
+"Font Software" refers to the set of files released by Copyright Holder under this license. This may include source
+files, build scripts and documentation.
+"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any
+of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
+"Original Version" refers to the collection of the Font Software components as distributed by Copyright Holder.
+"Reserved Typeface Name" refers to the name Atkinson Hayperlegible Font.
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy,
+merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the
+following conditions:
+1) Neither the Font Software nor any of its individual components, in Original Version or Modified Version, may be sold
+by itself.
+2) The Original Version or Modified Version of the Font Software may be bundled, redistributed and/or sold with any
+other software, provided that each copy contains the above copyright notice and this license. These can be included
+either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within
+text or binary files as long as those fields can be easily viewed by the user.
+3) No Modified Version of the Font Software may use the Reserved Typeface Name unless explicit written permission is
+granted by Copyright Holder. This restriction only applies to the primary font name as presented to the users.
+4) The name of Copyright Holder or the Author(s) of the Font Software shall not be used to promote, endorse or advertise
+any Modified Version or any related software or other product, except:
+(a) to acknowledge the contribution(s) of Copyright Holder and the Author(s); or
+(b) with the prior written permission of Copyright Holder.
+5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and
+must not be distributed under any other license.
+TERMINATION
+This license shall immediately terminate and become null and void if any of the above conditions are not met.
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
+ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK
+OR OTHER RIGHT. IN NO EVENT SHALL COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY
+GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ARISING FROM, OUT OF THE USE OF OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE.
diff --git a/docs/_static/style.css b/docs/_static/style.css
new file mode 100644
index 0000000..4a1ef4a
--- /dev/null
+++ b/docs/_static/style.css
@@ -0,0 +1,123 @@
+/* Set max width of the content */
+.wy-nav-content {
+	max-width: 1000px;
+}
+
+/* See https://github.com/GenericMappingTools/gmt/pull/1605 */
+.rst-content dl dt {
+	font-weight: normal;
+}
+
+body {
+	font-family: "Atkinson Hyperlegible", sans-serif;
+	font-size: 1.05em;
+}
+
+h1, h2, h3, h4, h5, h6 {
+	font-family: "Atkinson Hyperlegible", sans-serif;
+	font-weight: "normal"
+}
+
+/* style for example gallery */
+.gmtgallery li {
+	list-style: none!important;
+	width: 180px!important;
+	display: inline-grid!important;
+	margin-right: 15px!important;
+}
+
+/* style for gmt movies */
+.gmtmovie li {
+	list-style: none;
+	width: 45%;
+	display: inline-grid;
+	margin: 10px;
+}
+
+/* Set tab-width to 2 spaces */
+.highlight {
+	tab-size: 2;
+}
+
+/* Revert the old behavior of popups */
+.modalDialog {
+	position: fixed;
+	font-family: "Atkinson Hyperlegible", Arial, Helvetica, sans-serif;
+	top: 0;
+	right: 0;
+	bottom: 0;
+	left: 0;
+	z-index: 99999;
+	opacity:0;
+	-webkit-transition: opacity 400ms ease-in;
+	-moz-transition: opacity 400ms ease-in;
+	transition: opacity 400ms ease-in;
+	pointer-events: none;
+}
+.modalDialog:target {
+	opacity:1;
+	pointer-events: auto;
+}
+.modalDialog > div {
+	font-size:small;
+	width: 500px;
+	position: relative;
+	margin: 10% auto;
+	padding: 5px 20px 13px 20px;
+	border-radius: 10px;
+	background: #fff;
+	background: -moz-linear-gradient(#fff, #999);
+	background: -webkit-linear-gradient(#fff, #999);
+	background: -o-linear-gradient(#fff, #999);
+}
+.close {
+	background: #606061;
+	color: #FFFFFF;
+	line-height: 25px;
+	position: absolute;
+	right: -12px;
+	text-align: center;
+	top: -10px;
+	width: 24px;
+	text-decoration: none;
+	font-weight: bold;
+	-webkit-border-radius: 12px;
+	-moz-border-radius: 12px;
+	border-radius: 12px;
+	-moz-box-shadow: 1px 1px 3px #000;
+	-webkit-box-shadow: 1px 1px 3px #000;
+	box-shadow: 1px 1px 3px #000;
+}
+.close:hover { background: #00d9ff; }
+
+/* Atkinson Hyperlegible regular */
+@font-face {
+	font-family: "Atkinson Hyperlegible";
+	src: url("./fonts/Atkinson-Hyperlegible-Regular-102a.woff2") format('woff2');
+	font-weight: normal;
+	font-style: normal;
+}
+
+/* Atkinson Hyperlegible bold */
+@font-face {
+	font-family: "Atkinson Hyperlegible";
+	src: url("./fonts/Atkinson-Hyperlegible-Bold-102a.woff2") format('woff2');
+	font-weight: bold;
+	font-style: normal;
+}
+
+/* Atkinson Hyperlegible italic */
+@font-face {
+	font-family: "Atkinson Hyperlegible";
+	src: url("./fonts/Atkinson-Hyperlegible-Italic-102a.woff2") format('woff2');
+	font-weight: normal;
+	font-style: italic;
+}
+
+/* Atkinson Hyperlegible bold italic */
+@font-face {
+	font-family: "Atkinson Hyperlegible";
+	src: url("./fonts/Atkinson-Hyperlegible-BoldItalic-102a.woff2") format('woff2');
+	font-weight: bold;
+	font-style: italic;
+}
diff --git a/docs/conf.py b/docs/conf.py
new file mode 100644
index 0000000..72cbb4e
--- /dev/null
+++ b/docs/conf.py
@@ -0,0 +1,63 @@
+# Configuration file for the Sphinx documentation builder.
+#
+# This file only contains a selection of the most common options. For a full
+# list see the documentation:
+# https://www.sphinx-doc.org/en/master/usage/configuration.html
+
+# -- Path setup --------------------------------------------------------------
+
+# If extensions (or modules to document with autodoc) are in another directory,
+# add these directories to sys.path here. If the directory is relative to the
+# documentation root, use os.path.abspath to make it absolute, like shown here.
+#
+# import os
+# import sys
+# sys.path.insert(0, os.path.abspath('.'))
+
+
+# -- Project information -----------------------------------------------------
+
+project = 'GMT Examples'
+copyright = '2022, The GMT Team'
+author = 'The GMT Team'
+
+
+# -- General configuration ---------------------------------------------------
+
+# 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.extlinks",
+    "sphinx_gmt.gmtplot",
+]
+# Add any paths that contain templates here, relative to this directory.
+templates_path = ['_templates']
+
+# List of patterns, relative to source directory, that match files and
+# directories to ignore when looking for source files.
+# This pattern also affects html_static_path and html_extra_path.
+exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
+
+# MyST-NB configuration
+execution_timeout = 900
+
+# configure links to GMT docs
+extlinks = {
+    "gmt-module": ("https://docs.generic-mapping-tools.org/latest/%s", "%s"),
+}
+
+
+# -- Options for HTML output -------------------------------------------------
+
+# The theme to use for HTML and HTML Help pages.  See the documentation for
+# a list of builtin themes.
+#
+html_theme = 'sphinx_rtd_theme'
+
+# 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_favicon = "_static/favicon.png"
+html_static_path = ["_static"]
+html_css_files = ["style.css"]
\ No newline at end of file
diff --git a/docs/examples/gallery/3d_plots/grdview_surface.rst b/docs/examples/gallery/3d_plots/grdview_surface.rst
new file mode 100644
index 0000000..cbbc9ea
--- /dev/null
+++ b/docs/examples/gallery/3d_plots/grdview_surface.rst
@@ -0,0 +1,24 @@
+Plotting a surface
+------------------
+
+:gmt-module:`grdview` can plot 3-D surfaces using the :gmt-module:`-Q <grdview#q>`
+parameter with the ``s`` directive. Here, we use :gmt-module:`grdmath` to create
+a netCDF file containing a grid for plotting.
+
+Note that the **-p** parameter here controls the azimuth and elevation angle of
+the view.
+
+We use the :gmt-module:`-B <grdview#b>` parameter twice - the first specifies
+the :math:`x`- and :math:`y`-axes frame attributes and the second specifies the
+:math:`z`-axis frame attributes using the ``z`` directive.
+
+The :gmt-module:`-I <grdview#i>` parameter specifies the illumination; here we
+use an azimuth of 45° using the ``+a`` modifier.
+
+.. gmtplot::
+   :language: bash
+
+   gmt grdmath -R-15/15/-15/15 -I0.3 X Y HYPOT DUP 2 MUL PI MUL 8 DIV COS EXCH NEG 10 DIV EXP MUL 0.001 SUB = example_grid.nc
+   gmt begin grdview_surface png
+      gmt grdview example_grid.nc -Ba5f1 -Bza5f1 -JX10C -JZ2c -Qs -Croma -p135/30 -I+a45
+   gmt end show
diff --git a/docs/examples/tutorials/basics/coastlines.rst b/docs/examples/tutorials/basics/coastlines.rst
new file mode 100644
index 0000000..5885cdb
--- /dev/null
+++ b/docs/examples/tutorials/basics/coastlines.rst
@@ -0,0 +1,81 @@
+Coastlines and boarders
+-----------------------
+
+Plotting coastlines and boarders is handled by :gmt-module:`coast`.
+
+Shorelines
+~~~~~~~~~~
+
+Use the :gmt-module:`-W <coast#w>` parameter to plot only the shorelines:
+
+.. gmtplot::
+   :language: bash
+
+   gmt begin shorelines png
+      gmt coast -Rg -JW15c -B -W
+   gmt end show
+
+The shorelines are divided in 4 levels:
+
+1. coastline
+2. lakeshore
+3. island-in-lake shore
+4. lake-in-island-in-lake shore
+
+You can specify which level you want to plot by appending the level number and a
+GMT pen configuration to the :gmt-module:`-W <coast#w>` parameter. For example,
+to plot just the coastlines with 0.5 thickness and black lines:
+
+.. gmtplot::
+   :language: bash
+
+   gmt begin shorelines_levels png
+      gmt coast -Rg -JW15c -B -W1/0.5p,black
+   gmt end show
+
+You can specify multiple levels by using the :gmt-module:`-W <coast#w>`
+parameter more than once:
+
+.. gmtplot::
+   :language: bash
+
+   gmt begin shorelines_levels png
+      gmt coast -Rg -JW15c -B -W1/0.5p,black -W2/0.5,red
+   gmt end show
+
+Resolutions
+~~~~~~~~~~~
+
+The coastline database comes with 5 resolutions, which can be set using the
+:gmt-module:`-D <coast#d>` parameter. The resolution drops by 80% between levels:
+
+1. **c**: crude
+2. **l**: low
+3. **i**: intermediate
+4. **h**: high
+5. **f**: full
+
+.. gmtplot::
+   :language: bash
+
+   oahu="-158.3/-157.6/21.2/21.8"
+   gmt begin shorelines_resolutions png
+      for res in c, l, i, h, f
+      do
+          gmt coast -R${oahu} -JM5c -W1p -D${res} -X5c
+      done
+   gmt end show
+
+Land and water
+~~~~~~~~~~~~~~
+
+Use the :gmt-module:`-G <coast#g>` and :gmt-module:`-S <coast#s>` parameters to
+specify a fill color for land and water bodies. The colors can be given by name
+or hex codes:
+
+.. gmtplot::
+   :language: bash
+
+   gmt begin land_water png
+      gmt coast -Rg -JW15c -B -G#666666 -Sskyblue
+   gmt end show
diff --git a/docs/index.rst b/docs/index.rst
new file mode 100644
index 0000000..0242720
--- /dev/null
+++ b/docs/index.rst
@@ -0,0 +1,82 @@
+GMT Tutorials and Examples
+==========================
+
+A collection of tutorials and short guides demonstrating how to complete
+various tasks using GMT.
+
+.. toctree::
+   :hidden:
+   :glob:
+   :maxdepth: 2
+   :caption: Gallery
+
+   examples/gallery/*/*
+
+.. toctree::
+   :hidden:
+   :glob:
+   :maxdepth: 2
+   :caption: Tutorials
+
+   examples/tutorials/*/*
+
+.. cssclass:: gmtgallery
+
+
+Gallery
+-------
+
+Maps and map elements
+~~~~~~~~~~~~~~~~~~~~~
+
+Lines
+~~~~~
+
+Vectors
+~~~~~~~
+
+
+Symbols and markers
+~~~~~~~~~~~~~~~~~~~
+
+Images, contours, and fields
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+3d plots
+~~~~~~~~
+
+.. cssclass:: gmtgallery
+
+-  .. image:: ../gmtplot_directive/examples/gallery/3d_plots/grdview_surface-gmtplot-0.png
+      :target: examples/gallery/3d_plots/grdview_surface.html
+      :width: 80%
+      :align: center
+
+   :doc:`examples/gallery/3d_plots/grdview_surface`
+
+Seismology and geodesy
+~~~~~~~~~~~~~~~~~~~~~~
+
+Basemaps
+~~~~~~~~
+
+Histograms
+~~~~~~~~~~
+
+Plot embellishments
+~~~~~~~~~~~~~~~~~~~
+
+Tutorials
+---------
+
+Basics
+~~~~~~
+
+.. cssclass:: gmtgallery
+
+-  .. image:: ../gmtplot_directive/examples/tutorials/basics/coastlines-gmtplot-4.png
+      :target: examples/tutorials/basics/coastlines.html
+      :width: 80%
+      :align: center
+
+   :doc:`examples/tutorials/basics/coastlines`
diff --git a/docs/make.bat b/docs/make.bat
new file mode 100644
index 0000000..8084272
--- /dev/null
+++ b/docs/make.bat
@@ -0,0 +1,35 @@
+@ECHO OFF
+
+pushd %~dp0
+
+REM Command file for Sphinx documentation
+
+if "%SPHINXBUILD%" == "" (
+	set SPHINXBUILD=sphinx-build
+)
+set SOURCEDIR=.
+set BUILDDIR=_build
+
+if "%1" == "" goto help
+
+%SPHINXBUILD% >NUL 2>NUL
+if errorlevel 9009 (
+	echo.
+	echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
+	echo.installed, then set the SPHINXBUILD environment variable to point
+	echo.to the full path of the 'sphinx-build' executable. Alternatively you
+	echo.may add the Sphinx directory to PATH.
+	echo.
+	echo.If you don't have Sphinx installed, grab it from
+	echo.https://www.sphinx-doc.org/
+	exit /b 1
+)
+
+%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
+goto end
+
+:help
+%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
+
+:end
+popd

From 9c97b8526c93e43fa0c1e564e03430d794b0f5ab Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 5 Jan 2022 11:55:45 -0500
Subject: [PATCH 09/34] Remove extra whitespace

---
 vercel.json | 1 -
 1 file changed, 1 deletion(-)

diff --git a/vercel.json b/vercel.json
index 7d1e698..a18e049 100644
--- a/vercel.json
+++ b/vercel.json
@@ -3,4 +3,3 @@
       "silent": true
     }
   }
-  
\ No newline at end of file

From 93c01d453946d2a57494996750f0a7d48063d97d Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:02:23 -0500
Subject: [PATCH 10/34] Add workflow for deploying docs

---
 .github/workflows/docs.yml | 49 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 49 insertions(+)
 create mode 100644 .github/workflows/docs.yml

diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
new file mode 100644
index 0000000..142e7c3
--- /dev/null
+++ b/.github/workflows/docs.yml
@@ -0,0 +1,49 @@
+#
+# Build documentation and deploy
+#
+name: Docs
+
+on:
+  # pull_request:
+  push:
+    branches:
+      - main
+    paths:
+      - 'docs/**'
+      - '.github/workflows/**'
+
+defaults:
+  run:
+    # default to use bash shell
+    shell: bash
+
+jobs:
+  build:
+    runs-on: ubuntu-20.04
+    steps:
+      # Checks-out your repository under $GITHUB_WORKSPACE
+      - name: Checkout
+        uses: actions/checkout@v2.4.0
+
+      - name: Setup Python
+        uses: actions/setup-python@v2
+        with:
+          python-version: '3.8'
+
+      - name: Install requirements
+        run: pip install -r requirements.txt
+
+      - name: Build the website
+        run: make -C docs clean html
+
+      - name: Deploy to gh-pages
+        if: success() && github.event_name == 'push'
+        # Don't use tags: https://julienrenaux.fr/2019/12/20/github-actions-security-risk/
+        uses: peaceiris/actions-gh-pages@bbdfb200618d235585ad98e965f4aafc39b4c501
+        with:
+          github_token: ${{ secrets.GITHUB_TOKEN }}
+          publish_dir: ./docs/_build/html/
+          # Only keep the latest commit to avoid bloating the repository
+          force_orphan: true
+          user_name: 'github-actions[bot]'
+          user_email: 'github-actions[bot]@users.noreply.github.com'

From d8bfe9154f664a8859b3cc574c9c2d00c6439512 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:06:13 -0500
Subject: [PATCH 11/34] Fix requirements

---
 requirements.txt | 1 -
 1 file changed, 1 deletion(-)

diff --git a/requirements.txt b/requirements.txt
index 495bf86..d828488 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,4 +1,3 @@
-gmt
 sphinx
 sphinx_gmt
 sphinx_rtd_theme

From 1fe5d2b19b64497793a0560f74e84290ebfaaf08 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:21:05 -0500
Subject: [PATCH 12/34] Fix indentation

---
 environment.yml | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/environment.yml b/environment.yml
index 6bedf07..f117c41 100644
--- a/environment.yml
+++ b/environment.yml
@@ -3,7 +3,7 @@ channels:
     - conda-forge
     - defaults
 dependencies:
-  - gmt
-  - sphinx
-  - sphinx_gmt
-  - sphinx_rtd_theme
+    - gmt
+    - sphinx
+    - sphinx_gmt
+    - sphinx_rtd_theme

From 0fcfad9981864a9ba11489b50fa816d7ce1272b9 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:32:48 -0500
Subject: [PATCH 13/34] Add package.json for continuous documentation

---
 package.json | 8 ++++++++
 1 file changed, 8 insertions(+)
 create mode 100644 package.json

diff --git a/package.json b/package.json
new file mode 100644
index 0000000..7939fec
--- /dev/null
+++ b/package.json
@@ -0,0 +1,8 @@
+{
+    "scripts": {
+      "build:miniconda": "curl -o ~/miniconda.sh https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh && bash ~/miniconda.sh -b -p $HOME/miniconda",
+      "build:gmt": "conda install mamba -c conda-forge -y && mamba env create -f environment.yml",
+      "build:docs": "source activate gmt-examples && make -C docs/ html",
+      "build": "export PATH=$HOME/miniconda/bin:$PATH && export GMT_DATA_SERVER=https://oceania.generic-mapping-tools.org && npm run build:miniconda && npm run build:gmt && npm run build:docs"
+    }
+  }
\ No newline at end of file

From 89d1be50c3be7145346cee7234d1f2b9960e49cc Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:34:22 -0500
Subject: [PATCH 14/34] Remove requirements.txt

---
 requirements.txt | 3 ---
 1 file changed, 3 deletions(-)
 delete mode 100644 requirements.txt

diff --git a/requirements.txt b/requirements.txt
deleted file mode 100644
index d828488..0000000
--- a/requirements.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-sphinx
-sphinx_gmt
-sphinx_rtd_theme

From a4768ffb4129c8dfc7b1ad1ac61bb4f84bf3e8bf Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:48:35 -0500
Subject: [PATCH 15/34] Update build workflow to use mamba

---
 .github/workflows/docs.yml | 33 +++++++++++++++++++++++----------
 1 file changed, 23 insertions(+), 10 deletions(-)

diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
index 142e7c3..02bfdbe 100644
--- a/.github/workflows/docs.yml
+++ b/.github/workflows/docs.yml
@@ -12,26 +12,39 @@ on:
       - 'docs/**'
       - '.github/workflows/**'
 
-defaults:
-  run:
-    # default to use bash shell
-    shell: bash
-
 jobs:
   build:
     runs-on: ubuntu-20.04
+    defaults:
+      run:
+        shell: bash -l {0}
+
     steps:
       # Checks-out your repository under $GITHUB_WORKSPACE
       - name: Checkout
         uses: actions/checkout@v2.4.0
 
-      - name: Setup Python
-        uses: actions/setup-python@v2
+      # Install Mambaforge with conda-forge dependencies
+      - name: Setup Mambaforge
+        uses: conda-incubator/setup-miniconda@v2.1.1
         with:
-          python-version: '3.8'
+          activate-environment: gmt-examples
+          python-version: 3.8
+          channels: conda-forge,nodefaults
+          channel-priority: strict
+          miniforge-version: latest
+          miniforge-variant: Mambaforge
+          mamba-version: "*"
+          use-mamba: true
+
+      # Install GMT and other required dependencies from conda-forge
+      - name: Install dependencies
+        run: |
+          mamba install gmt sphinx sphinx_rtd_theme sphinx_gmt
 
-      - name: Install requirements
-        run: pip install -r requirements.txt
+      # Show installed pkg information for postmortem diagnostic
+      - name: List installed packages
+        run: mamba list
 
       - name: Build the website
         run: make -C docs clean html

From c8a6cce7407d8e4226018efdf2f103e6097e09e8 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:51:35 -0500
Subject: [PATCH 16/34] Update docs/conf.py

---
 docs/conf.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/docs/conf.py b/docs/conf.py
index 72cbb4e..1385e51 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -60,4 +60,4 @@
 # so a file named "default.css" will overwrite the builtin "default.css".
 html_favicon = "_static/favicon.png"
 html_static_path = ["_static"]
-html_css_files = ["style.css"]
\ No newline at end of file
+html_css_files = ["style.css"]

From 8b1222b2dc04c1c8ad6e45f6509eb257961ea0c6 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 11:59:56 -0500
Subject: [PATCH 17/34] Update image link

---
 docs/index.rst | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/docs/index.rst b/docs/index.rst
index 0242720..52acfc2 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -47,7 +47,7 @@ Images, contours, and fields
 
 .. cssclass:: gmtgallery
 
--  .. image:: ../gmtplot_directive/examples/gallery/3d_plots/grdview_surface-gmtplot-0.png
+-  .. image:: _images/grdview_surface-gmtplot-0.png
       :target: examples/gallery/3d_plots/grdview_surface.html
       :width: 80%
       :align: center
@@ -74,7 +74,7 @@ Basics
 
 .. cssclass:: gmtgallery
 
--  .. image:: ../gmtplot_directive/examples/tutorials/basics/coastlines-gmtplot-4.png
+-  .. image:: _images/coastlines-gmtplot-4.png
       :target: examples/tutorials/basics/coastlines.html
       :width: 80%
       :align: center

From 3bd8a64140cda04485777a8bc819b8ac45ba66a2 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 12:00:55 -0500
Subject: [PATCH 18/34] Use public dir for continuous documentation

---
 package.json | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package.json b/package.json
index 7939fec..2ea9cca 100644
--- a/package.json
+++ b/package.json
@@ -2,7 +2,7 @@
     "scripts": {
       "build:miniconda": "curl -o ~/miniconda.sh https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh && bash ~/miniconda.sh -b -p $HOME/miniconda",
       "build:gmt": "conda install mamba -c conda-forge -y && mamba env create -f environment.yml",
-      "build:docs": "source activate gmt-examples && make -C docs/ html",
+      "build:docs": "source activate gmt-examples && cd docs && make clean && make html && mv _build/html ../public",
       "build": "export PATH=$HOME/miniconda/bin:$PATH && export GMT_DATA_SERVER=https://oceania.generic-mapping-tools.org && npm run build:miniconda && npm run build:gmt && npm run build:docs"
     }
   }
\ No newline at end of file

From 4defe37013704d2570f964595acfbddcb778b4aa Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 12:09:54 -0500
Subject: [PATCH 19/34] Re-add requirements.txt

---
 requirements.txt | 3 +++
 1 file changed, 3 insertions(+)
 create mode 100644 requirements.txt

diff --git a/requirements.txt b/requirements.txt
new file mode 100644
index 0000000..f4d5302
--- /dev/null
+++ b/requirements.txt
@@ -0,0 +1,3 @@
+sphinx
+sphinx_rtd_theme
+sphinx_gmt

From 9b68b471ca2259c793811f9d68c0ac53b23ea095 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 12:15:48 -0500
Subject: [PATCH 20/34] Update vercel.json

---
 vercel.json | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/vercel.json b/vercel.json
index a18e049..7ae9a3d 100644
--- a/vercel.json
+++ b/vercel.json
@@ -1,5 +1,5 @@
 {
-    "github": {
-      "silent": true
-    }
+  "github": {
+    "silent": true
   }
+}

From b1835616a54b868856bec546baa8d0541d47e565 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 14:36:52 -0500
Subject: [PATCH 21/34] Add contributors guide and code of conduct

---
 CODE_OF_CONDUCT.md   | 133 +++++++++++++++++++++++++++++++++++++++++++
 CONTRIBUTING.md      |  30 ++++++++++
 README.md            |  12 ++--
 docs/conf.py         |   1 +
 docs/contributing.md | 121 +++++++++++++++++++++++++++++++++++++++
 docs/index.rst       |   7 +++
 environment.yml      |   1 +
 requirements.txt     |   1 +
 8 files changed, 298 insertions(+), 8 deletions(-)
 create mode 100644 CODE_OF_CONDUCT.md
 create mode 100644 CONTRIBUTING.md
 create mode 100644 docs/contributing.md

diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md
new file mode 100644
index 0000000..47d5438
--- /dev/null
+++ b/CODE_OF_CONDUCT.md
@@ -0,0 +1,133 @@
+# Contributor Code of Conduct
+
+## Our Pledge
+
+We as members, contributors, and leaders pledge to make participation in our
+community a harassment-free experience for everyone, regardless of age, body
+size, visible or invisible disability, ethnicity, sex characteristics, gender
+identity and expression, level of experience, education, socio-economic status,
+nationality, personal appearance, race, caste, color, religion, or sexual identity
+and orientation.
+
+We pledge to act and interact in ways that contribute to an open, welcoming,
+diverse, inclusive, and healthy community.
+
+## Our Standards
+
+Examples of behavior that contributes to a positive environment for our
+community include:
+
+* Demonstrating empathy and kindness toward other people
+* Being respectful of differing opinions, viewpoints, and experiences
+* Giving and gracefully accepting constructive feedback
+* Accepting responsibility and apologizing to those affected by our mistakes,
+  and learning from the experience
+* Focusing on what is best not just for us as individuals, but for the
+  overall community
+
+Examples of unacceptable behavior include:
+
+* The use of sexualized language or imagery, and sexual attention or
+  advances of any kind
+* Trolling, insulting or derogatory comments, and personal or political attacks
+* Public or private harassment
+* Publishing others' private information, such as a physical or email
+  address, without their explicit permission
+* Other conduct which could reasonably be considered inappropriate in a
+  professional setting
+
+## Enforcement Responsibilities
+
+Community leaders are responsible for clarifying and enforcing our standards of
+acceptable behavior and will take appropriate and fair corrective action in
+response to any behavior that they deem inappropriate, threatening, offensive,
+or harmful.
+
+Community leaders have the right and responsibility to remove, edit, or reject
+comments, commits, code, wiki edits, issues, and other contributions that are
+not aligned to this Code of Conduct, and will communicate reasons for moderation
+decisions when appropriate.
+
+## Scope
+
+This Code of Conduct applies within all community spaces, and also applies when
+an individual is officially representing the community in public spaces.
+Examples of representing our community include using an official e-mail address,
+posting via an official social media account, or acting as an appointed
+representative at an online or offline event.
+
+## Enforcement
+
+Instances of abusive, harassing, or otherwise unacceptable behavior may be
+reported to the community leaders responsible for enforcement at
+``pwessel at hawaii dot edu``, ``leouieda at gmail dot com``, or
+``meghanj at hawaii dot edu``. All complaints will be reviewed and investigated
+promptly and fairly.
+
+All community leaders are obligated to respect the privacy and security of the
+reporter of any incident.
+
+## Enforcement Guidelines
+
+Community leaders will follow these Community Impact Guidelines in determining
+the consequences for any action they deem in violation of this Code of Conduct:
+
+### 1. Correction
+
+**Community Impact**: Use of inappropriate language or other behavior deemed
+unprofessional or unwelcome in the community.
+
+**Consequence**: A private, written warning from community leaders, providing
+clarity around the nature of the violation and an explanation of why the
+behavior was inappropriate. A public apology may be requested.
+
+### 2. Warning
+
+**Community Impact**: A violation through a single incident or series
+of actions.
+
+**Consequence**: A warning with consequences for continued behavior. No
+interaction with the people involved, including unsolicited interaction with
+those enforcing the Code of Conduct, for a specified period of time. This
+includes avoiding interactions in community spaces as well as external channels
+like social media. Violating these terms may lead to a temporary or
+permanent ban.
+
+### 3. Temporary Ban
+
+**Community Impact**: A serious violation of community standards, including
+sustained inappropriate behavior.
+
+**Consequence**: A temporary ban from any sort of interaction or public
+communication with the community for a specified period of time. No public or
+private interaction with the people involved, including unsolicited interaction
+with those enforcing the Code of Conduct, is allowed during this period.
+Violating these terms may lead to a permanent ban.
+
+### 4. Permanent Ban
+
+**Community Impact**: Demonstrating a pattern of violation of community
+standards, including sustained inappropriate behavior,  harassment of an
+individual, or aggression toward or disparagement of classes of individuals.
+
+**Consequence**: A permanent ban from any sort of public interaction within
+the community.
+
+## Attribution
+
+This Code of Conduct is adapted from the [Contributor Covenant][homepage],
+version 2.0, available at
+[https://www.contributor-covenant.org/version/2/0/code_of_conduct.html][v2.0].
+
+Community Impact Guidelines were inspired by
+[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
+
+For answers to common questions about this code of conduct, see the FAQ at
+[https://www.contributor-covenant.org/faq][FAQ]. Translations are available
+at [https://www.contributor-covenant.org/translations][translations].
+
+[homepage]: https://www.contributor-covenant.org
+[v2.0]: https://www.contributor-covenant.org/version/2/0/code_of_conduct.html
+[Mozilla CoC]: https://github.com/mozilla/diversity
+[FAQ]: https://www.contributor-covenant.org/faq
+[translations]: https://www.contributor-covenant.org/translations
\ No newline at end of file
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
new file mode 100644
index 0000000..2f07ae0
--- /dev/null
+++ b/CONTRIBUTING.md
@@ -0,0 +1,30 @@
+# Contributing Guidelines
+
+:tada: **First off, thank you for considering contributing to our project!** :tada:
+
+This is a community-driven project, so it's people like you that make it useful and
+successful.
+These are some of the many ways to contribute:
+
+* :bug: Submitting bug reports and feature requests
+* :memo: Writing tutorials or examples
+* :mag: Fixing typos and improving the documentation
+* :people_holding_hands: Community engagement and outreach
+
+If you get stuck at any point you can create an
+[issue](https://github.com/GenericMappingTools/gmt-examples/issues) on GitHub or
+get in touch through the [GMT Forum](https://forum.generic-mapping-tools.org/).
+
+For more information on contributing to open source projects,
+[GitHub's own guide](https://opensource.guide/how-to-contribute)
+is a great starting point if you are new to version control.
+
+Detailed instructions for contributors to the GMT Examples project can be found
+in the [contributors guide](https://www.generic-mapping-tools.org/gmt-examples/contributing.html).
+
+## Ground Rules
+
+The goal is to maintain a diverse community that's pleasant for everyone.
+**Please be considerate and respectful of others**.
+Everyone must abide by our [Code of Conduct](CODE_OF_CONDUCT.md) and we encourage all to
+read it carefully.
\ No newline at end of file
diff --git a/README.md b/README.md
index b9009aa..f94ae0a 100644
--- a/README.md
+++ b/README.md
@@ -3,15 +3,11 @@
 This repository contains tutorials and gallery examples for the Generic Mapping
 Tools.
 
-## Building the documentation
+## Contributing
 
-Building the documentation requires the dependencies listed in requirements.txt.
-Using conda, these can be installed with the provided environment.yml file.
-
-Run:
-
-    cd docs
-    make html
+:tada: Thank you for considering contributing to our project! :tada: Please
+refer to the [contributors guide](https://www.generic-mapping-tools.org/gmt-examples/contributing.html)
+for more guidance.
 
 ## Acknowledgements
 
diff --git a/docs/conf.py b/docs/conf.py
index 1385e51..af9f457 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -28,6 +28,7 @@
 # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
 # ones.
 extensions = [
+    "myst_parser",
     "sphinx.ext.extlinks",
     "sphinx_gmt.gmtplot",
 ]
diff --git a/docs/contributing.md b/docs/contributing.md
new file mode 100644
index 0000000..b56ceda
--- /dev/null
+++ b/docs/contributing.md
@@ -0,0 +1,121 @@
+# Contributors Guide
+
+This is a community driven project and everyone is welcome to contribute. The
+project is hosted at the [gmt-examples GitHub repository](https://github.com/GenericMappingTools/gmt-examples).
+
+The goal is to maintain a diverse community that's pleasant for everyone.
+**Please be considerate and respectful of others**. Everyone must abide by our
+[Code of Conduct](https://github.com/GenericMappingTools/gmt-examples/blob/main/CODE_OF_CONDUCT.md)
+and we encourage all to read it carefully.
+
+## Setting up your environment
+
+We highly recommend using [Anaconda](https://www.anaconda.com/download/) and the `conda`
+package manager to install and manage your packages.
+
+
+The repository includes a conda environment file `environment.yml` with the
+specification for all development requirements to build and test the project.
+See the [`environment.yml`](https://github.com/GenericMappingTools/gmt-examples/blob/main/environment.yml)
+file for the list of dependencies and the environment name (`gmt-examples`).
+Once you have forked and cloned the repository to your local machine, you can
+use this file to create an isolated environment on which you can work.
+Run the following on the base of the repository to create a new conda
+environment from the `environment.yml` file:
+
+```bash
+conda env create
+```
+
+Before building and testing the project, you have to activate the environment
+(you'll need to do this every time you start a new terminal):
+
+```bash
+conda activate gmt-examples
+```
+
+## Building the documentation
+
+Once you have [setup your environment](#setting-up-your-environment), you can
+build the documentation using:
+
+```bash
+    cd docs
+    make html
+```
+
+## GMT Examples Overview
+
+There are two main components to GMT examples project:
+
+* Gallery examples, with source material in the `docs/examples/gallery/` folder.
+* Tutorial examples, with source material in the `docs/examples/tutorials/` folder.
+
+The gallery examples are designed to instruct users on how to complete a specific
+problem. For general recommendations on how to design effective gallery examples,
+see the [diataxis framework's section on how-to guides](https://diataxis.fr/how-to-guides/).
+
+The tutorials are learning orientated with the goal of teaching users GMT. For
+general recommendations on how to design effective tutorials, see the
+[diataxis framework's section on tutorials](https://diataxis.fr/tutorials/).
+
+The documentation are written primarily in
+[reStructuredText](https://docutils.sourceforge.io/rst.html) and built by
+[Sphinx](http://www.sphinx-doc.org/). Please refer to
+[reStructuredText Cheatsheet](https://docs.generic-mapping-tools.org/latest/devdocs/rst-cheatsheet.html)
+if you are new to reStructuredText.
+
+## Contributing New Examples
+
+The source files for the gallery examples and tutorials are `.rst` files in
+`docs/examples/` that generate one or more figures using the
+[sphinx_gmt](https://www.generic-mapping-tools.org/sphinx_gmt/latest/)
+extension. To add a new gallery example or tutorial:
+
+* If necessary, create a new sub-directory under `docs/examples/gallery/` for a
+  gallery example section (e.g., `basemaps/` or `plot_embellishments/`).
+* Create a new `.rst` file inside the appropriate sub-directory in
+  `docs/examples/gallery/` or `docs/examples/tutorials/`.
+* Add a descriptive title and as much explanation as necessary.
+* Add hyperlinks to GMT modules using the `gmt-module` restructured text directive:
+
+  ```bash
+  :gmt-module:`grdview`
+  ```
+
+* Add hyperlinks to GMT module options by appending lower-case `#<option>` to
+  the `gmt-module` argument:
+
+  ```bash
+  :gmt-module:`grdview#q`
+  ```
+
+* Add as many figures as needed using the `gmtplot` directive:
+
+  ```bash
+  .. gmtplot::
+     :language: bash
+
+     gmt begin basemap png
+        gmt basemap -B -Rg -JH5c
+     gmt end show
+
+  ```
+
+  The figures will be placed after the source code in the built documentation
+  by the `sphinx_gmt` extension.
+
+* Add the file to the appropriate section in `docs/index.rst` using the following
+  template:
+
+  ```bash
+    -  .. image:: _images/<file-name>-gmtplot-0.png
+        :target: examples/gallery/<section>/<file-name>.html
+        :width: 80%
+        :align: center
+
+     :doc:`examples/gallery/<section>/<file-name>`
+  ```
+
+  Edit the number in the `.. image:: ...` line to show a different figure on the
+  index page.
diff --git a/docs/index.rst b/docs/index.rst
index 52acfc2..41d16b9 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -20,6 +20,13 @@ various tasks using GMT.
 
    examples/tutorials/*/*
 
+.. toctree::
+   :hidden:
+   :maxdepth: 2
+   :caption: Development
+
+   contributing.md
+
 .. cssclass:: gmtgallery
 
 
diff --git a/environment.yml b/environment.yml
index f117c41..e1dc518 100644
--- a/environment.yml
+++ b/environment.yml
@@ -4,6 +4,7 @@ channels:
     - defaults
 dependencies:
     - gmt
+    - myst-parser
     - sphinx
     - sphinx_gmt
     - sphinx_rtd_theme
diff --git a/requirements.txt b/requirements.txt
index f4d5302..d6ed914 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,3 +1,4 @@
+myst-parser
 sphinx
 sphinx_rtd_theme
 sphinx_gmt

From 9709df8dbb79a922d0f79e2efe74ef025ed700e6 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 14:40:13 -0500
Subject: [PATCH 22/34] Update package.json

---
 package.json | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package.json b/package.json
index 2ea9cca..eee8c59 100644
--- a/package.json
+++ b/package.json
@@ -5,4 +5,4 @@
       "build:docs": "source activate gmt-examples && cd docs && make clean && make html && mv _build/html ../public",
       "build": "export PATH=$HOME/miniconda/bin:$PATH && export GMT_DATA_SERVER=https://oceania.generic-mapping-tools.org && npm run build:miniconda && npm run build:gmt && npm run build:docs"
     }
-  }
\ No newline at end of file
+  }

From 95399dc43d6b28cf23d01f3d56b51bf9400a3b24 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 17:14:28 -0500
Subject: [PATCH 23/34] Add pip instructions

---
 docs/contributing.md | 39 ++++++++++++++++++++++++++++++---------
 1 file changed, 30 insertions(+), 9 deletions(-)

diff --git a/docs/contributing.md b/docs/contributing.md
index b56ceda..593228a 100644
--- a/docs/contributing.md
+++ b/docs/contributing.md
@@ -10,17 +10,38 @@ and we encourage all to read it carefully.
 
 ## Setting up your environment
 
-We highly recommend using [Anaconda](https://www.anaconda.com/download/) and the `conda`
-package manager to install and manage your packages.
+The following dependencies are required for building the GMT examples pages:
 
+- [gmt](https://docs.generic-mapping-tools.org/latest/#)
+- [myst-parser](https://myst-parser.readthedocs.io/en/latest/)
+- [sphinx](https://www.sphinx-doc.org/en/master/)
+- [sphinx_gmt](https://www.generic-mapping-tools.org/sphinx_gmt/latest/)
+- [sphinx_rtd_theme](https://sphinx-rtd-theme.readthedocs.io/en/stable/installing.html)
 
-The repository includes a conda environment file `environment.yml` with the
-specification for all development requirements to build and test the project.
-See the [`environment.yml`](https://github.com/GenericMappingTools/gmt-examples/blob/main/environment.yml)
-file for the list of dependencies and the environment name (`gmt-examples`).
-Once you have forked and cloned the repository to your local machine, you can
-use this file to create an isolated environment on which you can work.
-Run the following on the base of the repository to create a new conda
+### Pip Setup
+
+These instructions rely on the [pip](https://pip.pypa.io/en/stable/) package
+installer, which can be used to install all dependencies except GMT.
+Follow the [GMT Install Guide](https://github.com/GenericMappingTools/gmt/blob/master/INSTALL.md)
+to install GMT. The Python dependencies can be installed using the
+`requirements.txt` from the base of the repository (you may wish to setup a
+[virtual environment](https://packaging.python.org/en/latest/guides/installing-using-pip-and-virtual-environments/#creating-a-virtual-environment) first):
+
+Unix/macOS:
+```
+python -m pip install -r requirements.txt # Unix/MacOS
+```
+
+Windows:
+```
+py -m pip install -r requirements.txt # Windows
+```
+
+
+### Conda Setup
+
+These instructions rely on the [conda](https://docs.conda.io/en/latest/) package
+manager. Run the following from the base of the repository to create a new conda
 environment from the `environment.yml` file:
 
 ```bash

From 139db3d72dcd8638af4e692e067992ec21fbdfa5 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 17:23:40 -0500
Subject: [PATCH 24/34] Remove extra comments

---
 docs/contributing.md | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/docs/contributing.md b/docs/contributing.md
index 593228a..8cdbe98 100644
--- a/docs/contributing.md
+++ b/docs/contributing.md
@@ -29,12 +29,12 @@ to install GMT. The Python dependencies can be installed using the
 
 Unix/macOS:
 ```
-python -m pip install -r requirements.txt # Unix/MacOS
+python -m pip install -r requirements.txt
 ```
 
 Windows:
 ```
-py -m pip install -r requirements.txt # Windows
+py -m pip install -r requirements.txt
 ```
 
 

From 4b7a085a9d45bff9b196c49076da37d63c0c338d Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Thu, 6 Jan 2022 17:25:15 -0500
Subject: [PATCH 25/34] Add links to sections

---
 docs/contributing.md | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/docs/contributing.md b/docs/contributing.md
index 8cdbe98..d53d647 100644
--- a/docs/contributing.md
+++ b/docs/contributing.md
@@ -18,6 +18,8 @@ The following dependencies are required for building the GMT examples pages:
 - [sphinx_gmt](https://www.generic-mapping-tools.org/sphinx_gmt/latest/)
 - [sphinx_rtd_theme](https://sphinx-rtd-theme.readthedocs.io/en/stable/installing.html)
 
+Two options for installing the dependencies are [pip](#pip-setup) and [conda](#conda-setup).
+
 ### Pip Setup
 
 These instructions rely on the [pip](https://pip.pypa.io/en/stable/) package
@@ -37,7 +39,6 @@ Windows:
 py -m pip install -r requirements.txt
 ```
 
-
 ### Conda Setup
 
 These instructions rely on the [conda](https://docs.conda.io/en/latest/) package

From f82e5136baff47b89a83803e2d0337f4b912f9c5 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Fri, 7 Jan 2022 10:40:06 -0500
Subject: [PATCH 26/34] Apply suggestions from code review

Co-authored-by: Dongdong Tian <seisman.info@gmail.com>
---
 docs/conf.py         | 3 ---
 docs/contributing.md | 4 ++--
 2 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/docs/conf.py b/docs/conf.py
index af9f457..57125e6 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -40,9 +40,6 @@
 # This pattern also affects html_static_path and html_extra_path.
 exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
 
-# MyST-NB configuration
-execution_timeout = 900
-
 # configure links to GMT docs
 extlinks = {
     "gmt-module": ("https://docs.generic-mapping-tools.org/latest/%s", "%s"),
diff --git a/docs/contributing.md b/docs/contributing.md
index d53d647..071ae7b 100644
--- a/docs/contributing.md
+++ b/docs/contributing.md
@@ -12,7 +12,7 @@ and we encourage all to read it carefully.
 
 The following dependencies are required for building the GMT examples pages:
 
-- [gmt](https://docs.generic-mapping-tools.org/latest/#)
+- [gmt](https://docs.generic-mapping-tools.org/latest/)
 - [myst-parser](https://myst-parser.readthedocs.io/en/latest/)
 - [sphinx](https://www.sphinx-doc.org/en/master/)
 - [sphinx_gmt](https://www.generic-mapping-tools.org/sphinx_gmt/latest/)
@@ -49,7 +49,7 @@ environment from the `environment.yml` file:
 conda env create
 ```
 
-Before building and testing the project, you have to activate the environment
+Before building the documentation, you have to activate the environment
 (you'll need to do this every time you start a new terminal):
 
 ```bash

From 65d7475eb7fbfc732412985ddbb25b9b8ee890d8 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Tue, 11 Jan 2022 11:35:29 -0500
Subject: [PATCH 27/34] Update copyright, author, and add authors guideline

---
 CONTRIBUTING.md | 7 ++++++-
 docs/conf.py    | 4 ++--
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 2f07ae0..2bc033c 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -27,4 +27,9 @@ in the [contributors guide](https://www.generic-mapping-tools.org/gmt-examples/c
 The goal is to maintain a diverse community that's pleasant for everyone.
 **Please be considerate and respectful of others**.
 Everyone must abide by our [Code of Conduct](CODE_OF_CONDUCT.md) and we encourage all to
-read it carefully.
\ No newline at end of file
+read it carefully.
+
+## The `AUTHORS.md` file
+
+Anyone who has contributed a pull request to the project is welcome to add
+themselves to the `AUTHORS.md` file.
diff --git a/docs/conf.py b/docs/conf.py
index 57125e6..c4a49e0 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -18,8 +18,8 @@
 # -- Project information -----------------------------------------------------
 
 project = 'GMT Examples'
-copyright = '2022, The GMT Team'
-author = 'The GMT Team'
+copyright = '2022, The GMT Examples Authors'
+author = 'GMT Examples Contributors'
 
 
 # -- General configuration ---------------------------------------------------

From cefc545eccb126d7da42f7554561a8f4aba30c04 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Tue, 11 Jan 2022 11:41:04 -0500
Subject: [PATCH 28/34] Move gallery and tutorials dirs under docs

---
 docs/contributing.md                               | 14 +++++++-------
 .../gallery/3d_plots/grdview_surface.rst           |  0
 docs/index.rst                                     | 12 ++++++------
 .../{examples => }/tutorials/basics/coastlines.rst |  0
 4 files changed, 13 insertions(+), 13 deletions(-)
 rename docs/{examples => }/gallery/3d_plots/grdview_surface.rst (100%)
 rename docs/{examples => }/tutorials/basics/coastlines.rst (100%)

diff --git a/docs/contributing.md b/docs/contributing.md
index 071ae7b..b790925 100644
--- a/docs/contributing.md
+++ b/docs/contributing.md
@@ -70,8 +70,8 @@ build the documentation using:
 
 There are two main components to GMT examples project:
 
-* Gallery examples, with source material in the `docs/examples/gallery/` folder.
-* Tutorial examples, with source material in the `docs/examples/tutorials/` folder.
+* Gallery examples, with source material in the `docs/gallery/` folder.
+* Tutorial examples, with source material in the `docs/tutorials/` folder.
 
 The gallery examples are designed to instruct users on how to complete a specific
 problem. For general recommendations on how to design effective gallery examples,
@@ -90,14 +90,14 @@ if you are new to reStructuredText.
 ## Contributing New Examples
 
 The source files for the gallery examples and tutorials are `.rst` files in
-`docs/examples/` that generate one or more figures using the
+`docs/` that generate one or more figures using the
 [sphinx_gmt](https://www.generic-mapping-tools.org/sphinx_gmt/latest/)
 extension. To add a new gallery example or tutorial:
 
-* If necessary, create a new sub-directory under `docs/examples/gallery/` for a
+* If necessary, create a new sub-directory under `docs/gallery/` for a
   gallery example section (e.g., `basemaps/` or `plot_embellishments/`).
 * Create a new `.rst` file inside the appropriate sub-directory in
-  `docs/examples/gallery/` or `docs/examples/tutorials/`.
+  `docs/gallery/` or `docs/tutorials/`.
 * Add a descriptive title and as much explanation as necessary.
 * Add hyperlinks to GMT modules using the `gmt-module` restructured text directive:
 
@@ -132,11 +132,11 @@ extension. To add a new gallery example or tutorial:
 
   ```bash
     -  .. image:: _images/<file-name>-gmtplot-0.png
-        :target: examples/gallery/<section>/<file-name>.html
+        :target: gallery/<section>/<file-name>.html
         :width: 80%
         :align: center
 
-     :doc:`examples/gallery/<section>/<file-name>`
+     :doc:`gallery/<section>/<file-name>`
   ```
 
   Edit the number in the `.. image:: ...` line to show a different figure on the
diff --git a/docs/examples/gallery/3d_plots/grdview_surface.rst b/docs/gallery/3d_plots/grdview_surface.rst
similarity index 100%
rename from docs/examples/gallery/3d_plots/grdview_surface.rst
rename to docs/gallery/3d_plots/grdview_surface.rst
diff --git a/docs/index.rst b/docs/index.rst
index 41d16b9..808a1ca 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -10,7 +10,7 @@ various tasks using GMT.
    :maxdepth: 2
    :caption: Gallery
 
-   examples/gallery/*/*
+   gallery/*/*
 
 .. toctree::
    :hidden:
@@ -18,7 +18,7 @@ various tasks using GMT.
    :maxdepth: 2
    :caption: Tutorials
 
-   examples/tutorials/*/*
+   tutorials/*/*
 
 .. toctree::
    :hidden:
@@ -55,11 +55,11 @@ Images, contours, and fields
 .. cssclass:: gmtgallery
 
 -  .. image:: _images/grdview_surface-gmtplot-0.png
-      :target: examples/gallery/3d_plots/grdview_surface.html
+      :target: gallery/3d_plots/grdview_surface.html
       :width: 80%
       :align: center
 
-   :doc:`examples/gallery/3d_plots/grdview_surface`
+   :doc:`gallery/3d_plots/grdview_surface`
 
 Seismology and geodesy
 ~~~~~~~~~~~~~~~~~~~~~~
@@ -82,8 +82,8 @@ Basics
 .. cssclass:: gmtgallery
 
 -  .. image:: _images/coastlines-gmtplot-4.png
-      :target: examples/tutorials/basics/coastlines.html
+      :target: tutorials/basics/coastlines.html
       :width: 80%
       :align: center
 
-   :doc:`examples/tutorials/basics/coastlines`
+   :doc:`tutorials/basics/coastlines`
diff --git a/docs/examples/tutorials/basics/coastlines.rst b/docs/tutorials/basics/coastlines.rst
similarity index 100%
rename from docs/examples/tutorials/basics/coastlines.rst
rename to docs/tutorials/basics/coastlines.rst

From facfdab660da6c12dd09900751880a04ff168380 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Tue, 11 Jan 2022 11:45:09 -0500
Subject: [PATCH 29/34] Set default highlight language

---
 docs/conf.py                              | 3 +++
 docs/contributing.md                      | 1 -
 docs/gallery/3d_plots/grdview_surface.rst | 1 -
 docs/tutorials/basics/coastlines.rst      | 5 -----
 4 files changed, 3 insertions(+), 7 deletions(-)

diff --git a/docs/conf.py b/docs/conf.py
index c4a49e0..9549f65 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -59,3 +59,6 @@
 html_favicon = "_static/favicon.png"
 html_static_path = ["_static"]
 html_css_files = ["style.css"]
+
+# Adjust highlight language for sphinx_gmt examples
+highlight_language = "bash"
diff --git a/docs/contributing.md b/docs/contributing.md
index b790925..28d0abf 100644
--- a/docs/contributing.md
+++ b/docs/contributing.md
@@ -116,7 +116,6 @@ extension. To add a new gallery example or tutorial:
 
   ```bash
   .. gmtplot::
-     :language: bash
 
      gmt begin basemap png
         gmt basemap -B -Rg -JH5c
diff --git a/docs/gallery/3d_plots/grdview_surface.rst b/docs/gallery/3d_plots/grdview_surface.rst
index cbbc9ea..2cbb99f 100644
--- a/docs/gallery/3d_plots/grdview_surface.rst
+++ b/docs/gallery/3d_plots/grdview_surface.rst
@@ -16,7 +16,6 @@ The :gmt-module:`-I <grdview#i>` parameter specifies the illumination; here we
 use an azimuth of 45° using the ``+a`` modifier.
 
 .. gmtplot::
-   :language: bash
 
    gmt grdmath -R-15/15/-15/15 -I0.3 X Y HYPOT DUP 2 MUL PI MUL 8 DIV COS EXCH NEG 10 DIV EXP MUL 0.001 SUB = example_grid.nc
    gmt begin grdview_surface png
diff --git a/docs/tutorials/basics/coastlines.rst b/docs/tutorials/basics/coastlines.rst
index 5885cdb..7608dd4 100644
--- a/docs/tutorials/basics/coastlines.rst
+++ b/docs/tutorials/basics/coastlines.rst
@@ -9,7 +9,6 @@ Shorelines
 Use the :gmt-module:`-W <coast#w>` parameter to plot only the shorelines:
 
 .. gmtplot::
-   :language: bash
 
    gmt begin shorelines png
       gmt coast -Rg -JW15c -B -W
@@ -27,7 +26,6 @@ GMT pen configuration to the :gmt-module:`-W <coast#w>` parameter. For example,
 to plot just the coastlines with 0.5 thickness and black lines:
 
 .. gmtplot::
-   :language: bash
 
    gmt begin shorelines_levels png
       gmt coast -Rg -JW15c -B -W1/0.5p,black
@@ -37,7 +35,6 @@ You can specify multiple levels by using the :gmt-module:`-W <coast#w>`
 parameter more than once:
 
 .. gmtplot::
-   :language: bash
 
    gmt begin shorelines_levels png
       gmt coast -Rg -JW15c -B -W1/0.5p,black -W2/0.5,red
@@ -56,7 +53,6 @@ The coastline database comes with 5 resolutions, which can be set using the
 5. **f**: full
 
 .. gmtplot::
-   :language: bash
 
    oahu="-158.3/-157.6/21.2/21.8"
    gmt begin shorelines_resolutions png
@@ -74,7 +70,6 @@ specify a fill color for land and water bodies. The colors can be given by name
 or hex codes:
 
 .. gmtplot::
-   :language: bash
 
    gmt begin land_water png
       gmt coast -Rg -JW15c -B -G#666666 -Sskyblue

From 86afebb2c6a4294bfe06bab036f8d56b4495614e Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Tue, 11 Jan 2022 12:08:28 -0500
Subject: [PATCH 30/34] Remove myst-parser dependency

---
 docs/conf.py          |   2 +-
 docs/contributing.md  | 142 ------------------------------------------
 docs/contributing.rst | 139 +++++++++++++++++++++++++++++++++++++++++
 docs/index.rst        |   2 +-
 environment.yml       |   1 -
 requirements.txt      |   1 -
 6 files changed, 141 insertions(+), 146 deletions(-)
 delete mode 100644 docs/contributing.md
 create mode 100644 docs/contributing.rst

diff --git a/docs/conf.py b/docs/conf.py
index 9549f65..4bb9236 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -28,7 +28,7 @@
 # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
 # ones.
 extensions = [
-    "myst_parser",
+    "sphinx.ext.autosectionlabel",
     "sphinx.ext.extlinks",
     "sphinx_gmt.gmtplot",
 ]
diff --git a/docs/contributing.md b/docs/contributing.md
deleted file mode 100644
index 28d0abf..0000000
--- a/docs/contributing.md
+++ /dev/null
@@ -1,142 +0,0 @@
-# Contributors Guide
-
-This is a community driven project and everyone is welcome to contribute. The
-project is hosted at the [gmt-examples GitHub repository](https://github.com/GenericMappingTools/gmt-examples).
-
-The goal is to maintain a diverse community that's pleasant for everyone.
-**Please be considerate and respectful of others**. Everyone must abide by our
-[Code of Conduct](https://github.com/GenericMappingTools/gmt-examples/blob/main/CODE_OF_CONDUCT.md)
-and we encourage all to read it carefully.
-
-## Setting up your environment
-
-The following dependencies are required for building the GMT examples pages:
-
-- [gmt](https://docs.generic-mapping-tools.org/latest/)
-- [myst-parser](https://myst-parser.readthedocs.io/en/latest/)
-- [sphinx](https://www.sphinx-doc.org/en/master/)
-- [sphinx_gmt](https://www.generic-mapping-tools.org/sphinx_gmt/latest/)
-- [sphinx_rtd_theme](https://sphinx-rtd-theme.readthedocs.io/en/stable/installing.html)
-
-Two options for installing the dependencies are [pip](#pip-setup) and [conda](#conda-setup).
-
-### Pip Setup
-
-These instructions rely on the [pip](https://pip.pypa.io/en/stable/) package
-installer, which can be used to install all dependencies except GMT.
-Follow the [GMT Install Guide](https://github.com/GenericMappingTools/gmt/blob/master/INSTALL.md)
-to install GMT. The Python dependencies can be installed using the
-`requirements.txt` from the base of the repository (you may wish to setup a
-[virtual environment](https://packaging.python.org/en/latest/guides/installing-using-pip-and-virtual-environments/#creating-a-virtual-environment) first):
-
-Unix/macOS:
-```
-python -m pip install -r requirements.txt
-```
-
-Windows:
-```
-py -m pip install -r requirements.txt
-```
-
-### Conda Setup
-
-These instructions rely on the [conda](https://docs.conda.io/en/latest/) package
-manager. Run the following from the base of the repository to create a new conda
-environment from the `environment.yml` file:
-
-```bash
-conda env create
-```
-
-Before building the documentation, you have to activate the environment
-(you'll need to do this every time you start a new terminal):
-
-```bash
-conda activate gmt-examples
-```
-
-## Building the documentation
-
-Once you have [setup your environment](#setting-up-your-environment), you can
-build the documentation using:
-
-```bash
-    cd docs
-    make html
-```
-
-## GMT Examples Overview
-
-There are two main components to GMT examples project:
-
-* Gallery examples, with source material in the `docs/gallery/` folder.
-* Tutorial examples, with source material in the `docs/tutorials/` folder.
-
-The gallery examples are designed to instruct users on how to complete a specific
-problem. For general recommendations on how to design effective gallery examples,
-see the [diataxis framework's section on how-to guides](https://diataxis.fr/how-to-guides/).
-
-The tutorials are learning orientated with the goal of teaching users GMT. For
-general recommendations on how to design effective tutorials, see the
-[diataxis framework's section on tutorials](https://diataxis.fr/tutorials/).
-
-The documentation are written primarily in
-[reStructuredText](https://docutils.sourceforge.io/rst.html) and built by
-[Sphinx](http://www.sphinx-doc.org/). Please refer to
-[reStructuredText Cheatsheet](https://docs.generic-mapping-tools.org/latest/devdocs/rst-cheatsheet.html)
-if you are new to reStructuredText.
-
-## Contributing New Examples
-
-The source files for the gallery examples and tutorials are `.rst` files in
-`docs/` that generate one or more figures using the
-[sphinx_gmt](https://www.generic-mapping-tools.org/sphinx_gmt/latest/)
-extension. To add a new gallery example or tutorial:
-
-* If necessary, create a new sub-directory under `docs/gallery/` for a
-  gallery example section (e.g., `basemaps/` or `plot_embellishments/`).
-* Create a new `.rst` file inside the appropriate sub-directory in
-  `docs/gallery/` or `docs/tutorials/`.
-* Add a descriptive title and as much explanation as necessary.
-* Add hyperlinks to GMT modules using the `gmt-module` restructured text directive:
-
-  ```bash
-  :gmt-module:`grdview`
-  ```
-
-* Add hyperlinks to GMT module options by appending lower-case `#<option>` to
-  the `gmt-module` argument:
-
-  ```bash
-  :gmt-module:`grdview#q`
-  ```
-
-* Add as many figures as needed using the `gmtplot` directive:
-
-  ```bash
-  .. gmtplot::
-
-     gmt begin basemap png
-        gmt basemap -B -Rg -JH5c
-     gmt end show
-
-  ```
-
-  The figures will be placed after the source code in the built documentation
-  by the `sphinx_gmt` extension.
-
-* Add the file to the appropriate section in `docs/index.rst` using the following
-  template:
-
-  ```bash
-    -  .. image:: _images/<file-name>-gmtplot-0.png
-        :target: gallery/<section>/<file-name>.html
-        :width: 80%
-        :align: center
-
-     :doc:`gallery/<section>/<file-name>`
-  ```
-
-  Edit the number in the `.. image:: ...` line to show a different figure on the
-  index page.
diff --git a/docs/contributing.rst b/docs/contributing.rst
new file mode 100644
index 0000000..8fdb8aa
--- /dev/null
+++ b/docs/contributing.rst
@@ -0,0 +1,139 @@
+Contributors Guide
+------------------
+
+This is a community driven project and everyone is welcome to contribute. The
+project is hosted at the `gmt-examples GitHub repository <https://github.com/GenericMappingTools/gmt-examples>`_.
+
+The goal is to maintain a diverse community that's pleasant for everyone.
+**Please be considerate and respectful of others**. Everyone must abide by our
+`Code of Conduct <https://github.com/GenericMappingTools/gmt-examples/blob/main/CODE_OF_CONDUCT.md>`_
+and we encourage all to read it carefully.
+
+Setting up your environment
+~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+The following dependencies are required for building the GMT examples pages:
+
+- `gmt <https://docs.generic-mapping-tools.org/latest/>`_
+- `sphinx <http://www.sphinx-doc.org/>`_
+- `sphinx_gmt <https://www.generic-mapping-tools.org/sphinx_gmt/latest/)>`_
+- `sphinx_rtd_theme <https://sphinx-rtd-theme.readthedocs.io/en/stable/installing.html)>`_
+
+Two options for installing the dependencies are :ref:`pip <Pip Setup>` and :ref:`conda <Conda Setup>`.
+
+Pip Setup
+^^^^^^^^^
+
+These instructions rely on the `pip <https://pip.pypa.io/en/stable/>`_ package
+installer, which can be used to install all dependencies except GMT.
+Follow the `GMT Install Guide <https://github.com/GenericMappingTools/gmt/blob/master/INSTALL.md>`_
+to install GMT. The Python dependencies can be installed using the
+``requirements.txt`` from the base of the repository (you may wish to setup a
+`virtual environment <https://packaging.python.org/en/latest/guides/installing-using-pip-and-virtual-environments/#creating-a-virtual-environment>`_ first):
+
+Unix/macOS::
+
+  python -m pip install -r requirements.txt
+
+
+Windows::
+
+  py -m pip install -r requirements.txt
+
+Conda Setup
+^^^^^^^^^^^
+
+These instructions rely on the `conda <https://docs.conda.io/en/latest/>`_ package
+manager. Run the following from the base of the repository to create a new conda
+environment from the ``environment.yml`` file::
+
+  conda env create
+
+
+Before building the documentation, you have to activate the environment
+(you'll need to do this every time you start a new terminal)::
+
+  conda activate gmt-examples
+
+Building the documentation
+~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Once you have :ref:`setup your environment <Setting up your environment>`, you can
+build the documentation using::
+
+  cd docs
+  make html
+
+GMT Examples Overview
+~~~~~~~~~~~~~~~~~~~~~
+
+There are two main components to GMT examples project:
+
+* Gallery examples, with source material in the ``docs/gallery/`` folder.
+* Tutorial examples, with source material in the ``docs/tutorials/`` folder.
+
+The gallery examples are designed to instruct users on how to complete a specific
+problem. For general recommendations on how to design effective gallery examples,
+see the `diataxis framework's section on how-to guides <https://diataxis.fr/how-to-guides/>`_.
+
+The tutorials are learning orientated with the goal of teaching users GMT. For
+general recommendations on how to design effective tutorials, see the
+`diataxis framework's section on tutorials <https://diataxis.fr/tutorials/>`_.
+
+The documentation are written primarily in
+`reStructuredText <https://docutils.sourceforge.io/rst.html>`_ and built by
+`Sphinx <http://www.sphinx-doc.org/>`_. Please refer to
+`reStructuredText Cheatsheet <https://docs.generic-mapping-tools.org/latest/devdocs/rst-cheatsheet.html>`_
+if you are new to reStructuredText.
+
+Contributing New Examples
+~~~~~~~~~~~~~~~~~~~~~~~~~
+
+The source files for the gallery examples and tutorials are ``.rst`` files in
+``docs/`` that generate one or more figures using the
+`sphinx_gmt <https://www.generic-mapping-tools.org/sphinx_gmt/latest/)>`_
+extension. To add a new gallery example or tutorial:
+
+* If necessary, create a new sub-directory under ``docs/gallery/`` for a
+  gallery example section (e.g., ``basemaps/`` or ``plot_embellishments/``).
+* Create a new ``.rst`` file inside the appropriate sub-directory in
+  ``docs/gallery/`` or ``docs/tutorials/``.
+* Add a descriptive title and as much explanation as necessary.
+* Add hyperlinks to GMT modules using the ``gmt-module`` restructured text directive::
+
+  :gmt-module:`grdview`
+
+* Add hyperlinks to GMT module options by appending lower-case ``#<option>`` to
+  the ``gmt-module`` argument::
+
+  :gmt-module:`grdview#q`
+
+* Add as many figures as needed using the ``gmtplot`` directive:
+
+  ::
+
+    .. gmtplot::
+
+      gmt begin basemap png
+        gmt basemap -B -Rg -JH5c
+      gmt end show
+
+  The figures will be placed after the source code in the built documentation
+  by the ``sphinx_gmt`` extension.
+
+* Add the file to the appropriate section in ``docs/index.rst`` using the following
+  template:
+
+  ::
+
+    ```bash
+      -  .. image:: _images/<file-name>-gmtplot-0.png
+          :target: gallery/<section>/<file-name>.html
+          :width: 80%
+          :align: center
+
+       :doc:`gallery/<section>/<file-name>`
+    ```
+
+  Edit the number in the ``.. image:: ...`` line to show a different figure on the
+  index page.
diff --git a/docs/index.rst b/docs/index.rst
index 808a1ca..197b6f8 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -25,7 +25,7 @@ various tasks using GMT.
    :maxdepth: 2
    :caption: Development
 
-   contributing.md
+   contributing.rst
 
 .. cssclass:: gmtgallery
 
diff --git a/environment.yml b/environment.yml
index e1dc518..f117c41 100644
--- a/environment.yml
+++ b/environment.yml
@@ -4,7 +4,6 @@ channels:
     - defaults
 dependencies:
     - gmt
-    - myst-parser
     - sphinx
     - sphinx_gmt
     - sphinx_rtd_theme
diff --git a/requirements.txt b/requirements.txt
index d6ed914..f4d5302 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,4 +1,3 @@
-myst-parser
 sphinx
 sphinx_rtd_theme
 sphinx_gmt

From c4c9259c8b495171c543c92d511b37809bb79fc3 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Tue, 11 Jan 2022 12:21:44 -0500
Subject: [PATCH 31/34] Move up examples overview section

---
 docs/contributing.rst | 44 +++++++++++++++++++++----------------------
 1 file changed, 22 insertions(+), 22 deletions(-)

diff --git a/docs/contributing.rst b/docs/contributing.rst
index 8fdb8aa..db329fb 100644
--- a/docs/contributing.rst
+++ b/docs/contributing.rst
@@ -9,6 +9,28 @@ The goal is to maintain a diverse community that's pleasant for everyone.
 `Code of Conduct <https://github.com/GenericMappingTools/gmt-examples/blob/main/CODE_OF_CONDUCT.md>`_
 and we encourage all to read it carefully.
 
+GMT Examples Overview
+~~~~~~~~~~~~~~~~~~~~~
+
+There are two main components to GMT examples project:
+
+* Gallery examples, with source material in the ``docs/gallery/`` folder.
+* Tutorial examples, with source material in the ``docs/tutorials/`` folder.
+
+The gallery examples are designed to instruct users on how to complete a specific
+problem. For general recommendations on how to design effective gallery examples,
+see the `diataxis framework's section on how-to guides <https://diataxis.fr/how-to-guides/>`_.
+
+The tutorials are learning orientated with the goal of teaching users GMT. For
+general recommendations on how to design effective tutorials, see the
+`diataxis framework's section on tutorials <https://diataxis.fr/tutorials/>`_.
+
+The documentation are written primarily in
+`reStructuredText <https://docutils.sourceforge.io/rst.html>`_ and built by
+`Sphinx <http://www.sphinx-doc.org/>`_. Please refer to
+`reStructuredText Cheatsheet <https://docs.generic-mapping-tools.org/latest/devdocs/rst-cheatsheet.html>`_
+if you are new to reStructuredText.
+
 Setting up your environment
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
@@ -64,28 +86,6 @@ build the documentation using::
   cd docs
   make html
 
-GMT Examples Overview
-~~~~~~~~~~~~~~~~~~~~~
-
-There are two main components to GMT examples project:
-
-* Gallery examples, with source material in the ``docs/gallery/`` folder.
-* Tutorial examples, with source material in the ``docs/tutorials/`` folder.
-
-The gallery examples are designed to instruct users on how to complete a specific
-problem. For general recommendations on how to design effective gallery examples,
-see the `diataxis framework's section on how-to guides <https://diataxis.fr/how-to-guides/>`_.
-
-The tutorials are learning orientated with the goal of teaching users GMT. For
-general recommendations on how to design effective tutorials, see the
-`diataxis framework's section on tutorials <https://diataxis.fr/tutorials/>`_.
-
-The documentation are written primarily in
-`reStructuredText <https://docutils.sourceforge.io/rst.html>`_ and built by
-`Sphinx <http://www.sphinx-doc.org/>`_. Please refer to
-`reStructuredText Cheatsheet <https://docs.generic-mapping-tools.org/latest/devdocs/rst-cheatsheet.html>`_
-if you are new to reStructuredText.
-
 Contributing New Examples
 ~~~~~~~~~~~~~~~~~~~~~~~~~
 

From b46c47851103bab21ef281eaf58be1b4cf254e33 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Tue, 11 Jan 2022 12:29:31 -0500
Subject: [PATCH 32/34] Add description of dependencies

---
 docs/contributing.rst | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/docs/contributing.rst b/docs/contributing.rst
index db329fb..ef16210 100644
--- a/docs/contributing.rst
+++ b/docs/contributing.rst
@@ -36,10 +36,10 @@ Setting up your environment
 
 The following dependencies are required for building the GMT examples pages:
 
-- `gmt <https://docs.generic-mapping-tools.org/latest/>`_
-- `sphinx <http://www.sphinx-doc.org/>`_
-- `sphinx_gmt <https://www.generic-mapping-tools.org/sphinx_gmt/latest/)>`_
-- `sphinx_rtd_theme <https://sphinx-rtd-theme.readthedocs.io/en/stable/installing.html)>`_
+- `gmt <https://docs.generic-mapping-tools.org/latest/>`_ (GMT is required for executing example scripts)
+- `sphinx <http://www.sphinx-doc.org/>`_ (a Python documentation generator for creating the docs from source files)
+- `sphinx_gmt <https://www.generic-mapping-tools.org/sphinx_gmt/latest/)>`_ (a Sphinx extension for creating GMT figures to accompany example scripts)
+- `sphinx_rtd_theme <https://sphinx-rtd-theme.readthedocs.io/en/stable/)>`_ (a Sphinx theme used for consistent documentation appearance between GMT projects)
 
 Two options for installing the dependencies are :ref:`pip <Pip Setup>` and :ref:`conda <Conda Setup>`.
 

From 30fe3883b155b1fe861f68a2fd87c6a851025c39 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Tue, 11 Jan 2022 12:54:14 -0500
Subject: [PATCH 33/34] Add note about Python environment

---
 docs/contributing.rst | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/docs/contributing.rst b/docs/contributing.rst
index ef16210..5962b13 100644
--- a/docs/contributing.rst
+++ b/docs/contributing.rst
@@ -42,6 +42,10 @@ The following dependencies are required for building the GMT examples pages:
 - `sphinx_rtd_theme <https://sphinx-rtd-theme.readthedocs.io/en/stable/)>`_ (a Sphinx theme used for consistent documentation appearance between GMT projects)
 
 Two options for installing the dependencies are :ref:`pip <Pip Setup>` and :ref:`conda <Conda Setup>`.
+Since Sphinx is a Python documentation generator, you will need a working Python
+environment. For those who do not already have a working Python environment,
+one option is to use the minimal installer for Conda `Miniforge <https://github.com/conda-forge/miniforge>`_
+along with the :ref:`conda <Conda Setup>` instructions.
 
 Pip Setup
 ^^^^^^^^^

From 6a581e812520ffb284e70b8246b21d0b75a09446 Mon Sep 17 00:00:00 2001
From: Meghan Jones <meghanj@alum.mit.edu>
Date: Wed, 12 Jan 2022 10:49:15 -0500
Subject: [PATCH 34/34] Apply suggestions from code review

Co-authored-by: Dongdong Tian <seisman.info@gmail.com>
---
 .github/workflows/docs.yml |  6 +----
 docs/_static/style.css     | 51 --------------------------------------
 docs/contributing.rst      | 18 ++++++--------
 requirements.txt           |  2 +-
 4 files changed, 10 insertions(+), 67 deletions(-)

diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
index 02bfdbe..26e7a42 100644
--- a/.github/workflows/docs.yml
+++ b/.github/workflows/docs.yml
@@ -29,6 +29,7 @@ jobs:
         uses: conda-incubator/setup-miniconda@v2.1.1
         with:
           activate-environment: gmt-examples
+          environment-file: environment.yml
           python-version: 3.8
           channels: conda-forge,nodefaults
           channel-priority: strict
@@ -37,11 +38,6 @@ jobs:
           mamba-version: "*"
           use-mamba: true
 
-      # Install GMT and other required dependencies from conda-forge
-      - name: Install dependencies
-        run: |
-          mamba install gmt sphinx sphinx_rtd_theme sphinx_gmt
-
       # Show installed pkg information for postmortem diagnostic
       - name: List installed packages
         run: mamba list
diff --git a/docs/_static/style.css b/docs/_static/style.css
index 4a1ef4a..c4a640b 100644
--- a/docs/_static/style.css
+++ b/docs/_static/style.css
@@ -39,57 +39,6 @@ h1, h2, h3, h4, h5, h6 {
 	tab-size: 2;
 }
 
-/* Revert the old behavior of popups */
-.modalDialog {
-	position: fixed;
-	font-family: "Atkinson Hyperlegible", Arial, Helvetica, sans-serif;
-	top: 0;
-	right: 0;
-	bottom: 0;
-	left: 0;
-	z-index: 99999;
-	opacity:0;
-	-webkit-transition: opacity 400ms ease-in;
-	-moz-transition: opacity 400ms ease-in;
-	transition: opacity 400ms ease-in;
-	pointer-events: none;
-}
-.modalDialog:target {
-	opacity:1;
-	pointer-events: auto;
-}
-.modalDialog > div {
-	font-size:small;
-	width: 500px;
-	position: relative;
-	margin: 10% auto;
-	padding: 5px 20px 13px 20px;
-	border-radius: 10px;
-	background: #fff;
-	background: -moz-linear-gradient(#fff, #999);
-	background: -webkit-linear-gradient(#fff, #999);
-	background: -o-linear-gradient(#fff, #999);
-}
-.close {
-	background: #606061;
-	color: #FFFFFF;
-	line-height: 25px;
-	position: absolute;
-	right: -12px;
-	text-align: center;
-	top: -10px;
-	width: 24px;
-	text-decoration: none;
-	font-weight: bold;
-	-webkit-border-radius: 12px;
-	-moz-border-radius: 12px;
-	border-radius: 12px;
-	-moz-box-shadow: 1px 1px 3px #000;
-	-webkit-box-shadow: 1px 1px 3px #000;
-	box-shadow: 1px 1px 3px #000;
-}
-.close:hover { background: #00d9ff; }
-
 /* Atkinson Hyperlegible regular */
 @font-face {
 	font-family: "Atkinson Hyperlegible";
diff --git a/docs/contributing.rst b/docs/contributing.rst
index 5962b13..d0d3947 100644
--- a/docs/contributing.rst
+++ b/docs/contributing.rst
@@ -61,7 +61,6 @@ Unix/macOS::
 
   python -m pip install -r requirements.txt
 
-
 Windows::
 
   py -m pip install -r requirements.txt
@@ -75,7 +74,6 @@ environment from the ``environment.yml`` file::
 
   conda env create
 
-
 Before building the documentation, you have to activate the environment
 (you'll need to do this every time you start a new terminal)::
 
@@ -103,7 +101,7 @@ extension. To add a new gallery example or tutorial:
 * Create a new ``.rst`` file inside the appropriate sub-directory in
   ``docs/gallery/`` or ``docs/tutorials/``.
 * Add a descriptive title and as much explanation as necessary.
-* Add hyperlinks to GMT modules using the ``gmt-module`` restructured text directive::
+* Add hyperlinks to GMT modules using the ``gmt-module`` reStructuredText directive::
 
   :gmt-module:`grdview`
 
@@ -118,9 +116,9 @@ extension. To add a new gallery example or tutorial:
 
     .. gmtplot::
 
-      gmt begin basemap png
-        gmt basemap -B -Rg -JH5c
-      gmt end show
+       gmt begin basemap png
+         gmt basemap -B -Rg -JH5c
+       gmt end show
 
   The figures will be placed after the source code in the built documentation
   by the ``sphinx_gmt`` extension.
@@ -132,11 +130,11 @@ extension. To add a new gallery example or tutorial:
 
     ```bash
       -  .. image:: _images/<file-name>-gmtplot-0.png
-          :target: gallery/<section>/<file-name>.html
-          :width: 80%
-          :align: center
+            :target: gallery/<section>/<file-name>.html
+            :width: 80%
+            :align: center
 
-       :doc:`gallery/<section>/<file-name>`
+         :doc:`gallery/<section>/<file-name>`
     ```
 
   Edit the number in the ``.. image:: ...`` line to show a different figure on the
diff --git a/requirements.txt b/requirements.txt
index f4d5302..d828488 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,3 +1,3 @@
 sphinx
-sphinx_rtd_theme
 sphinx_gmt
+sphinx_rtd_theme
