Jump to content

Meza/Short procedure on how to submit a PR to Meza

From mediawiki.org

For Meza itself

[edit]

Consider the CONTRIBUTING.md guidelines and submitting a PR to the freephile fork[1]

  1. At github.com
    1. Log in to your an account at Github.com
    2. Visit the Meza project page at: https://github.com/nasa/meza
    3. Create a "Fork" of the official Meza project on your github account
  2. On your wiki server
    1. cd /opt/meza/
    2. git remote set-url origin https://github.com/<yourgitusername>/meza
    3. Edit the files you think are wrong or need improved
    4. git push -A "a few words about what your changes are"
  3. Back at https://github.com/<yourgitusername>/meza
    1. Verify that the changes you made a reflected in your fork of the meza project
    2. (optional) - Make a pull request (PR) in github using github gui tools to invite primary extension owner to "pull" your changes into their master repo.

For an extension hosted on github

[edit]

Extensions like SemanticMediaWiki extensions who's primary repository is hosted on GitHub, you can fork and submit patches through GitHub.

For most MediaWiki extensions, GitHub is only a mirror repository to the primary repository hosted in Wikimedia Gerrit or GitLab. PRs or patches to those repositories should follow the Wikimedia guidelines for How to contribute and best practices for extensions.

  1. On your wiki server
    1. vi either /opt/meza/config/core/MezaExtensions.yml or /opt/conf-meza/public/MezaLocalExtennsions.yml and identify the repo source and version of the extension you wish to develop
  2. At https://github.com
    1. Log in to your an account at Github.com
    2. Visit the extension project page at: https://github.com/<extension owner>/<extension name>
    3. Create a "Fork" of the official extension project on your github account
  3. On your wiki server
    1. cd to /opt/htdocs/mediawiki/extension/<extension name>
    2. git remote set-url origin https://github.com/<yourgitusername>/<extension name>
    3. Edit the files you think are wrong or need improved
    4. git push -A "a few words about what your changes are"
  4. Visit https://github.com/<yourgitusername>/<extension name>
    1. Verify that the changes you made a reflected in your fork of the extension
    2. (optional) - Make a pull request (PR) in github using github gui tools to invite primary extension owner to "pull" your changes into their master repo.

tgr's notes

[edit]

You might set it something other than origin, but that's more of a personal workflow choice. e.g.:

  • git remote set-url fork ...;
  • git branch my-fix;
  • git commit;
  • git push fork;
  • git checkout master

...would be more of a feature branch type workflow

  1. The CONTRIBUTING.md file contents should shortly be merged into the primary nasa/meza repository so the link can be updated then. In any case, it is still acceptable to request a PR through the freephile/meza fork.