• Jamie Madill's avatar
    git-cl: Add diff lines of context setting. · 812ac228
    Jamie Madill authored
    Clients using some Clang-Format options can run into bugs when using
    0 lines of context. AlignConsecutiveAssignments in particular is picky
    and behaves differently with 0 lines of context.
    
    This behaviour lead to 'git cl format' behaving differently from
    'git cl format --full'. That could also break presubmit format checks.
    Using >0 lines of context for 'git diff' fixes the inconsistency.
    
    Add a setting 'DIFF_LINES_OF_CONTEXT' that can be controlled via
    codereview.settings. Defaults to zero to preserve the old behaviour.
    The setting allows the client to control the number of lines of context
    to use when running 'git cl format'.
    
    Bug: angleproject:4003
    Change-Id: Ied2ebf23df4c41ba19bfbd5b8ddf526b56a20b31
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/1864309Reviewed-by: 's avatarEdward Lesmes <ehmaldonado@chromium.org>
    Commit-Queue: Jamie Madill <jmadill@chromium.org>
    812ac228
Name
Last commit
Last update
..
gstools Loading commit data...
OWNERS Loading commit data...
auth_test.py Loading commit data...
bot_update_coverage_test.py Loading commit data...
cipd_bootstrap_test.py Loading commit data...
download_from_google_storage_unittest.py Loading commit data...
fix_encoding_test.py Loading commit data...
gclient_eval_unittest.py Loading commit data...
gclient_scm_test.py Loading commit data...
gclient_smoketest.py Loading commit data...
gclient_test.py Loading commit data...
gclient_utils_test.py Loading commit data...
git_cache_test.py Loading commit data...
git_cl_creds_check_report.txt Loading commit data...
git_cl_test.py Loading commit data...
git_common_test.py Loading commit data...
git_dates_test.py Loading commit data...
git_drover_test.py Loading commit data...
git_footers_test.py Loading commit data...
git_hyper_blame_test.py Loading commit data...
git_number_test.py Loading commit data...
git_rebase_update_test.py Loading commit data...
gsutil_test.py Loading commit data...
metrics_test.py Loading commit data...
ninjalog_uploader_test.py Loading commit data...
owners_finder_test.py Loading commit data...
owners_unittest.py Loading commit data...
presubmit_unittest.py Loading commit data...
recipes_test.py Loading commit data...
roll_dep_test.py Loading commit data...
scm_unittest.py Loading commit data...
subprocess2_test.py Loading commit data...
upload_to_google_storage_unittest.py Loading commit data...
watchlists_unittest.py Loading commit data...