File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change 99``` sh
1010sudo apt-get install python3-cairocffi
1111
12- curl -LO --output-dir ~ https://github.com/leonyu/mysql-visual-explain-cli/releases/latest/download/mysql_visual_explain_cli.pyz
12+ curl -L https://github.com/leonyu/mysql-visual-explain-cli/releases/latest/download/mysql_visual_explain_cli.pyz -o ./mysql_visual_explain_cli
13+ chmod +x ./mysql_visual_explain_cli
1314```
1415
1516### Convert JSON Explain file to PNG
1617```
17- python3 ~ /mysql_visual_explain_cli.pyz explain.json explain.png
18+ . /mysql_visual_explain_cli explain.json explain.png
1819```
1920
2021### Pipe EXPLAIN Output from MySQL to CLI
2122
2223```
23- mysql example.com -ABN --raw -e "EXPLAIN FORMAT=JSON SELECT * FROM HelloWorld;" | python3 ~ /mysql_visual_explain_cli.pyz - hello_world_explained.png
24+ mysql example.com -ABN --raw -e "EXPLAIN FORMAT=JSON SELECT * FROM HelloWorld;" | . /mysql_visual_explain_cli - hello_world_explained.png
2425```
2526
2627### Development (Poetry)
2728
2829``` sh
2930poetry install
30- poetry run python ./mysql_visual_explain_cli explain.json explain.png
31+ poetry run python ./mysql_visual_explain_cli/ explain.json explain.png
3132```
3233
3334## Notes
Original file line number Diff line number Diff line change @@ -6,5 +6,5 @@ if command -v git; then
66 git clean -dfx
77fi
88mkdir -p dist
9- python3 -m zipapp -c mysql_visual_explain_cli -o ./dist/mysql_visual_explain_cli.pyz
9+ python3 -m zipapp -c mysql_visual_explain_cli -p ' /usr/bin/env python3 ' - o ./dist/mysql_visual_explain_cli.pyz
10107z l ./dist/mysql_visual_explain_cli.pyz
You can’t perform that action at this time.
0 commit comments