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

The great refactor #82

Merged
merged 17 commits into from
Jan 30, 2021
Merged

The great refactor #82

merged 17 commits into from
Jan 30, 2021

Conversation

lowlighter
Copy link
Owner

@lowlighter lowlighter commented Jan 29, 2021

💣 This PR heavily refactor metrics code with a lot of meta-programming to simplify integration of new features:

  • Plugins will now:
    • have their own README.md and documentation
    • have a metadata.yml file descriptor
      • containing possible inputs, along with types and default values
      • which simplifies all inputs checks (inputs from both web and action will be compliant with these metadata)
    • have their own GraphQL queries folder
      • which are still magically autoloaded like before
    • have base and core content, which were reclassified as "special" plugins
      • all misceallenous inputs (config_*, committer_*, debug, etc.) are now inputs of core plugin
  • Templates will now:
    • have their own README.md and documentation
  • Metrics README.md will now:
    • be autogenerated
      • by automatically extracting demo images from plugins and templates README.md
      • by automatically building compatibility matrix from present partials in each templates
      • by automatically indexing all templates
      • by automatically indexing all plugins
    • be splitted into smaller parts for easier maintaining
    • be more coherent in text style and more up-to-date
    • CONTRIBUTING.md has been rewritten to reflect this refactor
      • Also update issues and pull requests templates
  • Metrics action.yml will now:
    • be autogenerated
      • by automatically extracting inputs from plugins metadata.yml files
  • Metrics settings.example.json will now:
    • be autogenerated
      • by automatically extracting inputs from plugins metadata.yml files
  • Web instance will now:
    • have plugins options extracted and autogenerated from metadata.yml plugins files
    • have app.placeholder.js being tested in workflow
  • Mocks will now:
    • be splitted into smaller parts for easier maintaining
    • have mocked GitHub GraphQL API autoloaded
    • have mocked external REST APIs autoloaded
  • Metadata system will now:
    • handle inputs of GitHub action
    • handle inputs of web instance
  • Workflow will now:
    • automatically rebuild global metrics, plugins and templates README.md
    • automatically rebuild settings.example.json
    • automatically rebuild action.yml
    • automatically push the resulting files after run
  • Relaunch lowlighter/lowlighter to check everything is fine

@lowlighter lowlighter marked this pull request as ready for review January 30, 2021 11:30
@lowlighter lowlighter merged commit 682e43e into master Jan 30, 2021
@lowlighter lowlighter deleted the feat-refactor branch January 30, 2021 11:31
JayantGoel001 referenced this pull request in JayantGoel001/metrics Jan 30, 2021
@lowlighter lowlighter mentioned this pull request Feb 4, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Mar 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant