Generate enums from source code

Open
#1,663 2 comments 0 reactions 1 assignee View on GitHub

@provokateurin is already working on this.

Since Feb 28, 2024.

Assessment

This issue has not been assessed yet.

Description

feature package: nextcloud

Our helpers currently contain a few enums that are not included in the OpenAPI specs. They are a one to one mapping to the enums defined in the PHP source code, so we should be able to generate them automatically in order to ensure they are always up-to-date:
https://github.com/nextcloud/server/blob/master/lib/public/Share/IShare.php
https://github.com/nextcloud/news/blob/master/lib/Db/ListType.php
https://github.com/nextcloud/spreed/blob/main/lib/Room.php
https://github.com/nextcloud/spreed/blob/main/lib/Chat/ChatManager.php
https://github.com/nextcloud/spreed/blob/main/lib/Model/Attendee.php
https://github.com/nextcloud/spreed/blob/main/lib/Participant.php
This will also make it much easier in the future to add new enums if needed.

Dominant language
Dart
Stars
178
Forks
41
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from nextcloud/neon

All issues in nextcloud/neon

Similar issues

More Dart issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.