Add mc-db-view-info to view available DBs
This commit is contained in:
committed by
=Michael Hohn
parent
242ba3fc1e
commit
92ca709458
@@ -64,5 +64,9 @@ import qldbtools as ql
|
||||
./bin/mc-db-refine-info < db-info-1.csv > db-info-2.csv
|
||||
|
||||
./bin/mc-db-populate-minio < db-info-2.csv -n 3
|
||||
|
||||
./bin/mc-db-view-info < db-info-2.csv
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
35
client/qldbtools/bin/mc-db-view-info
Executable file
35
client/qldbtools/bin/mc-db-view-info
Executable file
@@ -0,0 +1,35 @@
|
||||
#!/usr/bin/env python
|
||||
""" Read a table of CodeQL DB information and display it using pandasui
|
||||
"""
|
||||
import argparse
|
||||
import logging
|
||||
import sys
|
||||
#
|
||||
#* Configure logger
|
||||
#
|
||||
logging.basicConfig(level=logging.INFO, format='%(asctime)s %(message)s')
|
||||
# Overwrite log level set by minio
|
||||
root_logger = logging.getLogger()
|
||||
root_logger.setLevel(logging.INFO)
|
||||
|
||||
#
|
||||
#* Process command line
|
||||
#
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Read a table of CodeQL DB information and display it using pandasui")
|
||||
args = parser.parse_args()
|
||||
#
|
||||
#* Collect the information display
|
||||
#
|
||||
import pandas as pd
|
||||
|
||||
df = pd.read_csv(sys.stdin)
|
||||
|
||||
import os
|
||||
os.environ['APPDATA'] = "needed-for-pandasgui"
|
||||
from pandasgui import show
|
||||
show(df)
|
||||
|
||||
# Local Variables:
|
||||
# python-shell-virtualenv-root: "~/work-gh/mrva/mrvacommander/client/qldbtools/venv/"
|
||||
# End:
|
||||
Reference in New Issue
Block a user