| commit | 08bc142c829aed843b1145b27fab5bb1d973cb51 | [log] [tgz] |
|---|---|---|
| author | Saša Živkov <sasa.zivkov@sap.com> | Mon Nov 04 13:55:59 2024 +0100 |
| committer | Saša Živkov <sasa.zivkov@sap.com> | Mon Nov 04 16:28:09 2024 +0100 |
| tree | 83c6fbb2c5dcb1c94188b2589694fea47ad93d0d | |
| parent | bd49c1bf4212a166d1246774cb8c70d54ead31ba [diff] |
Use ChangeIndex.deleteAllForProject to delete efficiently from index Instead of deleting changes on-by-one, use the deleteAllForProject which deletes all changes of a project in one Lucene method call. In addition, improve names of some methods to reflect their purpose better. Change-Id: I1bf173e5feadd4bc1183b77a2e3edd3141b91e13
A plugin which allows projects to be deleted from Gerrit via an SSH command, REST API or the Project settings screen.
For running unit tests execute:
bazel test --test_output=all //plugins/delete-project/web:karma_test
For checking or fixing eslint formatter problems run:
bazel test //plugins/delete-project/web:lint_test bazel run //plugins/delete-project/web:lint_bin -- --fix "$(pwd)/plugins/delete-project/web"
For testing the plugin with Gerrit FE Dev Helper build the JavaScript bundle and copy it to the plugins/ folder:
bazel build //plugins/delete-project/web:gr-delete-repo cp -f bazel-bin/plugins/delete-project/web/gr-delete-repo.js plugins/
and let the Dev Helper redirect from .+/plugins/delete-project/static/gr-delete-repo.js to http://localhost:8081/plugins_/gr-delete-repo.js.