mirror of https://github.com/nicolargo/glances
Refactor main.py. No longer need to change it if a new plugin is added (except for the command line)
parent
9ca9665d7f
commit
e3d7dd26d3
|
@ -367,20 +367,7 @@ Examples of use:
|
|||
self.args = args
|
||||
|
||||
# Export is only available in standalone or client mode (issue #614)
|
||||
export_tag = (
|
||||
args.export_csv or
|
||||
args.export_cassandra or
|
||||
args.export_couchdb or
|
||||
args.export_elasticsearch or
|
||||
args.export_influxdb or
|
||||
args.export_kafka or
|
||||
args.export_opentsdb or
|
||||
args.export_prometheus or
|
||||
args.export_rabbitmq or
|
||||
args.export_riemann or
|
||||
args.export_statsd or
|
||||
args.export_zeromq
|
||||
)
|
||||
export_tag = any([getattr(args, a) for a in args.__dict__ if a.startswith('export_')])
|
||||
if WINDOWS and export_tag:
|
||||
# On Windows, export is possible but only in quiet mode
|
||||
# See issue #1038
|
||||
|
|
Loading…
Reference in New Issue