proj-flow 0.8.1__py3-none-any.whl → 0.9.0__py3-none-any.whl
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.
- proj_flow/__init__.py +1 -1
- proj_flow/__main__.py +1 -1
- proj_flow/api/__init__.py +11 -2
- proj_flow/api/arg.py +14 -6
- proj_flow/api/env.py +15 -35
- proj_flow/api/release.py +99 -0
- proj_flow/api/step.py +12 -2
- proj_flow/base/__init__.py +2 -2
- proj_flow/base/inspect.py +15 -44
- proj_flow/base/plugins.py +41 -2
- proj_flow/base/registry.py +105 -0
- proj_flow/cli/__init__.py +55 -0
- proj_flow/cli/argument.py +447 -0
- proj_flow/{flow/cli → cli}/finder.py +1 -1
- proj_flow/ext/__init__.py +6 -0
- proj_flow/ext/github/__init__.py +11 -0
- proj_flow/ext/github/cli.py +118 -0
- proj_flow/ext/github/hosting.py +19 -0
- proj_flow/ext/markdown_changelist.py +14 -0
- proj_flow/ext/python/__init__.py +10 -0
- proj_flow/ext/python/rtdocs.py +238 -0
- proj_flow/ext/python/steps.py +71 -0
- proj_flow/ext/python/version.py +98 -0
- proj_flow/ext/re_structured_changelist.py +14 -0
- proj_flow/flow/__init__.py +3 -3
- proj_flow/flow/configs.py +21 -5
- proj_flow/flow/dependency.py +8 -6
- proj_flow/flow/steps.py +6 -9
- proj_flow/log/__init__.py +10 -2
- proj_flow/log/commit.py +19 -4
- proj_flow/log/error.py +31 -0
- proj_flow/log/hosting/github.py +10 -6
- proj_flow/log/msg.py +23 -0
- proj_flow/log/release.py +112 -21
- proj_flow/log/rich_text/__init__.py +0 -12
- proj_flow/log/rich_text/api.py +10 -4
- proj_flow/minimal/__init__.py +11 -0
- proj_flow/{plugins/commands → minimal}/bootstrap.py +2 -2
- proj_flow/{plugins/commands → minimal}/list.py +12 -10
- proj_flow/{plugins/commands → minimal}/run.py +20 -11
- proj_flow/{plugins/commands → minimal}/system.py +2 -2
- proj_flow/plugins/__init__.py +1 -1
- proj_flow/template/layers/base/.flow/matrix.yml +1 -1
- proj_flow/template/layers/cmake/CMakeLists.txt.mustache +1 -1
- proj_flow/template/layers/github_actions/.github/workflows/build.yml +1 -1
- proj_flow/template/layers/github_social/.github/ISSUE_TEMPLATE/feature_request.md.mustache +1 -1
- {proj_flow-0.8.1.dist-info → proj_flow-0.9.0.dist-info}/METADATA +6 -5
- {proj_flow-0.8.1.dist-info → proj_flow-0.9.0.dist-info}/RECORD +51 -37
- proj_flow-0.9.0.dist-info/entry_points.txt +2 -0
- proj_flow/flow/cli/__init__.py +0 -66
- proj_flow/flow/cli/cmds.py +0 -385
- proj_flow-0.8.1.dist-info/entry_points.txt +0 -2
- {proj_flow-0.8.1.dist-info → proj_flow-0.9.0.dist-info}/WHEEL +0 -0
- {proj_flow-0.8.1.dist-info → proj_flow-0.9.0.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,42 +1,60 @@
|
|
|
1
|
-
proj_flow/__init__.py,sha256=
|
|
2
|
-
proj_flow/__main__.py,sha256=
|
|
3
|
-
proj_flow/api/__init__.py,sha256=
|
|
4
|
-
proj_flow/api/arg.py,sha256=
|
|
1
|
+
proj_flow/__init__.py,sha256=UtRFdb2fvniMm_xApll78tgH4iEnAWu1dCbELDj2dbw,124
|
|
2
|
+
proj_flow/__main__.py,sha256=xpK1_avlRKlSw55135IAmaTfRKt344-qkJrVFz45ogM,229
|
|
3
|
+
proj_flow/api/__init__.py,sha256=gV2f6kll_5JXtvkGASvnx7CbOWr34PHOdck-4ce-qEk,378
|
|
4
|
+
proj_flow/api/arg.py,sha256=J7_53noW7t8VJ9sfJiX4qaPs7KqWfMHNcrWYe1jIq-g,4097
|
|
5
5
|
proj_flow/api/completers.py,sha256=NapNVu6QAQ_iF6dqcAzOV5kDHKD9MAMVX209Bklq-Mw,2464
|
|
6
6
|
proj_flow/api/ctx.py,sha256=AXZSnfLO9w7Uiqa8VtrTzLnNegVZru2sn1-WON3RIyg,5847
|
|
7
|
-
proj_flow/api/env.py,sha256=
|
|
7
|
+
proj_flow/api/env.py,sha256=bFDHuFtUR-zEh7fTrEoPFobBLx2W4ZIl4TGJ8E9s5mM,10909
|
|
8
8
|
proj_flow/api/init.py,sha256=an0czDiPCDqW4Bp0I8sGQgaAlDAozLO0ZYnP149lWqk,521
|
|
9
9
|
proj_flow/api/makefile.py,sha256=hNKKe1Mf0V8JZl7yNLn5BJfHXJtjREqDVZ7JDRLkE4M,3858
|
|
10
|
-
proj_flow/api/
|
|
11
|
-
proj_flow/
|
|
10
|
+
proj_flow/api/release.py,sha256=A-t4qcjeaptEgfBCZs2Q9cOjsGACrNM0CzmCorms0U4,2401
|
|
11
|
+
proj_flow/api/step.py,sha256=PAqLBkQkUVQETrBvHjI6_-PAkh4Q7KLPMBUOWqW_jbk,4580
|
|
12
|
+
proj_flow/base/__init__.py,sha256=RRmqiYjdVlC4i8QijXHNiRh9yzNH8305WXezrSaPjKk,311
|
|
12
13
|
proj_flow/base/cmd.py,sha256=Vo3e8kd4CHRzbsUkO-MnbhQxjLXTczv7YQRUkFlcBQE,1560
|
|
13
|
-
proj_flow/base/inspect.py,sha256=
|
|
14
|
+
proj_flow/base/inspect.py,sha256=lt5P19rvSZ-wMCTrCYAaQFCt2S9fUjEQXlrKK-Tmvwc,2786
|
|
14
15
|
proj_flow/base/matrix.py,sha256=8XBFGYOwW6Myt_4h3WNk36V2bJ5xeqUv6DvzF4B3q_g,7767
|
|
15
|
-
proj_flow/base/plugins.py,sha256=
|
|
16
|
+
proj_flow/base/plugins.py,sha256=ZH8p16eeqdf7r99IHPEzvTxATXonj3QSwnYhEPtJSvE,2089
|
|
17
|
+
proj_flow/base/registry.py,sha256=0OdNeeZmek1CecR0yMRAcKc7zHtQ6kpKTBPdfdV8iRo,2933
|
|
16
18
|
proj_flow/base/uname.py,sha256=7Awb3Es0jTAKMpyRawdrC16xc5X9M97BlPqEfQibqIk,2295
|
|
17
|
-
proj_flow/
|
|
18
|
-
proj_flow/
|
|
19
|
-
proj_flow/
|
|
19
|
+
proj_flow/cli/__init__.py,sha256=IpNnnr3ZOzwCmdhAzzruA8Sms04U1thdJjUvU6qpRH8,1270
|
|
20
|
+
proj_flow/cli/argument.py,sha256=RFBOpeTqyUGM0KvnyKA-lzfUfZpXE-mJl9RcoQzRciY,13661
|
|
21
|
+
proj_flow/cli/finder.py,sha256=5x7H1nH0k63DetDauhB_wABel_f0RQpsZ5YnhPfbkRc,1402
|
|
22
|
+
proj_flow/ext/__init__.py,sha256=XD52rUFTPz3GnyRq6KZUNeWdMce7e0bB19iTx-zU6DE,169
|
|
23
|
+
proj_flow/ext/markdown_changelist.py,sha256=P6FSfX2yD62Zm5_KnNDKo2XB-K_7rLZsXPcs6xH87xo,351
|
|
24
|
+
proj_flow/ext/re_structured_changelist.py,sha256=u1mNCvntGRf-r6ti1fRVe-99IgWbxb5htfjzyeVml_0,360
|
|
25
|
+
proj_flow/ext/github/__init__.py,sha256=_ujB0X99q0DYWMwL1H4TiYyxTzKsE_2Pvzwva91_jrw,260
|
|
26
|
+
proj_flow/ext/github/cli.py,sha256=JyvEjDKf5eSQuGep7VnEPAJKaUOWSdEudSYWkNCMBjk,3430
|
|
27
|
+
proj_flow/ext/github/hosting.py,sha256=3iW8QjeJk7MyqKNbv92nB-5a_Yn_B5_eEIlw_cdgUT0,519
|
|
28
|
+
proj_flow/ext/python/__init__.py,sha256=GbEKEJJZ3PJ4sRHEykAWjGIR6yyyrYdlUFulldvsAGI,252
|
|
29
|
+
proj_flow/ext/python/rtdocs.py,sha256=MliuI8GJ0lP7Azyeqt6qCMKLVOy0h7RdTwJbkw2Oc4c,6350
|
|
30
|
+
proj_flow/ext/python/steps.py,sha256=pDHGAe_CDzzdRFAzM1AIBvkbc14KB3SNUunusKZAaaY,1815
|
|
31
|
+
proj_flow/ext/python/version.py,sha256=d8cY36bJYkNNH_JQcj6v-DnBLeT2CsyIzj_nz76MUBU,3182
|
|
32
|
+
proj_flow/flow/__init__.py,sha256=Y1MfQsrbk_dIT6pn7c9YIlqsEUZj4Q9n_oIGtbnhIP4,339
|
|
33
|
+
proj_flow/flow/configs.py,sha256=l-pIotrXFm4oMqqpuvKP-RdtlTmDDnK_izhTJfsWbhk,5260
|
|
34
|
+
proj_flow/flow/dependency.py,sha256=5o_-5Soc2e1tOu5mwvkXa6jqDFplZi_chN8edkR6vVY,4644
|
|
20
35
|
proj_flow/flow/init.py,sha256=9k3cgVmmeOKtH6mJ0nc4IOmI48oXvtYXFYWx2rj60-M,1777
|
|
21
36
|
proj_flow/flow/interact.py,sha256=AJknpCxk3C39GhsR6BjH5QDk33KouWCZbHEUFLjvfGc,4166
|
|
22
37
|
proj_flow/flow/layer.py,sha256=6mvbhiOy9KcMP69Q9zew_7jGhf5Wqr7v-veS3YPGnmc,5720
|
|
23
|
-
proj_flow/flow/steps.py,sha256=
|
|
24
|
-
proj_flow/
|
|
25
|
-
proj_flow/
|
|
26
|
-
proj_flow/
|
|
27
|
-
proj_flow/log/__init__.py,sha256=jVVE9hgi6x9QazO9qI07AJZ_c4KCDcsk-Ye5N4CT5XY,318
|
|
28
|
-
proj_flow/log/commit.py,sha256=oO6rnELiMCGRc86szzW2vr7P5iiiI-w9zXCF2bEOL20,12746
|
|
38
|
+
proj_flow/flow/steps.py,sha256=PN_C_B6vNvqOsjpDpa5ESvH30Sc6RM1fSSqWqXgqg-4,2804
|
|
39
|
+
proj_flow/log/__init__.py,sha256=02EIgasE-K7mmbbNiIdX0IebWQMp2Co_D6H4ZBhJgcs,365
|
|
40
|
+
proj_flow/log/commit.py,sha256=MQhx5ZIeVQ3_8o4w2giLNTVn6Ig-cUGxTDQhlJoN6Ig,13060
|
|
41
|
+
proj_flow/log/error.py,sha256=65Nvhfs_d1xSY4EB-ISdWgjotvg-on3iKjhAWHpsBYM,841
|
|
29
42
|
proj_flow/log/fmt.py,sha256=o14aO3iEt5_KKp9SqcfkscqbMKuTI83NBoSXHcrb7Kg,330
|
|
30
43
|
proj_flow/log/format.py,sha256=gp1kUoW0nYj5e7Ysu1c29Fh2ssfE1KBSDIYeUbhzN9g,333
|
|
31
|
-
proj_flow/log/msg.py,sha256=
|
|
32
|
-
proj_flow/log/release.py,sha256=
|
|
44
|
+
proj_flow/log/msg.py,sha256=zARmRZHFV3yG-fBnx00wal4Y0O5aGnL-6XcGwNBNKA4,6758
|
|
45
|
+
proj_flow/log/release.py,sha256=Sv9IPtZizJqHtJVdvx2TCt-a1PNSaFnWPHo2CQaDaC8,3837
|
|
33
46
|
proj_flow/log/hosting/__init__.py,sha256=9Teyw8jJcxeWH2MegqYEgW0n5OmSAWC7FFJj2u_UcrM,278
|
|
34
|
-
proj_flow/log/hosting/github.py,sha256
|
|
35
|
-
proj_flow/log/rich_text/__init__.py,sha256=
|
|
36
|
-
proj_flow/log/rich_text/api.py,sha256=
|
|
47
|
+
proj_flow/log/hosting/github.py,sha256=-13krmAqTWcOQ21ZPSrMeZ4ipmgBSMCgoVk9AstpsvQ,6747
|
|
48
|
+
proj_flow/log/rich_text/__init__.py,sha256=D3Y2jy9xlGgnQZdNC_ekoLzQtwkF_NTgLqDTWPvSRUk,279
|
|
49
|
+
proj_flow/log/rich_text/api.py,sha256=PCSAGwkmDUMoVlpN7BDsgIA1AiMZEC0H6TUZXpr_Mg8,3571
|
|
37
50
|
proj_flow/log/rich_text/markdown.py,sha256=GVDH7hONyATRG4FyXkSvprEzxikRXiErGyINjiJfQx8,1618
|
|
38
51
|
proj_flow/log/rich_text/re_structured_text.py,sha256=zDx4KQQy1RzYhzTfnldwCYIxl-jypyDBYOwNKP1SqN4,1818
|
|
39
|
-
proj_flow/
|
|
52
|
+
proj_flow/minimal/__init__.py,sha256=VsIdoFE0RRXueJf4-fVJF15iukkZUiysJsr8sTb9XIs,326
|
|
53
|
+
proj_flow/minimal/bootstrap.py,sha256=PcZfBsUmj8uDPGBC55iUgD5O7W4VSkpCQb6r9GEyAaQ,556
|
|
54
|
+
proj_flow/minimal/list.py,sha256=RlOqammE8olNKXsnbv1enF5uriu0MZ2wFbht37Z2ETw,4810
|
|
55
|
+
proj_flow/minimal/run.py,sha256=fkirdYeWb36SFXqIq5NQEflIv0HdjNhaTpmsutzWwXA,4691
|
|
56
|
+
proj_flow/minimal/system.py,sha256=9FliH5TD103JYSAe2O5EU7hkOHDgVzTqu0Exxk-WrXE,1579
|
|
57
|
+
proj_flow/plugins/__init__.py,sha256=nJQiXQU2zOiM_mafqoBsCu3ivpuA_o2vAOPk4HdfBvY,308
|
|
40
58
|
proj_flow/plugins/base.py,sha256=yDAn7417DazBXMzZpZs8wv1DNY_9EjqtkWRq2IOF_Oo,736
|
|
41
59
|
proj_flow/plugins/github.py,sha256=hcC-le-suTxlX929wzwvghtNFSqiVn5VCcVoLDeMHj4,402
|
|
42
60
|
proj_flow/plugins/cmake/__init__.py,sha256=Mk4Rm6Pqv7Jkd27cSfoP90bhVv4fxMcg3Rr0fNNJ63c,386
|
|
@@ -48,11 +66,7 @@ proj_flow/plugins/cmake/pack.py,sha256=2rBaPePbqJn55pFBAkPQSjQJeK14HWfu6ogu9ZtVP
|
|
|
48
66
|
proj_flow/plugins/cmake/parser.py,sha256=MA1PB1lWybDC0YGYhaXEuHawGRPRRsjpJJ4qFqkDf8U,4223
|
|
49
67
|
proj_flow/plugins/cmake/test.py,sha256=POUa5QBb9mTTCYhS7wLjkqtVRiFGoJxD8O556bDYHXs,790
|
|
50
68
|
proj_flow/plugins/commands/__init__.py,sha256=-5jT0bfrrGds3TbAOIRZOFJjH2Q8IUKDzm02Ac7PO_4,298
|
|
51
|
-
proj_flow/plugins/commands/bootstrap.py,sha256=Lqp15skMXaH0OOUvXIWRSfGiR3WfELMgdhLGIc3Na2U,570
|
|
52
69
|
proj_flow/plugins/commands/init.py,sha256=MrdxMv9G-0oYZgLk5OOKjd36Z-b55mdJaTV9ix3va9o,2090
|
|
53
|
-
proj_flow/plugins/commands/list.py,sha256=1hRgPamQmNulxwVHCtd8rA3wEQQdLMWozPLdj9ULsog,4733
|
|
54
|
-
proj_flow/plugins/commands/run.py,sha256=yMyT37U2QXVNWC-CEJEOoMtBU-O1mTMmXC1Z1ArOOxc,4434
|
|
55
|
-
proj_flow/plugins/commands/system.py,sha256=VsfC3O7PrgVCtrgJwvmR4e7ggmt0puLSTC0NTH6Qbl8,1593
|
|
56
70
|
proj_flow/plugins/commands/ci/__init__.py,sha256=4PkKCd2HoCHypAzO7GZatCkrV0fteLWdoICviQXoyAg,369
|
|
57
71
|
proj_flow/plugins/commands/ci/changelog.py,sha256=Q2f-JGuFxmK0IJg7K8RN3z_Rv_29haexgoFQWUysUM0,1296
|
|
58
72
|
proj_flow/plugins/commands/ci/matrix.py,sha256=tjEpyCTdNvIY4xvyGNy5KffCkmOXnVUUXVTds9WeDeA,1362
|
|
@@ -77,10 +91,10 @@ proj_flow/template/layers/base/flow,sha256=aPBLCgYNAZFl3FcP3HPwPnUxuRGxeV1Dp_6qF
|
|
|
77
91
|
proj_flow/template/layers/base/flow.cmd,sha256=LQplRzLw4n86xvMXxOd1SzH2xJAN71Ou1uWsST8D6Ik,239
|
|
78
92
|
proj_flow/template/layers/base/.flow/config.yml,sha256=7dc7u0FVBWP0nwOCzWNHEGeOM_APR467vyMuT_Mjfto,773
|
|
79
93
|
proj_flow/template/layers/base/.flow/flow.py.mustache,sha256=UpCW3-DVa3d_4XmVkmzQu_L6vfiDr7RGUJiyFz5ykRM,4679
|
|
80
|
-
proj_flow/template/layers/base/.flow/matrix.yml,sha256=
|
|
94
|
+
proj_flow/template/layers/base/.flow/matrix.yml,sha256=XgDC-F8YfeZEILBwHPkGNeRCxgaDK79f-JoWfHlVrgc,1257
|
|
81
95
|
proj_flow/template/layers/base/.flow/official.yml,sha256=2nQgxoQJ5IAnPQVn50LrVD0B2p9KpLYSVz1b7IFu0Zc,71
|
|
82
96
|
proj_flow/template/layers/cmake/CMakeGraphVizOptions.cmake,sha256=lAuNOIFDOAPnU_Zfz0ZCxephIp2bqteVlMSsuVg0BTM,368
|
|
83
|
-
proj_flow/template/layers/cmake/CMakeLists.txt.mustache,sha256=
|
|
97
|
+
proj_flow/template/layers/cmake/CMakeLists.txt.mustache,sha256=qZ7LQcBG5-jUq69ZoGxpHTH3nYLLbUnXNeDJvwEGZ8Y,6251
|
|
84
98
|
proj_flow/template/layers/cmake/CMakePresets.json,sha256=B6j0Cxh_l8QfxHNV1IIWoGyMBz4unVHyAGbUUKJWBFM,5487
|
|
85
99
|
proj_flow/template/layers/cmake/.flow/cmake/common.cmake.mustache,sha256=ntar1ypWUH10JwrebdrnOjQz0Nk8KpDyE6Qh4M2y86I,1053
|
|
86
100
|
proj_flow/template/layers/cmake/.flow/extensions/wall/__init__.py.mustache,sha256=oEnCHoU4KtUZb-4SX3ld255jHT06nEx7pS6gW-w-zIc,127
|
|
@@ -108,19 +122,19 @@ proj_flow/template/layers/conan/.flow/cmake/output_dirs_setup.cmake,sha256=-GSDi
|
|
|
108
122
|
proj_flow/template/layers/github_actions/CPPLINT.cfg,sha256=JX88FBnJ3pECU0QS-8CjOfvWo_my6lSgX8kc1oi-mmY,385
|
|
109
123
|
proj_flow/template/layers/github_actions/.github/linters/.isort.cfg,sha256=9gpUkeq6rXGxXeeokeGkTDjOBvDpdlcup8ipxCpJQ9s,79
|
|
110
124
|
proj_flow/template/layers/github_actions/.github/linters/.mypy.ini,sha256=13DnGOzVFyXtkXH-48LlblCLfiXc2Xbzk78pllCKbSo,37
|
|
111
|
-
proj_flow/template/layers/github_actions/.github/workflows/build.yml,sha256=
|
|
125
|
+
proj_flow/template/layers/github_actions/.github/workflows/build.yml,sha256=K1a_bk3ybA2NfVazDQNvInVHHSD4lG-zxaRSuDjw994,8166
|
|
112
126
|
proj_flow/template/layers/github_actions/.github/workflows/linter.yml,sha256=Ffg-ptQ9kjw4X0UyQax9-3AMIP2H62ikDkbgPi0ypeM,1545
|
|
113
127
|
proj_flow/template/layers/github_social/CODE_OF_CONDUCT.md.mustache,sha256=XzXW9p1pX7AA5DcWW7cz-Onrxa0J32WclgCYWeYLT3Y,3347
|
|
114
128
|
proj_flow/template/layers/github_social/CONTRIBUTING.md,sha256=nw1FZgDtKXubnRqvBaQgSmUqpsvDy_433VGmy5W-BH4,239
|
|
115
129
|
proj_flow/template/layers/github_social/.github/ISSUE_TEMPLATE/bug_report.md.mustache,sha256=n1O-WANLPD3hMBLKXB_jwuFIb6xQ77elaVjqasRQwp4,1041
|
|
116
|
-
proj_flow/template/layers/github_social/.github/ISSUE_TEMPLATE/feature_request.md.mustache,sha256=
|
|
130
|
+
proj_flow/template/layers/github_social/.github/ISSUE_TEMPLATE/feature_request.md.mustache,sha256=scmkwO5qgwX0HkoAhUybnbZOWZ1-tEViR1A7378LdcA,843
|
|
117
131
|
proj_flow/template/licenses/0BSD.mustache,sha256=GXHBGk29Tviv6M-ysTRNH_IHh7j8CKBGCPAMG7zXZSY,651
|
|
118
132
|
proj_flow/template/licenses/MIT.mustache,sha256=NncPoQaNsuy-WmRmboik3fyhJJ8m5pc2RVsfeelYA9s,1081
|
|
119
133
|
proj_flow/template/licenses/Unlicense.mustache,sha256=awOCsWJ58m_2kBQwBUGWejVqZm6wuRtCL2hi9rfa0X4,1211
|
|
120
134
|
proj_flow/template/licenses/WTFPL.mustache,sha256=lvF4V_PrKKfZPa2TC8CZo8tlqaKvs3Bpv9G6XsWWQ4k,483
|
|
121
135
|
proj_flow/template/licenses/Zlib.mustache,sha256=uIj-mhSjes2HJ3rRapyy2ALflKRz4xQgS4mVM9827C0,868
|
|
122
|
-
proj_flow-0.
|
|
123
|
-
proj_flow-0.
|
|
124
|
-
proj_flow-0.
|
|
125
|
-
proj_flow-0.
|
|
126
|
-
proj_flow-0.
|
|
136
|
+
proj_flow-0.9.0.dist-info/METADATA,sha256=ApEM1wxQjZ2gejY6uTBx0FbkJCl-iwOp8TKjLoScf7c,2780
|
|
137
|
+
proj_flow-0.9.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
138
|
+
proj_flow-0.9.0.dist-info/entry_points.txt,sha256=d_OmGKZzpY7FCWz0sZ4wnBAPZC75oMEzTgJZWtpDELo,49
|
|
139
|
+
proj_flow-0.9.0.dist-info/licenses/LICENSE,sha256=vpOQJ5QlrTedF3coEWvA4wJzVJH304f66ZitR7Od4iU,1068
|
|
140
|
+
proj_flow-0.9.0.dist-info/RECORD,,
|
proj_flow/flow/cli/__init__.py
DELETED
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
# PYTHON_ARGCOMPLETE_OK
|
|
2
|
-
|
|
3
|
-
# Copyright (c) 2025 Marcin Zdun
|
|
4
|
-
# This code is licensed under MIT license (see LICENSE for details)
|
|
5
|
-
|
|
6
|
-
"""
|
|
7
|
-
The **proj_flow.flow.cli** provides command-line entry for the *C++ flow*.
|
|
8
|
-
"""
|
|
9
|
-
|
|
10
|
-
import argparse
|
|
11
|
-
import os
|
|
12
|
-
import sys
|
|
13
|
-
from typing import Dict, List, cast
|
|
14
|
-
|
|
15
|
-
from proj_flow import __version__
|
|
16
|
-
from proj_flow.api import env
|
|
17
|
-
from proj_flow.flow import steps
|
|
18
|
-
from proj_flow.flow.cli import cmds, finder
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
def _change_dir():
|
|
22
|
-
root = argparse.ArgumentParser(
|
|
23
|
-
prog="proj-flow",
|
|
24
|
-
usage="proj-flow [-h] [--version] [-C [dir]] {command} ...",
|
|
25
|
-
add_help=False,
|
|
26
|
-
)
|
|
27
|
-
root.add_argument("-C", dest="cd", nargs="?")
|
|
28
|
-
|
|
29
|
-
args, _ = root.parse_known_args()
|
|
30
|
-
if args.cd:
|
|
31
|
-
os.chdir(args.cd)
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
def _expand_shortcuts(parser: argparse.ArgumentParser, args: argparse.Namespace):
|
|
35
|
-
args_kwargs = dict(args._get_kwargs())
|
|
36
|
-
shortcuts: Dict[str, List[str]] = parser.shortcuts # type: ignore
|
|
37
|
-
for key in shortcuts:
|
|
38
|
-
try:
|
|
39
|
-
if not args_kwargs[key]:
|
|
40
|
-
continue
|
|
41
|
-
cast(List[str], args.configs).extend(shortcuts[key])
|
|
42
|
-
break
|
|
43
|
-
except KeyError:
|
|
44
|
-
continue
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
def __main():
|
|
48
|
-
_change_dir()
|
|
49
|
-
|
|
50
|
-
flow_cfg = env.FlowConfig(root=finder.autocomplete.find_project())
|
|
51
|
-
steps.clean_aliases(flow_cfg)
|
|
52
|
-
|
|
53
|
-
parser = cmds.build_argparser(flow_cfg)
|
|
54
|
-
finder.autocomplete(parser)
|
|
55
|
-
args = parser.parse_args()
|
|
56
|
-
_expand_shortcuts(parser, args)
|
|
57
|
-
|
|
58
|
-
sys.exit(cmds.BuiltinEntry.run_entry(args, flow_cfg))
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
def main():
|
|
62
|
-
"""Entry point for *C++ flow* tool."""
|
|
63
|
-
try:
|
|
64
|
-
__main()
|
|
65
|
-
except KeyboardInterrupt:
|
|
66
|
-
sys.exit(1)
|
proj_flow/flow/cli/cmds.py
DELETED
|
@@ -1,385 +0,0 @@
|
|
|
1
|
-
# Copyright (c) 2025 Marcin Zdun
|
|
2
|
-
# This code is licensed under MIT license (see LICENSE for details)
|
|
3
|
-
|
|
4
|
-
"""
|
|
5
|
-
The **proj_flow.flow.cli.cmds** provides command-line builders and runners,
|
|
6
|
-
supporting the functions defined in :mod:`proj_flow.commands`.
|
|
7
|
-
"""
|
|
8
|
-
|
|
9
|
-
import argparse
|
|
10
|
-
import typing
|
|
11
|
-
from dataclasses import dataclass, field
|
|
12
|
-
from typing import Dict, List, Optional, Tuple, Union, cast
|
|
13
|
-
|
|
14
|
-
from proj_flow import __version__
|
|
15
|
-
from proj_flow.api import arg, completers, env
|
|
16
|
-
from proj_flow.base import inspect as _inspect
|
|
17
|
-
from proj_flow.flow.configs import Configs
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
def build_argparser(flow_cfg: env.FlowConfig):
|
|
21
|
-
parser = argparse.ArgumentParser(
|
|
22
|
-
prog="proj-flow",
|
|
23
|
-
description="C++ project maintenance, automated",
|
|
24
|
-
add_help=False,
|
|
25
|
-
)
|
|
26
|
-
parser.add_argument(
|
|
27
|
-
"-h", "--help", action="help", help="Show this help message and exit"
|
|
28
|
-
)
|
|
29
|
-
parser.add_argument(
|
|
30
|
-
"-v",
|
|
31
|
-
"--version",
|
|
32
|
-
action="version",
|
|
33
|
-
default=argparse.SUPPRESS,
|
|
34
|
-
version=f"%(prog)s version {__version__}",
|
|
35
|
-
help="Show proj-flow's version and exit",
|
|
36
|
-
)
|
|
37
|
-
parser.add_argument(
|
|
38
|
-
"-C",
|
|
39
|
-
metavar="dir",
|
|
40
|
-
nargs="?",
|
|
41
|
-
help="Run as if proj-flow was started in <dir> instead of the current "
|
|
42
|
-
"working directory. This directory must exist.",
|
|
43
|
-
).completer = completers.cd_completer # type: ignore
|
|
44
|
-
|
|
45
|
-
BuiltinEntry.visit_all(parser, flow_cfg)
|
|
46
|
-
return parser
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
@dataclass
|
|
50
|
-
class SpecialArg:
|
|
51
|
-
name: str
|
|
52
|
-
ctor: callable # type: ignore
|
|
53
|
-
|
|
54
|
-
def create(self, rt: env.Runtime, args: argparse.Namespace):
|
|
55
|
-
if self.ctor == env.Runtime:
|
|
56
|
-
return rt
|
|
57
|
-
return self.ctor(rt, args)
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
@dataclass
|
|
61
|
-
class EntryArg:
|
|
62
|
-
name: str
|
|
63
|
-
argument: arg.Argument
|
|
64
|
-
|
|
65
|
-
def visit(self, parser: argparse.ArgumentParser):
|
|
66
|
-
return self.argument.visit(parser, self.name)
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
@dataclass
|
|
70
|
-
class BuiltinEntry:
|
|
71
|
-
name: str
|
|
72
|
-
doc: str
|
|
73
|
-
entry: callable # type: ignore
|
|
74
|
-
args: List[EntryArg]
|
|
75
|
-
additional: List[SpecialArg]
|
|
76
|
-
children: List["BuiltinEntry"] = field(default_factory=list)
|
|
77
|
-
|
|
78
|
-
@staticmethod
|
|
79
|
-
def run_entry(args: argparse.Namespace, cfg: env.FlowConfig):
|
|
80
|
-
builtin_entries = {entry.name for entry in command_list}
|
|
81
|
-
aliases = cfg.aliases
|
|
82
|
-
|
|
83
|
-
rt = env.Runtime(args, cfg)
|
|
84
|
-
|
|
85
|
-
if args.command in builtin_entries:
|
|
86
|
-
command = first(lambda command: command.name == args.command, command_list)
|
|
87
|
-
if command:
|
|
88
|
-
return command.run(args, rt)
|
|
89
|
-
elif args.command in {alias.name for alias in aliases}:
|
|
90
|
-
command = first(lambda command: command.name == "run", command_list)
|
|
91
|
-
alias = first(lambda alias: alias.name == args.command, aliases)
|
|
92
|
-
if command and alias:
|
|
93
|
-
args.cli_steps.append(",".join(alias.steps))
|
|
94
|
-
return command.run(args, rt)
|
|
95
|
-
|
|
96
|
-
print("known commands:")
|
|
97
|
-
for command in command_list:
|
|
98
|
-
print(f" {command.name}: {command.doc}")
|
|
99
|
-
for alias in aliases:
|
|
100
|
-
print(f" {alias.name}: {alias.doc}")
|
|
101
|
-
return 1
|
|
102
|
-
|
|
103
|
-
def run(self, args: argparse.Namespace, rt: env.Runtime, level=0):
|
|
104
|
-
if level == 0 and rt.only_host:
|
|
105
|
-
rt.only_host = self.name == "run"
|
|
106
|
-
|
|
107
|
-
subcommand_name = None
|
|
108
|
-
|
|
109
|
-
if len(self.children):
|
|
110
|
-
subcommand_attribute = f"command_{level}"
|
|
111
|
-
if hasattr(args, subcommand_attribute):
|
|
112
|
-
subcommand_name = getattr(args, subcommand_attribute)
|
|
113
|
-
|
|
114
|
-
if subcommand_name is not None:
|
|
115
|
-
subcommand = first(
|
|
116
|
-
lambda command: command.name == subcommand_name, self.children
|
|
117
|
-
)
|
|
118
|
-
if not subcommand:
|
|
119
|
-
return 1
|
|
120
|
-
return subcommand.run(args, rt, level=level + 1)
|
|
121
|
-
|
|
122
|
-
kwargs = {}
|
|
123
|
-
for arg in self.args:
|
|
124
|
-
kwargs[arg.name] = getattr(args, arg.name, None)
|
|
125
|
-
|
|
126
|
-
for additional in self.additional:
|
|
127
|
-
arg = additional.create(rt, args)
|
|
128
|
-
kwargs[additional.name] = arg
|
|
129
|
-
|
|
130
|
-
result = self.entry(**kwargs)
|
|
131
|
-
return 0 if result is None else result
|
|
132
|
-
|
|
133
|
-
@staticmethod
|
|
134
|
-
def visit_all(parser: argparse.ArgumentParser, cfg: env.FlowConfig):
|
|
135
|
-
global command_list
|
|
136
|
-
command_list = BuiltinEntry.build_menu(arg.get_commands().subs)
|
|
137
|
-
shortcut_configs = BuiltinEntry.build_shortcuts(cfg)
|
|
138
|
-
|
|
139
|
-
parser.flow = cfg # type: ignore
|
|
140
|
-
parser.shortcuts = shortcut_configs # type: ignore
|
|
141
|
-
|
|
142
|
-
subparsers = parser.add_subparsers(
|
|
143
|
-
dest="command", metavar="{command}", help="Known command name, see below"
|
|
144
|
-
)
|
|
145
|
-
|
|
146
|
-
subparsers.parent = parser # type: ignore
|
|
147
|
-
|
|
148
|
-
run: Optional[BuiltinEntry] = None
|
|
149
|
-
for entry in command_list:
|
|
150
|
-
entry.visit(subparsers)
|
|
151
|
-
if entry.name == "run":
|
|
152
|
-
run = entry
|
|
153
|
-
|
|
154
|
-
if run is not None and len(cfg.aliases) > 0:
|
|
155
|
-
builtin_entries = {entry.name for entry in command_list}
|
|
156
|
-
cfg.aliases = [
|
|
157
|
-
alias for alias in cfg.aliases if alias.name not in builtin_entries
|
|
158
|
-
]
|
|
159
|
-
for alias in cfg.aliases:
|
|
160
|
-
run.visit(subparsers, alias=alias.name, doc=alias.doc)
|
|
161
|
-
else:
|
|
162
|
-
cfg.aliases = []
|
|
163
|
-
|
|
164
|
-
def visit(
|
|
165
|
-
self,
|
|
166
|
-
subparsers,
|
|
167
|
-
alias: Optional[str] = None,
|
|
168
|
-
doc: Optional[str] = None,
|
|
169
|
-
level=0,
|
|
170
|
-
):
|
|
171
|
-
if not doc:
|
|
172
|
-
doc = self.doc
|
|
173
|
-
if not alias:
|
|
174
|
-
alias = self.name
|
|
175
|
-
|
|
176
|
-
parser: argparse.ArgumentParser = subparsers.add_parser(
|
|
177
|
-
alias, help=doc.split("\n\n")[0], description=doc, add_help=False
|
|
178
|
-
)
|
|
179
|
-
|
|
180
|
-
parent = getattr(subparsers, "parent")
|
|
181
|
-
parser.flow = getattr(parent, "flow") # type: ignore
|
|
182
|
-
parser.shortcuts = getattr(parent, "shortcuts") # type: ignore
|
|
183
|
-
|
|
184
|
-
assert parent.flow is not None
|
|
185
|
-
assert parent.shortcuts is not None
|
|
186
|
-
|
|
187
|
-
parser.add_argument(
|
|
188
|
-
"-h",
|
|
189
|
-
"--help",
|
|
190
|
-
action="help",
|
|
191
|
-
default=argparse.SUPPRESS,
|
|
192
|
-
help="Show this help message and exit",
|
|
193
|
-
)
|
|
194
|
-
|
|
195
|
-
parser.add_argument(
|
|
196
|
-
"--dry-run",
|
|
197
|
-
action="store_true",
|
|
198
|
-
required=False,
|
|
199
|
-
help="Print steps and commands, do nothing",
|
|
200
|
-
)
|
|
201
|
-
|
|
202
|
-
verbosity = parser.add_mutually_exclusive_group()
|
|
203
|
-
verbosity.add_argument(
|
|
204
|
-
"--silent",
|
|
205
|
-
action="store_true",
|
|
206
|
-
required=False,
|
|
207
|
-
help="Remove most of the output",
|
|
208
|
-
)
|
|
209
|
-
verbosity.add_argument(
|
|
210
|
-
"--verbose",
|
|
211
|
-
action="store_true",
|
|
212
|
-
required=False,
|
|
213
|
-
help="Add even more output",
|
|
214
|
-
)
|
|
215
|
-
|
|
216
|
-
has_config = False
|
|
217
|
-
for additional in self.additional:
|
|
218
|
-
if additional.ctor == Configs:
|
|
219
|
-
has_config = True
|
|
220
|
-
break
|
|
221
|
-
|
|
222
|
-
if has_config:
|
|
223
|
-
parser.add_argument(
|
|
224
|
-
"-D",
|
|
225
|
-
dest="configs",
|
|
226
|
-
metavar="key=value",
|
|
227
|
-
nargs="*",
|
|
228
|
-
action="store",
|
|
229
|
-
default=[],
|
|
230
|
-
help="Run only builds on matching configs. The key is one of "
|
|
231
|
-
'the keys into "matrix" object in .flow/matrix.yml definition '
|
|
232
|
-
"and the value is one of the possible values for that key. In "
|
|
233
|
-
"case of boolean flags, such as sanitizer, the true value is "
|
|
234
|
-
'one of "true", "on", "yes", "1" and "with-<key>", '
|
|
235
|
-
'i.e. "with-sanitizer" for sanitizer.'
|
|
236
|
-
" "
|
|
237
|
-
"If given key is never used, all values from .flow/matrix.yaml "
|
|
238
|
-
"for that key are used. Otherwise, only values from command "
|
|
239
|
-
"line are used.",
|
|
240
|
-
).completer = completers.matrix_completer # type: ignore
|
|
241
|
-
|
|
242
|
-
parser.add_argument(
|
|
243
|
-
"--official",
|
|
244
|
-
action="store_true",
|
|
245
|
-
required=False,
|
|
246
|
-
help="Cut matrix to release builds only",
|
|
247
|
-
)
|
|
248
|
-
|
|
249
|
-
if len(parser.shortcuts): # type: ignore
|
|
250
|
-
group = parser.add_mutually_exclusive_group()
|
|
251
|
-
|
|
252
|
-
for shortcut_name in sorted(parser.shortcuts.keys()): # type: ignore
|
|
253
|
-
config = parser.shortcuts[shortcut_name] # type: ignore
|
|
254
|
-
group.add_argument(
|
|
255
|
-
f"--{shortcut_name}",
|
|
256
|
-
required=False,
|
|
257
|
-
action="store_true",
|
|
258
|
-
help=f'Shortcut for "-D {" ".join(config)}"',
|
|
259
|
-
)
|
|
260
|
-
|
|
261
|
-
for arg in self.args:
|
|
262
|
-
arg.visit(parser)
|
|
263
|
-
|
|
264
|
-
if len(self.children):
|
|
265
|
-
subparsers = parser.add_subparsers(
|
|
266
|
-
dest=f"command_{level}",
|
|
267
|
-
metavar="{command}",
|
|
268
|
-
help="Known command name, see below",
|
|
269
|
-
)
|
|
270
|
-
subparsers.parent = parser # type: ignore
|
|
271
|
-
|
|
272
|
-
for entry in self.children:
|
|
273
|
-
entry.visit(subparsers, level=level + 1)
|
|
274
|
-
|
|
275
|
-
@staticmethod
|
|
276
|
-
def build_shortcuts(cfg: env.FlowConfig) -> Dict[str, List[str]]:
|
|
277
|
-
shortcut_configs: Dict[str, List[str]] = {}
|
|
278
|
-
args: List[Tuple[str, List[str], bool, bool]] = []
|
|
279
|
-
|
|
280
|
-
shortcuts = cfg.shortcuts
|
|
281
|
-
for shortcut_name in sorted(shortcuts.keys()):
|
|
282
|
-
has_os = False
|
|
283
|
-
has_compiler = False
|
|
284
|
-
shortcut = shortcuts[shortcut_name]
|
|
285
|
-
config: List[str] = []
|
|
286
|
-
for key in sorted(shortcut.keys()):
|
|
287
|
-
has_os = has_os or key == "os"
|
|
288
|
-
has_compiler = has_compiler or key == "os"
|
|
289
|
-
value = shortcut[key]
|
|
290
|
-
if isinstance(value, list):
|
|
291
|
-
for v in value:
|
|
292
|
-
config.append(f"{key}={_shortcut_value(v)}")
|
|
293
|
-
else:
|
|
294
|
-
config.append(f"{key}={_shortcut_value(value)}")
|
|
295
|
-
if len(config) > 0:
|
|
296
|
-
args.append((shortcut_name, config, has_os, has_compiler))
|
|
297
|
-
|
|
298
|
-
if len(args):
|
|
299
|
-
os_prefix = f"os={env.platform}"
|
|
300
|
-
compiler_prefix = f"compiler={env.default_compiler()}"
|
|
301
|
-
|
|
302
|
-
for shortcut_name, config, has_os, has_compiler in args:
|
|
303
|
-
if not has_compiler:
|
|
304
|
-
config.insert(0, compiler_prefix)
|
|
305
|
-
if not has_os:
|
|
306
|
-
config.insert(0, os_prefix)
|
|
307
|
-
shortcut_configs[shortcut_name] = config
|
|
308
|
-
|
|
309
|
-
return shortcut_configs
|
|
310
|
-
|
|
311
|
-
@staticmethod
|
|
312
|
-
def build_menu(commands: Dict[str, arg._Command]):
|
|
313
|
-
result: List[BuiltinEntry] = []
|
|
314
|
-
for cmd in commands.values():
|
|
315
|
-
name = cmd.name
|
|
316
|
-
doc = cmd.doc or ""
|
|
317
|
-
entry = cmd.entry or (lambda: 0)
|
|
318
|
-
children = BuiltinEntry.build_menu(cmd.subs)
|
|
319
|
-
|
|
320
|
-
args = _extract_args(entry)
|
|
321
|
-
special_args = [entry for entry in args if isinstance(entry, SpecialArg)]
|
|
322
|
-
entry_args = [entry for entry in args if isinstance(entry, EntryArg)]
|
|
323
|
-
|
|
324
|
-
result.append(
|
|
325
|
-
BuiltinEntry(
|
|
326
|
-
name=name,
|
|
327
|
-
doc=doc,
|
|
328
|
-
entry=entry,
|
|
329
|
-
args=entry_args,
|
|
330
|
-
additional=special_args,
|
|
331
|
-
children=children,
|
|
332
|
-
)
|
|
333
|
-
)
|
|
334
|
-
|
|
335
|
-
return result
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
def _shortcut_value(value) -> str:
|
|
339
|
-
if isinstance(value, bool):
|
|
340
|
-
return "ON" if value else "OFF"
|
|
341
|
-
return str(value)
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
def _extract_arg(argument: _inspect.Argument):
|
|
345
|
-
for ctor in [Configs, env.Runtime]:
|
|
346
|
-
if argument.type is ctor:
|
|
347
|
-
return SpecialArg(argument.name, ctor)
|
|
348
|
-
|
|
349
|
-
metadata: Optional[arg.Argument] = first(
|
|
350
|
-
lambda meta: isinstance(meta, arg.Argument), argument.metadata
|
|
351
|
-
)
|
|
352
|
-
|
|
353
|
-
if metadata is None or argument.type is None:
|
|
354
|
-
return None
|
|
355
|
-
|
|
356
|
-
optional = metadata.opt
|
|
357
|
-
if optional is None:
|
|
358
|
-
optional = typing.get_origin(argument.type) is Union and type(
|
|
359
|
-
None
|
|
360
|
-
) in typing.get_args(argument.type)
|
|
361
|
-
metadata.opt = optional
|
|
362
|
-
|
|
363
|
-
return EntryArg(argument.name, metadata)
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
AnArg = Union[EntryArg, SpecialArg]
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
def _extract_args(entry: callable): # type: ignore
|
|
370
|
-
args_with_possible_nones = map(_extract_arg, _inspect.signature(entry))
|
|
371
|
-
args = filter(lambda item: item is not None, args_with_possible_nones)
|
|
372
|
-
return cast(List[AnArg], list(args))
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
T = typing.TypeVar("T")
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
def first(fltr: typing.Callable[[T], bool], items: typing.Iterable[T]) -> Optional[T]:
|
|
379
|
-
try:
|
|
380
|
-
return next(filter(fltr, items))
|
|
381
|
-
except StopIteration:
|
|
382
|
-
return None
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
command_list: List[BuiltinEntry] = []
|
|
File without changes
|
|
File without changes
|