Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Gitea #355

Open
Tracked by #1841
6543 opened this issue Oct 12, 2020 · 6 comments
Open
Tracked by #1841

Support Gitea #355

6543 opened this issue Oct 12, 2020 · 6 comments

Comments

@6543
Copy link

6543 commented Oct 12, 2020

pleace correct me if you know a better description ...

currently docsy has integration for github (create issue, edit/create page, ...)
example:
Screenshot at 2020-10-12 21-42-16

the same feature for gitea would be nice

gitea issue: go-gitea/gitea#12303

@ShalokShalom
Copy link

Gitea is written in Go, by the way ;)
https://gitea.io

@LisaFC
Copy link
Collaborator

LisaFC commented Oct 13, 2020

Anyone fancy taking this on? You'd need to update the config flags and then do a Gitea version (or update though it might get too Conditional Spaghetti) of this partial:
https://github.com/google/docsy/blob/master/layouts/partials/page-meta-links.html

@smainz
Copy link

smainz commented Apr 23, 2024

There is already a PR #1310 to add Azure repos and I do have a working example for gitea.
To open question is, which direction to go for when adding more repo types.

Anyone got an Opinion?

@ShalokShalom
Copy link

Do you mean an universal API, or what exactly do you have in mind, categorically speaking?

@smainz
Copy link

smainz commented Apr 23, 2024

In #1310 the repo links are already seperated into different files per repo type, but each repo type has its own parameters github_XXX or azure_XXX.

If you changed that to: e.g.

repo_type=azure
repo=<some_repo_url>
...

you can have this in page-meta-links.html

  {{ partial (printf "repo-links-%s.html" $repo_type) }}

This should give an idea how this could be done. Of course there needs to be some defaulting magic to not break existing configs for github.

This will allow

  1. to bundle some repo types like github, azure, gitea and
  2. provide a means for everyone to add a custom repo_type not already supported.

In contrast to what is done in #1310 you can have only one repo type, but extensible, whereas in the PR you can define github_XXX and azure_XXX parameters.

To be discussed: Should different repo_type for docs and project be supported?

@smainz
Copy link

smainz commented Apr 24, 2024

@ShalokShalom #1941 should give an impression of what I want to do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants