Skip to content

How to automate copying of GMT documentation to PyGMT #895

@weiji14

Description

@weiji14

The time we spend on writing and reviewing documentation for PyGMT is getting insane. Specifically, I'm talking about the docstrings in modules (not the tutorials/gallery examples). These are some of the formatting fixes we apply:

  1. Turn short aliases to long aliases (Turn all short aliases into long form #474)
  2. Check that italics/bold/code-block formatting is applied correctly (How to reproduce original GMT arguments in PyGMT documentation #631)
  3. Wrap to 79 characters (Wrap docstrings to 79 chars and check with flake8 #384)

And there are perhaps more 'standards' to be applied soon (#884, #886, etc).

There should be an automated or semi-automated script to just copy things from the canonical GMT function docstring, apply the above formatting standards, and paste it to the PyGMT function. Say when we want to:

  1. wrap a new module
  2. keep up to date with a new GMT release

This would likely require some coordination with upstream GMT. I think there are smart people who might have some ideas around this.

Are you willing to help implement and maintain this feature? Yes, but need teamwork

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedHelping hands are appreciatedquestionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions