Skip to content

Commit

Permalink
Add a gallery for simple examples
Browse files Browse the repository at this point in the history
  • Loading branch information
seisman committed Jun 20, 2021
1 parent f83f92e commit 29639bd
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 2 deletions.
5 changes: 5 additions & 0 deletions doc/rst/source/examples/ex001/ex001.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env bash

gmt begin basemap png
gmt basemap -R0/10/0/10 -JM10c -Baf
gmt end show
9 changes: 9 additions & 0 deletions doc/rst/source/examples/ex001/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
Demo example
============

This is a demo for the gallery of simple examples.

.. literalinclude:: ex001.sh

.. image:: https://user-images.githubusercontent.com/3974108/122659135-7cfe0100-d142-11eb-9a3f-e1ecf5b3d35c.png
:width: 80%
19 changes: 19 additions & 0 deletions doc/rst/source/examples/index.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Examples
========

In this page we show numerous simple GMT examples.

.. cssclass:: gmtgallery

- .. figure:: https://user-images.githubusercontent.com/3974108/122659135-7cfe0100-d142-11eb-9a3f-e1ecf5b3d35c.png
:target: ./ex001/index.html
:width: 80%
:align: center

:doc:`ex001/index`

.. toctree::
:hidden:
:glob:

ex*/index
4 changes: 2 additions & 2 deletions doc/rst/source/gallery.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
.. _example_gallery:

Example Gallery
===============
Gallery
=======

In this section we will be giving numerous examples of typical usage of
GMT programs. In general, we will start with a raw data set,
Expand Down
1 change: 1 addition & 0 deletions doc/rst/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ Quick links
:caption: Getting started

gallery
examples/index
animations
tutorial

Expand Down

0 comments on commit 29639bd

Please sign in to comment.