pulli 0.2.6__tar.gz → 0.2.7__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: pulli
3
- Version: 0.2.6
3
+ Version: 0.2.7
4
4
  Summary: Walk a directory tree, show git repos with status, and fast-forward the ones that are behind upstream.
5
5
  Author: Stefan Waldherr
6
6
  License-Expression: MIT
@@ -1,2 +1,2 @@
1
1
  """pulli — discover git repos under a root and report their status."""
2
- __version__ = "0.2.6"
2
+ __version__ = "0.2.7"
@@ -332,7 +332,13 @@ def _build_flat_lines(
332
332
  if len(cols) >= 4:
333
333
  cols[0] = cols[0] + " " * (url_width - _visible_width(cols[0]))
334
334
  text = " ".join(c for c in cols if c)
335
- lines.append(padded + " " + text)
335
+ line = padded + " " + text
336
+ # A repo that is behind is the actionable one — `pulli pull` acts on
337
+ # it — so the whole line is highlighted (cyan) instead of just the
338
+ # count. Everything up to date stays quiet: no news takes no color.
339
+ if n.behind and not n.error:
340
+ line = C(line, _CYAN)
341
+ lines.append(line)
336
342
  repo_line[id(n)] = len(lines) - 1
337
343
  repo_base[id(n)] = padded
338
344
  return lines, repo_line, repo_base
@@ -456,6 +462,10 @@ class LiveTree:
456
462
  if self._flat and len(cols) >= 4:
457
463
  cols[0] = cols[0] + " " * (self._url_width - _visible_width(cols[0]))
458
464
  text = self.repo_base[nid] + " " + " ".join(c for c in cols if c)
465
+ # Same highlight rule as _build_flat_lines: the whole line goes
466
+ # cyan when the repo is behind — that is the actionable state.
467
+ if self._flat and node.behind and not node.error:
468
+ text = self._C(text, _CYAN)
459
469
  text = _clip_ansi(text, self._width)
460
470
  with self._lock:
461
471
  self._rewrite(i, text)
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes