advice: remove usage of `advice_*` global variables
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest4 patches 0 repliesNew
- v14 patches 9 repliesSuperseded
Changes in v2 from the cover letter
- improve commit messages to mention the history of the current state
- split the API updates between readers and writers of advice_* into separate commits
- reorder commits to better show the progression of the replacement
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | advice: add enum variants for missing advice variablesadvice.c advice.h | +4 | 0 replies | |
| 2/4 | advice: remove read uses of global `advice_` variablesadvice.c branch.c builtin/ +19 more | +52 | 0 replies | |
| 3/4 | advice: add `advice_set` to update advice settings at runtimeadvice.c advice.h builtin/ +1 more | +12 | 0 replies | |
| 4/4 | advice: remove static global variables for advice trackingadvice.c advice.h | +0 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH v2 0/4] advice: remove usage of `advice_*` global variables
Hi,
When looking at global variable usage for my branch.default* settings, I found the advice_ variables which were simple enough to resolve.
This concludes the journey started in c4a09cc9ccb (Merge branch 'hw/advise-ng', 2020-03-25) to update the advice configuration API to help avoid bad coding patterns in usage of the advice_ global variables.
New advice_* variables also in flight will conflict with this patchset, but the conflict resolution is trivial (if not at all automatic).
Thanks,
--Ben
---
v1 -> v2:
- improve commit messages to mention the history of the current state
- split the API updates between readers and writers of advice_* into separate commits
- reorder commits to better show the progression of the replacement
Ben Boeckel (4):
advice: add enum variants for missing advice variables
advice: remove read uses of global advice_ variables
advice: add advice_set to update advice settings at runtime
advice: remove static global variables for advice tracking
advice.c | 88 ++++--------------------------------- advice.h | 38 +++------------- branch.c | 2 +- builtin/add.c | 8 ++-- builtin/am.c | 2 +- builtin/checkout.c | 6 +-- builtin/clone.c | 2 +- builtin/commit.c | 4 +- builtin/fetch.c | 2 +- builtin/merge.c | 4 +- builtin/push.c | 12 ++--- builtin/replace.c | 2 +- builtin/reset.c | 2 +- builtin/rm.c | 2 +- builtin/submodule--helper.c | 2 +- commit.c | 2 +- editor.c | 2 +- notes-merge.c | 2 +- object-name.c | 2 +- remote.c | 12 ++--- run-command.c | 2 +- sequencer.c | 8 ++-- unpack-trees.c | 18 ++++---- wt-status.c | 6 +-- 24 files changed, 68 insertions(+), 162 deletions(-)
base-commit: eb27b338a3e71c7c4079fbac8aeae3f8fbb5c687
Signature · 1 line
2.31.1