Skip to content

Commit

Permalink
docs: write the readme
Browse files Browse the repository at this point in the history
  • Loading branch information
12rambau committed Oct 29, 2024
1 parent a0d5fba commit 1da42fd
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 537 deletions.
32 changes: 31 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,33 @@
# gee-sphinx-inventory

The code used to generate the sphinx inventory of the GEE objects
The code used to generate the sphinx inventory of the GEE objects.

## Usage

This repository is generating and storing the Sphinx inventory of the GEE objects.
The inventory is generated by the `generate_inventory.py` script.
The script is using the `ee` module to get the list of the objects and their methods.
The inventory is stored in the `inventory/earthengine-api.inv` file.
The `inventory.json` file is used by the `sphinx` to generate the documentation.

To link Earth Engine object in your sphinx documentation, add the following to your `conf.py` file:

```python
intersphinx_mapping = {
'ee': (
"https://developers.google.com/earth-engine/apidocs",
"https://raw.githubusercontent.com/gee-community/sphinx-inventory/refs/heads/main/inventory/earthengine-api.inv"
),
}
```

Then you can use the `:py:class:'ee.Image'` role to link the Earth Engine object in your Sphinx files.
It will appear as [`ee.Image`](https://developers.google.com/earth-engine/apidocs/ee-image) in the built documentation.

```rst
> [!NOTE]
> - To know more about `earthengine-api` read their documentation [here](https://developers.google.com/earth-engine)
> - To know more about `sphinx` read their documentation [here](https://www.sphinx-doc.org/en/master/)
> - To know more about `sphinx.ext.intersphinx` usage read their documentation [here](https://www.sphinx-doc.org/en/master/usage/extensions/intersphinx.html)
```
Loading

0 comments on commit 1da42fd

Please sign in to comment.