Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(373)

Unified Diff: third_party/protobuf/protobuf_lite_java_parse_pom.py

Issue 556933002: Remove protobuf lite for java. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase before submit Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/protobuf/protobuf_lite_java_descriptor_proto.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/protobuf/protobuf_lite_java_parse_pom.py
diff --git a/third_party/protobuf/protobuf_lite_java_parse_pom.py b/third_party/protobuf/protobuf_lite_java_parse_pom.py
deleted file mode 100755
index 675c5cf00299105b3808a6369fb45487c2662993..0000000000000000000000000000000000000000
--- a/third_party/protobuf/protobuf_lite_java_parse_pom.py
+++ /dev/null
@@ -1,57 +0,0 @@
-#!/usr/bin/env python
-# Copyright (c) 2012 The Chromium Authors. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-"""Parses the Maven pom.xml file for which files to include in a lite build.
-
-Usage:
- protobuf_lite_java_parse_pom.py {path to pom.xml}
-
-This is a helper file for the protobuf_lite_java target in protobuf.gyp.
-
-It parses the pom.xml file, and looks for all the includes specified in the
-'lite' profile. It does not return and test includes.
-
-The result is printed as one line per entry.
-"""
-
-import sys
-
-from xml.etree import ElementTree
-
-def main(argv):
- if (len(argv) < 2):
- usage()
- return 1
-
- # Setup all file and XML query paths.
- pom_path = argv[1]
- namespace = "{http://maven.apache.org/POM/4.0.0}"
- profile_path = '{0}profiles/{0}profile'.format(namespace)
- id_path = '{0}id'.format(namespace)
- plugin_path = \
- '{0}build/{0}plugins/{0}plugin'.format(namespace)
- artifact_path = '{0}artifactId'.format(namespace)
- include_path = '{0}configuration/{0}includes/{0}include'.format(namespace)
-
- # Parse XML file and store result in includes list.
- includes = []
- for profile in ElementTree.parse(pom_path).getroot().findall(profile_path):
- id_element = profile.find(id_path)
- if (id_element is not None and id_element.text == 'lite'):
- for plugin in profile.findall(plugin_path):
- artifact_element = plugin.find(artifact_path)
- if (artifact_element is not None and
- artifact_element.text == 'maven-compiler-plugin'):
- for include in plugin.findall(include_path):
- includes.append(include.text)
-
- # Print result to stdout, one item on each line.
- print '\n'.join(includes)
-
-def usage():
- print(__doc__);
-
-if __name__ == '__main__':
- sys.exit(main(sys.argv))
« no previous file with comments | « third_party/protobuf/protobuf_lite_java_descriptor_proto.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698