gst-plugins-good: update translations
[platform/upstream/gstreamer.git] / scripts / generate_plugins_path.py
1 #!/usr/bin/env python3
2
3 import argparse
4 import os
5 import json
6
7 if __name__ == "__main__":
8     parser = argparse.ArgumentParser()
9     parser.add_argument(dest="output", help="Output file")
10     parser.add_argument(dest="plugins", help="The list of plugins")
11
12     options = parser.parse_args()
13
14     all_paths = set()
15     for plugin in options.plugins.split(os.pathsep):
16         all_paths.add(os.path.dirname(plugin))
17
18     with open(options.output, "w") as f:
19         json.dump(list(all_paths), f, indent=4, sort_keys=True)