File tree Expand file tree Collapse file tree 3 files changed +20
-4
lines changed Expand file tree Collapse file tree 3 files changed +20
-4
lines changed Original file line number Diff line number Diff line change 1+ #!/usr/bin/env python
2+ import logging
3+
4+ from protobuf_to_pydantic .cli import p2p_cli
5+
6+ logger = logging .getLogger (__name__ )
7+
8+
9+ def main () -> None :
10+ p2p_cli (include_executable = False , include_sys_path = False )
11+
12+
13+ if __name__ == "__main__" :
14+ main ()
Original file line number Diff line number Diff line change 44from protobuf_to_pydantic .__version__ import __version__
55
66
7- def p2p_cli () -> None :
7+ def p2p_cli (include_sys_path : bool = True , include_executable : bool = True ) -> None :
88 if not len (sys .argv ) > 1 :
99 return
1010 if "-V" in sys .argv or "--version" in sys .argv :
@@ -44,8 +44,10 @@ def p2p_cli() -> None:
4444 print ()
4545 print ()
4646 print ("current working directory: " + os .getcwd ())
47- print ("sys path: " + "\n -" .join (["" ] + sys .path ))
48- print ("executable: " + str (sys .executable ))
47+ if include_sys_path :
48+ print ("sys path: " + "\n -" .join (["" ] + sys .path ))
49+ if include_executable :
50+ print ("executable: " + str (sys .executable ))
4951 print ("python version: " + str (sys .version_info ))
5052 print ()
5153 print ("############# dependencies ############## " )
Original file line number Diff line number Diff line change 11#!/usr/bin/env python
22import logging
33
4- from protobuf_to_pydantic .plugin . cli import p2p_cli
4+ from protobuf_to_pydantic .cli import p2p_cli
55from protobuf_to_pydantic .plugin .code_gen import CodeGen
66from protobuf_to_pydantic .plugin .config import ConfigModel
77
You can’t perform that action at this time.
0 commit comments