Skip to content

Commit

Permalink
Switch to myst-parser and reconfigure markdown in sphinx docs
Browse files Browse the repository at this point in the history
  • Loading branch information
rlskoeser committed Jul 20, 2024
1 parent 867ce93 commit 09d46b9
Show file tree
Hide file tree
Showing 16 changed files with 40 additions and 21 deletions.
5 changes: 3 additions & 2 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -72,5 +72,6 @@
"repoType": "github",
"repoHost": "https://github.com",
"projectName": "undate-python",
"projectOwner": "dh-tech"
}
"projectOwner": "dh-tech",
"badgeTemplate": "![All Contributors](https://img.shields.io/github/all-contributors/dh-tech/undate-python?color=ee8449&style=flat-square)"
}
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ If you report a bug, please include any error messages you get and a full descri
## Submitting Use Cases and Example Data
We are particularly interested in collecting more use cases and example data where undate would be helpful!

Example data can be added to the [examples/](https://github.com/dh-tech/undate-python/tree/develop/examples/) folder by a pull request.
Example data can be added to the [examples/](https://github.com/dh-tech/undate-python/tree/main/examples/) folder by a pull request.

## Getting Help
The best and recommended way to get help is to join the [DHTech Slack](https://dh-tech.github.io/join/) and ask for help there. Only in cases when this is not feasible at all, you can open a new issue and tag it with "Help Request".
Expand Down
8 changes: 6 additions & 2 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
# Contributors
# All Contributors

We use [All Contributors](https://allcontributors.org/) because we recognize that all kinds of contributions are valuable and important.

<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
[![All Contributors](https://img.shields.io/badge/all_contributors-5-orange.svg?style=flat-square)](#contributors-)
![All Contributors](https://img.shields.io/github/all-contributors/dh-tech/undate-python?color=ee8449&style=flat-square)
<!-- ALL-CONTRIBUTORS-BADGE:END -->

## Contributors

<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
<!-- prettier-ignore-start -->
<!-- markdownlint-disable -->
Expand Down
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ It was initially created as part of a [DH-Tech](https://dh-tech.github.io/) hack
[![codecov](https://codecov.io/gh/dh-tech/undate-python/branch/main/graph/badge.svg?token=GE7HZE8C9D)](https://codecov.io/gh/dh-tech/undate-python)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
[![All Contributors](https://img.shields.io/badge/all_contributors-5-orange.svg?style=flat-square)](#contributors-)
[![All Contributors](https://img.shields.io/badge/all_contributors-5-orange.svg?style=flat-square)](CONTRIBUTORS.md)
<!-- ALL-CONTRIBUTORS-BADGE:END -->

Read [Contributors](CONTRIBUTORS.md) for detailed contribution information.
Expand All @@ -28,7 +28,8 @@ Read [Contributors](CONTRIBUTORS.md) for detailed contribution information.

Often humanities and cultural data include imprecise or uncertain temporal information. We want to store that information but also work with it in a structured way, not just treat it as text for display. Different projects may need to work with or convert between different date formats or even different calendars.

An `undate.Undate` is analogous to python's builtin `datetime.date` object, but with support for varying degrees of precision and unknown information. You can initialize an undate with either strings or numbers for whichever parts of the date are known or partially known. An `Undate` can take an optional label.
An `undate.Undate` is analogous to python’s builtin `datetime.date` object, but with support for varying degrees of precision and unknown information. You can initialize an undate with either strings or numbers for whichever parts of the date are known or partially known. An `Undate` can take an optional label.

```python
from undate.undate import Undate

Expand Down Expand Up @@ -155,7 +156,7 @@ You can initialize `Undate` or `UndateInterval` objects by parsing a date string

## Documentation

Project documentation is available on ReadTheDocs https://undate-python.readthedocs.io/en/latest/
Project documentation is [available on ReadTheDocs](https://undate-python.readthedocs.io/en/latest/).

For instructions on setting up for local development, see [Developer Notes](DEVELOPER_NOTES.md).

Expand Down
2 changes: 2 additions & 0 deletions docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
```{include} ../CONTRIBUTING.md
```
3 changes: 0 additions & 3 deletions docs/CONTRIBUTING.rst

This file was deleted.

2 changes: 2 additions & 0 deletions docs/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
```{include} ../CONTRIBUTORS.md
```
3 changes: 0 additions & 3 deletions docs/CONTRIBUTORS.rst

This file was deleted.

2 changes: 2 additions & 0 deletions docs/DEVELOPER_NOTES.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
```{include} ../DEVELOPER_NOTES.md
```
1 change: 0 additions & 1 deletion docs/DEVELOPER_NOTES.rst

This file was deleted.

4 changes: 4 additions & 0 deletions docs/LICENSE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# License

```{include} ../LICENSE.md
```
3 changes: 0 additions & 3 deletions docs/LICENSE.rst

This file was deleted.

7 changes: 7 additions & 0 deletions docs/_static/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@

div.sphinxsidebar .powered_by a {
text-decoration: none;
border-bottom: none;
text-align: center;
}

7 changes: 5 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
extensions = [
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
"m2r2",
"myst_parser",
]

# Add any paths that contain templates here, relative to this directory.
Expand All @@ -46,7 +46,10 @@
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]

source_suffix = [".rst", ".md"]
source_suffix = {
".rst": "restructuredtext",
".md": "markdown",
}

# -- Options for HTML output -------------------------------------------------

Expand Down
4 changes: 4 additions & 0 deletions docs/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
```{include} ../README.md
:relative-docs: /
:relative-images:
```
1 change: 0 additions & 1 deletion docs/readme.rst

This file was deleted.

0 comments on commit 09d46b9

Please sign in to comment.