Skip to content

Conversation

@Cadair
Copy link
Member

@Cadair Cadair commented Jan 14, 2026

See my Cycle 5 FR for more details on the whole project.

This PR will add a new sphinx theme to this repo, which customises the defaults of the sunpy-sphinx-theme and adds a nominal v3 config to use it, although with any luck all it will contain is html_theme = "astropy".

def setup(app: Sphinx):
# Register theme
theme_dir = Path(__file__).parent.resolve()
app.add_html_theme("astropy", theme_dir)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we be a bit more specific on the theme name? Otherwise, if we want to switch again in the future, it might get confusing.

html_theme = 'bootstrap-astropy'

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got any suggestions? Calling it sunpy-astropy sounds terrible 😜

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should have moved it to OpenAstronomy! :p

Is astropy-v3-theme also confusing? Naming is hard.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

calling it openastronomy makes the most sense; even if the package itself if not being moved.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Calling what openastronomy?

Copy link
Member

@astrofrog astrofrog Jan 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The best thing to do might be to move the astropy theme to it's own package as then we can version it properly. Then if we want to rewrite it in a decade we can have v2.0.0 of the theme package?

FWIW we did have a theme package before the current one: https://github.com/astropy/astropy-sphinx-theme

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, before I go much further here I would like to get a 👍 from you all for the following plan:

I propose to move this micro-theme from this PR into astropy-sphinx-theme, under the name "astropy", and then release v2 of that package (optionally deprecating the old theme). This would mean that package would provide two themes, i.e. if you install it you can set html_theme = "astropy" or html_theme = "bootstrap-astropy". If we want to make major changes to the "astropy" theme, we can control that with major versions of that package, or make a "astropy-v2" in the future if needed.

As a prerequisite to that, I will have to do some cleanup of the now very crufty astropy-sphinx-theme repo, and I'll add a doc build to preview the themes etc.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't it be cleaner as a new theme package? I still think just "astropy" is too vague as theme name.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Making a whole new repo with a new theme which is ~100 lines of code and config seems extreme when we already have a repo named "astropy-sphinx-theme"?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you have my 👍

@pllim
Copy link
Member

pllim commented Jan 14, 2026

Do you plan to have a proof-of-concept PR over at astropy using this one?

@pllim pllim added enhancement New feature or request Build wheels labels Jan 14, 2026
@Cadair
Copy link
Member Author

Cadair commented Jan 14, 2026

Do you plan to have a proof-of-concept PR over at astropy using this one?

Yeah though I'll probably use a repo which takes less than a week to build the docs to start off with.

@Cadair
Copy link
Member Author

Cadair commented Jan 21, 2026

This is now replaced by astropy/astropy-sphinx-theme#48 and #94

@Cadair Cadair closed this Jan 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Build wheels enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants