commit ffa932de018c0a7c7513da4139e0b2e283d94d975b68ee22d0d167015721ccc5 from: Stefan Sperling date: Thu Feb 20 21:32:31 2025 UTC change gotwebd diff algorithm from myers-diff to patience-diff This matches the default of our command line diff and tog diff. If anyone really prefers myers we could add an option gotwebd.conf. commit - 8d099c2c4071f754faebc53661d8a6ee63ad91c3fe4a39a6dc9af0131bf48e5d commit + ffa932de018c0a7c7513da4139e0b2e283d94d975b68ee22d0d167015721ccc5 blob - 29cc02bee8243bfc3ac400489b20c4a70bd8f397dff0d444efa3a2299d81c144 blob + 8df1bbf2fbda2c7494f2a6e81440258ae9a1cc6d8eff001f87d19a2a77358a16 --- gotwebd/got_operations.c +++ gotwebd/got_operations.c @@ -1108,7 +1108,7 @@ got_output_file_blame(struct request *c, got_render_bl goto done; error = got_blame(in_repo_path, commit_id, repo, - GOT_DIFF_ALGORITHM_MYERS, got_gotweb_blame_cb, &bca, NULL, NULL, + GOT_DIFF_ALGORITHM_PATIENCE, got_gotweb_blame_cb, &bca, NULL, NULL, fd1, fd2, f1, f2); done: @@ -1213,18 +1213,18 @@ got_open_diff_for_output(FILE **fp, struct request *c) switch (obj_type) { case GOT_OBJ_TYPE_BLOB: error = got_diff_objects_as_blobs(NULL, NULL, f1, f2, fd1, fd2, - id1, id2, NULL, NULL, GOT_DIFF_ALGORITHM_MYERS, 3, 0, 0, - NULL, repo, f3); + id1, id2, NULL, NULL, GOT_DIFF_ALGORITHM_PATIENCE, + 3, 0, 0, NULL, repo, f3); break; case GOT_OBJ_TYPE_TREE: error = got_diff_objects_as_trees(NULL, NULL, f1, f2, fd1, fd2, - id1, id2, NULL, "", "", GOT_DIFF_ALGORITHM_MYERS, 3, 0, 0, - NULL, repo, f3); + id1, id2, NULL, "", "", GOT_DIFF_ALGORITHM_PATIENCE, + 3, 0, 0, NULL, repo, f3); break; case GOT_OBJ_TYPE_COMMIT: error = got_diff_objects_as_commits(NULL, NULL, f1, f2, fd1, - fd2, id1, id2, NULL, GOT_DIFF_ALGORITHM_MYERS, 3, 0, 0, - NULL, repo, f3); + fd2, id1, id2, NULL, GOT_DIFF_ALGORITHM_PATIENCE, + 3, 0, 0, NULL, repo, f3); break; default: error = got_error(GOT_ERR_OBJ_TYPE);