From: Peter Schaefer Date: Wed, 2 Jan 2019 23:28:59 +0000 (+0100) Subject: [py] new git order X-Git-Tag: v1.0^2~7 X-Git-Url: https://git.leopard-lacewing.eu/?a=commitdiff_plain;h=d2bf8774055e147904cfad030b0143d271680c69;p=tex_tools.git [py] new git order --- diff --git a/git-log-to-tikz.py b/git-log-to-tikz.py index ce948ff..0973b97 100755 --- a/git-log-to-tikz.py +++ b/git-log-to-tikz.py @@ -95,7 +95,7 @@ class Repo: print("\\tikzstyle{every path}=[draw]") print("\\tikzstyle{branch}=[draw,rectangle,rounded corners=3,fill=white,inner sep=2pt,minimum size=5pt]") ypos = 0 - ystep = -.5 + ystep = .5 for commit in self._commits.values(): commit.export_to_tikz(ypos) ypos = ypos + ystep @@ -119,7 +119,7 @@ cmd = "git log --branches --graph --oneline --parents" return_output = check_output(cmd, shell=True) #print(return_output.split("\n")) -for line in return_output.split("\n"): +for line in reversed(return_output.split("\n")): if not line == "": r.add_commit(Commit(line)) diff --git a/git1.tex b/git1.tex index bc4b4d7..e20b23a 100644 --- a/git1.tex +++ b/git1.tex @@ -2,58 +2,65 @@ \tikzstyle{commit}=[draw,circle,fill=white,inner sep=0pt,minimum size=5pt] \tikzstyle{every path}=[draw] \tikzstyle{branch}=[draw,rectangle,rounded corners=3,fill=white,inner sep=2pt,minimum size=5pt] -\node[commit, black, fill=black] (dd2c9c0) at (0.0,0) {}; -\node[right,xshift=10] (label_dd2c9c0) at (dd2c9c0.east) {\verb!dd2c9c0: [doc] hook test!}; -\node[commit, black, fill=black] (8dde7ec) at (0.0,-0.5) {}; -\node[right,xshift=10] (label_8dde7ec) at (8dde7ec.east) {\verb!8dde7ec: [doc] neues Hooks!}; -\node[commit, black, fill=black] (53e02cf) at (0.0,-1.0) {}; -\node[right,xshift=10] (label_53e02cf) at (53e02cf.east) {\verb!53e02cf: [doc] test!}; -\node[commit, blue, fill=blue] (16d4f59) at (0.5,-1.5) {}; -\node[right,xshift=10] (label_16d4f59) at (16d4f59.east) {\verb!16d4f59: [doc] test!}; -\node[commit, black, fill=black] (6e41ab0) at (0.0,-2.0) {}; -\node[right,xshift=10] (label_6e41ab0) at (6e41ab0.east) {\verb!6e41ab0: [py] fixed order!}; -\node[commit, black, fill=black] (2256509) at (0.0,-2.5) {}; -\node[right,xshift=10] (label_2256509) at (2256509.east) {\verb!2256509: [py] fixed automatic colors!}; -\node[commit, black, fill=black] (8a5d531) at (0.0,-3.0) {}; -\node[right,xshift=10] (label_8a5d531) at (8a5d531.east) {\verb!8a5d531: [py] minor fix!}; -\node[commit, black, fill=black] (7ac7de4) at (0.0,-3.5) {}; -\node[right,xshift=10] (label_7ac7de4) at (7ac7de4.east) {\verb!7ac7de4: Merge branch 'master' into feature/python!}; -\node[commit, blue, fill=blue] (69be133) at (0.5,-4.0) {}; -\node[right,xshift=10] (label_69be133) at (69be133.east) {\verb!69be133: [py]minor bugfix!}; -\node[commit, black, fill=black] (1af283b) at (0.0,-4.5) {}; -\node[right,xshift=10] (label_1af283b) at (1af283b.east) {\verb!1af283b: [py] some comments!}; -\node[commit, black, fill=black] (da268ea) at (0.0,-5.0) {}; -\node[right,xshift=10] (label_da268ea) at (da268ea.east) {\verb!da268ea: [py] Export copy finished!}; -\node[commit, black, fill=black] (3dbbd41) at (0.0,-5.5) {}; -\node[right,xshift=10] (label_3dbbd41) at (3dbbd41.east) {\verb!3dbbd41: [py] commit & branch läuft!}; -\node[commit, black, fill=black] (afd6f5a) at (0.0,-6.0) {}; -\node[right,xshift=10] (label_afd6f5a) at (afd6f5a.east) {\verb!afd6f5a: [py] Commit funktioniert!}; -\node[commit, black, fill=black] (9ebee64) at (0.0,-6.5) {}; -\node[right,xshift=10] (label_9ebee64) at (9ebee64.east) {\verb!9ebee64: [py] init & git shell!}; -\node[commit, black, fill=black] (e5c3cd5) at (0.0,-7.0) {}; -\node[right,xshift=10] (label_e5c3cd5) at (e5c3cd5.east) {\verb!e5c3cd5: added Ruby Skript!}; -\node[commit, black, fill=black] (d78896f) at (0.0,-7.5) {}; -\node[right,xshift=10] (label_d78896f) at (d78896f.east) {\verb!d78896f: [doc] kleine änderrung!}; -\node[commit, black, fill=black] (a6f6d74) at (0.0,-8.0) {}; +\node[commit, black, fill=black] (a6f6d74) at (0.0,0) {}; \node[right,xshift=10] (label_a6f6d74) at (a6f6d74.east) {\verb!a6f6d74: Grober Latex Test!}; -\path[black] (8dde7ec) to[out=90,in=-90] (dd2c9c0); -\path[black] (53e02cf) to[out=90,in=-90] (8dde7ec); -\path[black] (6e41ab0) to[out=90,in=-90] (16d4f59); -\path[black] (6e41ab0) to[out=90,in=-90] (53e02cf); -\path[black] (2256509) to[out=90,in=-90] (6e41ab0); -\path[black] (8a5d531) to[out=90,in=-90] (2256509); -\path[black] (7ac7de4) to[out=90,in=-90] (8a5d531); -\path[blue] (69be133) to[out=90,in=-90] (7ac7de4); -\path[black] (1af283b) to[out=90,in=-90] (7ac7de4); +\node[commit, black, fill=black] (d78896f) at (0.0,0.5) {}; +\node[right,xshift=10] (label_d78896f) at (d78896f.east) {\verb!d78896f: [doc] kleine änderrung!}; +\node[commit, black, fill=black] (e5c3cd5) at (0.0,1.0) {}; +\node[right,xshift=10] (label_e5c3cd5) at (e5c3cd5.east) {\verb!e5c3cd5: added Ruby Skript!}; +\node[commit, black, fill=black] (9ebee64) at (0.0,1.5) {}; +\node[right,xshift=10] (label_9ebee64) at (9ebee64.east) {\verb!9ebee64: [py] init & git shell!}; +\node[commit, black, fill=black] (afd6f5a) at (0.0,2.0) {}; +\node[right,xshift=10] (label_afd6f5a) at (afd6f5a.east) {\verb!afd6f5a: [py] Commit funktioniert!}; +\node[commit, black, fill=black] (3dbbd41) at (0.0,2.5) {}; +\node[right,xshift=10] (label_3dbbd41) at (3dbbd41.east) {\verb!3dbbd41: [py] commit & branch läuft!}; +\node[commit, black, fill=black] (da268ea) at (0.0,3.0) {}; +\node[right,xshift=10] (label_da268ea) at (da268ea.east) {\verb!da268ea: [py] Export copy finished!}; +\node[commit, black, fill=black] (1af283b) at (0.0,3.5) {}; +\node[right,xshift=10] (label_1af283b) at (1af283b.east) {\verb!1af283b: [py] some comments!}; +\node[commit, blue, fill=blue] (69be133) at (0.5,4.0) {}; +\node[right,xshift=10] (label_69be133) at (69be133.east) {\verb!69be133: [py]minor bugfix!}; +\node[commit, black, fill=black] (7ac7de4) at (0.0,4.5) {}; +\node[right,xshift=10] (label_7ac7de4) at (7ac7de4.east) {\verb!7ac7de4: Merge branch 'master' into feature/python!}; +\node[commit, black, fill=black] (8a5d531) at (0.0,5.0) {}; +\node[right,xshift=10] (label_8a5d531) at (8a5d531.east) {\verb!8a5d531: [py] minor fix!}; +\node[commit, black, fill=black] (2256509) at (0.0,5.5) {}; +\node[right,xshift=10] (label_2256509) at (2256509.east) {\verb!2256509: [py] fixed automatic colors!}; +\node[commit, black, fill=black] (6e41ab0) at (0.0,6.0) {}; +\node[right,xshift=10] (label_6e41ab0) at (6e41ab0.east) {\verb!6e41ab0: [py] fixed order!}; +\node[commit, blue, fill=blue] (16d4f59) at (0.5,6.5) {}; +\node[right,xshift=10] (label_16d4f59) at (16d4f59.east) {\verb!16d4f59: [doc] test!}; +\node[commit, black, fill=black] (53e02cf) at (0.0,7.0) {}; +\node[right,xshift=10] (label_53e02cf) at (53e02cf.east) {\verb!53e02cf: [doc] test!}; +\node[commit, black, fill=black] (8dde7ec) at (0.0,7.5) {}; +\node[right,xshift=10] (label_8dde7ec) at (8dde7ec.east) {\verb!8dde7ec: [doc] neues Hooks!}; +\node[commit, black, fill=black] (8024ece) at (0.0,8.0) {}; +\node[right,xshift=10] (label_8024ece) at (8024ece.east) {\verb!8024ece: [doc] hook test!}; +\node[commit, black, fill=black] (7ef61eb) at (0.0,8.5) {}; +\node[right,xshift=10] (label_7ef61eb) at (7ef61eb.east) {\verb!7ef61eb: [doc] hooktest 2!}; +\node[commit, black, fill=black] (d477a13) at (0.0,9.0) {}; +\node[right,xshift=10] (label_d477a13) at (d477a13.east) {\verb!d477a13: [doc] neuer Branch!}; +\path[black] (a6f6d74) to[out=90,in=-90] (d78896f); +\path[black] (d78896f) to[out=90,in=-90] (e5c3cd5); +\path[black] (e5c3cd5) to[out=90,in=-90] (9ebee64); +\path[black] (9ebee64) to[out=90,in=-90] (afd6f5a); +\path[black] (afd6f5a) to[out=90,in=-90] (3dbbd41); +\path[black] (3dbbd41) to[out=90,in=-90] (da268ea); \path[black] (da268ea) to[out=90,in=-90] (69be133); \path[black] (da268ea) to[out=90,in=-90] (1af283b); -\path[black] (3dbbd41) to[out=90,in=-90] (da268ea); -\path[black] (afd6f5a) to[out=90,in=-90] (3dbbd41); -\path[black] (9ebee64) to[out=90,in=-90] (afd6f5a); -\path[black] (e5c3cd5) to[out=90,in=-90] (9ebee64); -\path[black] (d78896f) to[out=90,in=-90] (e5c3cd5); -\path[black] (a6f6d74) to[out=90,in=-90] (d78896f); -\node[branch,right,xshift=10] (develop) at (label_dd2c9c0.east) {\lstinline{develop}}; -\node[branch,right,xshift=10] (feature/python) at (label_6e41ab0.east) {\lstinline{feature/python}}; +\path[black] (1af283b) to[out=90,in=-90] (7ac7de4); +\path[blue] (69be133) to[out=90,in=-90] (7ac7de4); +\path[black] (7ac7de4) to[out=90,in=-90] (8a5d531); +\path[black] (8a5d531) to[out=90,in=-90] (2256509); +\path[black] (2256509) to[out=90,in=-90] (6e41ab0); +\path[black] (6e41ab0) to[out=90,in=-90] (16d4f59); +\path[black] (6e41ab0) to[out=90,in=-90] (53e02cf); +\path[black] (53e02cf) to[out=90,in=-90] (8dde7ec); +\path[black] (8dde7ec) to[out=90,in=-90] (8024ece); +\path[black] (8024ece) to[out=90,in=-90] (7ef61eb); +\path[black] (7ef61eb) to[out=90,in=-90] (d477a13); +\node[branch,right,xshift=10] (develop) at (label_7ef61eb.east) {\lstinline{develop}}; +\node[branch,right,xshift=10] (feature/python) at (label_7ef61eb.east) {\lstinline{feature/python}}; +\node[branch,right,xshift=10] (feature/python2) at (label_d477a13.east) {\lstinline{feature/python2}}; \node[branch,right,xshift=10] (master) at (label_16d4f59.east) {\lstinline{master}}; \end{tikzpicture} diff --git a/text-output.pdf b/text-output.pdf index 0fcf62c..0b5ac10 100644 Binary files a/text-output.pdf and b/text-output.pdf differ