Citoid/Updating Zotero

If you are not yet a registered user of gerrit, see Developer account.


Updating Zotero translators

edit
  1. Check out our translator fork at https://gitlab.wikimedia.org/repos/mediawiki/services/zotero-translators
  2. (First time only)
    1. git remote add upstream https://github.com/zotero/translators.git
    2. git fetch upstream
    3. git checkout -b upstream upstream/master
  3. Point your repository to the gitlab main git checkout main
  4. Create a new branch for your changes git checkout -b work/user/update
  5. Squash the merges from the github branch to our 'update' one: git merge --squash upstream
  6. Commit the squashed changes: git commit
  7. Push upstream if you have developer access: git push origin work/user/update. Alternatively push to your fork (see: mw:GitLab/Workflows/Making_a_merge_request)

Our translator fork is largely the same except that we have deleted the WorldCat translator, so it's important this stays deleted in the squashed merge.


Once the translators have been updated, you will need to also update translation-server to point to the correct version by updating the submodule.

Updating Zotero (translation-server)

edit
  1. Clone the gerrit repository using authenticated checkout git clone ssh://<user>@gerrit.wikimedia.org:29418/mediawiki/services/zotero
  2. Create a local branch of the github repository as well called github from https://github.com/zotero/translation-server
    1. git add remote github https://github.com/zotero/translation-server.git
    2. git fetch github
    3. git checkout -b github github/master</branch>
  3. Point your repository to the gerrit master git checkout master
  4. Create a new branch for your changes git checkout -b update
  5. Squash the merges from the github branch to our 'update' one: git merge --squash github
  6. Resolve conflicts; there are some dockerfiles in the github repo that need to be removed as they conflict with our production environment. Otherwise, new changes can be merged in, as long as they pass automated tests and integration testing with citoid. git rm -f Dockerfile .dockerignore docker-entrypoint.sh
  7. Change directories to modules/translators, check out our translator fork at https://gitlab.wikimedia.org/repos/mediawiki/services/zotero-translators
  8. Change directories back to your zotero directory and git add modules/translators/ so it points to the correct submodule.
  9. Commit the squashed changes: git commit
  10. Send the changes to gerrit for review: git review