There is an issue with the docstring formatting (see comments below),
but otherwise, LGTM.
-Patrick
On 2020-04-16 at 15:47:26 +0100, Ross Burton wrote:
Add a new 'log' command that is similar to 'diff' but
shows the log of
commits from HEAD to origin/master, thus listing all commits that have
not yet been pushed.
For example:
$ make log
packages/glib-networking
glib-networking: enable installed tests
packages/gnome-desktop
gnome-desktop: Autospec creation for update from version 3.34.3 to version 3.36.0
packages/gnome-terminal
gnome-terminal: Autospec creation for update from version 3.34.2 to version 3.36.0.1
Signed-off-by: Ross Burton <ross.burton(a)intel.com>
---
Makefile.toplevel | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/Makefile.toplevel b/Makefile.toplevel
index be6c085..4e54858 100644
--- a/Makefile.toplevel
+++ b/Makefile.toplevel
@@ -166,6 +166,15 @@ diff: $(PACKAGES_FILE) $(addprefix packages/,$(PKGS_LOCAL))
(cd $$p ; git status | grep -q 'nothing to commit, working [^ ]* clean' ||
(echo "Uncommitted changes in: $$p"; git diff |diffstat -p1)) ;\
done
+#help log: Run git log HEAD...origin/master for all package repos, thus
This line is formatted correctly.
+#help log: displaying any committed but unpushed changes.
... but this line should begin with "#help" instead of "#help log:",
otherwise the docstring generation will happen for two different "log"
commands :-)
You can run `make help` at toplevel to verify the correctness of the
docstring formatting.
> +log: $(PACKAGES_FILE) $(addprefix packages/,$(PKGS_LOCAL))
> + @for p in projects/common $(addprefix packages/,$(PKGS_LOCAL)); do \
> + ( cd $$p; if [ "$$(git rev-parse --verify HEAD)" != "$$(git
rev-parse --verify origin/master)" ] ; then \
> + echo $$p ; git --no-pager log --pretty="format:%s" origin/master..HEAD ;
echo ; echo;\
> + fi ; ) \
> + done
> +
> #help versions: Displays the version of each package in the ./packages tree.
> versions: $(PACKAGES_FILE) $(addprefix packages/,$(PKGS_LOCAL))
> @for p in $(addprefix packages/,$(PKGS_LOCAL)); do \
> --
> 2.26.0
> _______________________________________________
> Dev mailing list -- dev(a)lists.clearlinux.org
> To unsubscribe send an email to dev-leave(a)lists.clearlinux.org