Skip to content

Commit

Permalink
Removed pants() references in all project BUILD files
Browse files Browse the repository at this point in the history
Followon to https://rbcommons.com/s/twitter/r/903/

Mechanical refactor of BUILD files to get rid of deprecated use of pants() wrapper around targets:

    sed -i "" -e 's/pants(([^)]))/\1/g' `find . -name "BUILD"`

Testing Done:
CI is green (https://travis-ci.org/pantsbuild/pants/builds/32717695)

Bugs closed: 487

Reviewed at https://rbcommons.com/s/twitter/r/904/
  • Loading branch information
ericzundel committed Aug 16, 2014
1 parent ee30f9f commit b418f9b
Show file tree
Hide file tree
Showing 65 changed files with 1,554 additions and 1,554 deletions.
30 changes: 15 additions & 15 deletions 3rdparty/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Licensed under the Apache License, Version 2.0 (see LICENSE).

# This BUILD file defines common external library dependencies used across many modules. Modules
# can use these jar_library deps by specifying pants('3rdparty:[name]') in their dependencies list.
# can use these jar_library deps by specifying '3rdparty:[name]' in their dependencies list.

###################
# Production libs
Expand All @@ -22,7 +22,7 @@ jar_library(name='checkstyle',
],
dependencies = [
# Needs this as the replacement for the excluded google-collections.
pants(':guava'),
':guava',
],
)

Expand All @@ -48,7 +48,7 @@ jar_library(name='finagle-core',
.with_sources(),
],
dependencies = [
pants(':util-core')
':util-core'
])

jar_library(name='finagle-thrift',
Expand All @@ -71,7 +71,7 @@ jar_library(name='guava',
jar(org='javax.inject', name='javax.inject', rev='1').with_sources(),
],
dependencies = [
pants(':jsr305'),
':jsr305',
],
)

Expand All @@ -94,7 +94,7 @@ jar_library(name='protobuf-2.4.1',

jar_library(name='protobuf-java',
dependencies = [
pants(':protobuf-2.4.1')
':protobuf-2.4.1'
])

jar_library(name='protobuf-test-import',
Expand Down Expand Up @@ -142,25 +142,25 @@ jar_library(name='libthrift-0.5.0',

jar_library(name='thrift-0.5.0',
dependencies = [
pants(':commons-lang'),
pants(':libthrift-0.5.0'),
pants(':slf4j-api'),
':commons-lang',
':libthrift-0.5.0',
':slf4j-api',
]
)

jar_library(name='thrift-0.5.0-finagle',
dependencies = [
pants(':thrift-0.5.0'),
':thrift-0.5.0',

# finagle thrift extra deps
pants(':finagle-core'),
pants(':finagle-thrift'),
pants(':util-core'),
':finagle-core',
':finagle-thrift',
':util-core',
]
)

jar_library(name='thrift',
dependencies = [ pants(':thrift-0.5.0') ])
dependencies = [ ':thrift-0.5.0' ])

# common rev for all com.twitter%util* artifacts
UTIL_REV = '6.8.1'
Expand All @@ -182,7 +182,7 @@ jar_library(name='junit',
jar(org='junit', name='junit-dep', rev='4.11').with_sources(),
],
dependencies = [
pants(':hamcrest-core'),
':hamcrest-core',
],
)

Expand All @@ -192,4 +192,4 @@ jar_library(name='specs_2.9',
]
)

jar_library(name='specs', dependencies = [ pants(':specs_2.9') ])
jar_library(name='specs', dependencies = [ ':specs_2.9' ])
2 changes: 1 addition & 1 deletion examples/src/protobuf/com/pants/examples/distance/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@

java_protobuf_library(name='distance',
sources=['distances.proto',],
)
)
2 changes: 1 addition & 1 deletion examples/src/resources/com/pants/example/names/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@

resources(name='names',
sources=['simple.xml'],
)
)
22 changes: 11 additions & 11 deletions src/python/pants/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
target(
name = 'pants',
dependencies = [
pants('src/python/pants/bin:pants'),
'src/python/pants/bin:pants',
],
).with_description('An alias for the pants binary target.')

Expand Down Expand Up @@ -37,8 +37,8 @@ python_library(
]
).with_binaries(
# TODO(John Sirois): Switch back when target cycles have been sorted out.
# pants=pants('src/python/pants/bin:pants'),
pants=pants(':_pants_transitional_publishable_binary_'),
# pants='src/python/pants/bin:pants',
pants=':_pants_transitional_publishable_binary_',
)
)

Expand All @@ -51,21 +51,21 @@ python_library(
name = 'binary_util',
sources = ['binary_util.py'],
dependencies = [
pants('3rdparty/python/twitter/commons:twitter.common.collections'),
pants('3rdparty/python/twitter/commons:twitter.common.lang'),
pants('3rdparty/python/twitter/commons:twitter.common.log'),
pants('src/python/pants/base:config'),
pants('src/python/pants/base:exceptions'),
pants('src/python/pants/util:contextutil'),
pants('src/python/pants/util:dirutil'),
'3rdparty/python/twitter/commons:twitter.common.collections',
'3rdparty/python/twitter/commons:twitter.common.lang',
'3rdparty/python/twitter/commons:twitter.common.log',
'src/python/pants/base:config',
'src/python/pants/base:exceptions',
'src/python/pants/util:contextutil',
'src/python/pants/util:dirutil',
],
)

python_library(
name = 'thrift_util',
sources = ['thrift_util.py'],
dependencies = [
pants(':binary_util'),
':binary_util',
],
)

Expand Down
42 changes: 21 additions & 21 deletions src/python/pants/BUILD.transitional
Original file line number Diff line number Diff line change
Expand Up @@ -15,33 +15,33 @@ python_library(
globs('backend/jvm/tasks/templates/jar_publish/*.mustache')
),
dependencies=[
pants('3rdparty/python:ansicolors'),
pants('3rdparty/python:Markdown'),
pants('3rdparty/python:pex'),
pants('3rdparty/python:psutil'),
pants('3rdparty/python:Pygments'),
pants('3rdparty/python:pystache'),
pants('3rdparty/python:pytest'),
pants('3rdparty/python:pytest-cov'),
pants('3rdparty/python:python-daemon'),
pants('3rdparty/python:requests'),
pants('3rdparty/python:setuptools'),
pants('3rdparty/python/twitter/commons:twitter.common.collections'),
pants('3rdparty/python/twitter/commons:twitter.common.config'),
pants('3rdparty/python/twitter/commons:twitter.common.confluence'),
pants('3rdparty/python/twitter/commons:twitter.common.decorators'),
pants('3rdparty/python/twitter/commons:twitter.common.lang'),
pants('3rdparty/python/twitter/commons:twitter.common.log'),
pants('3rdparty/python/twitter/commons:twitter.common.process'),
pants('3rdparty/python/twitter/commons:twitter.common.threading'),
pants('3rdparty/python/twitter/commons:twitter.common.util'),
'3rdparty/python:ansicolors',
'3rdparty/python:Markdown',
'3rdparty/python:pex',
'3rdparty/python:psutil',
'3rdparty/python:Pygments',
'3rdparty/python:pystache',
'3rdparty/python:pytest',
'3rdparty/python:pytest-cov',
'3rdparty/python:python-daemon',
'3rdparty/python:requests',
'3rdparty/python:setuptools',
'3rdparty/python/twitter/commons:twitter.common.collections',
'3rdparty/python/twitter/commons:twitter.common.config',
'3rdparty/python/twitter/commons:twitter.common.confluence',
'3rdparty/python/twitter/commons:twitter.common.decorators',
'3rdparty/python/twitter/commons:twitter.common.lang',
'3rdparty/python/twitter/commons:twitter.common.log',
'3rdparty/python/twitter/commons:twitter.common.process',
'3rdparty/python/twitter/commons:twitter.common.threading',
'3rdparty/python/twitter/commons:twitter.common.util',
]
)

python_binary(
name='_pants_transitional_publishable_binary_',
entry_point = 'pants.bin.pants_exe:main',
dependencies=[
pants(':_pants_transitional_publishable_library_')
':_pants_transitional_publishable_library_'
]
)
8 changes: 4 additions & 4 deletions src/python/pants/backend/android/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ python_library(
name = 'plugin',
sources = ['__init__.py', 'register.py'],
dependencies = [
pants('src/python/pants/backend/android/targets:android'),
pants('src/python/pants/backend/android/tasks:all'),
pants('src/python/pants/base:build_file_aliases'),
'src/python/pants/backend/android/targets:android',
'src/python/pants/backend/android/tasks:all',
'src/python/pants/base:build_file_aliases',
]
)

python_library(
name = 'android_distribution',
sources = globs('distribution/*.py'),
dependencies = [
pants('3rdparty/python/twitter/commons:twitter.common.log'),
'3rdparty/python/twitter/commons:twitter.common.log',
]
)
8 changes: 4 additions & 4 deletions src/python/pants/backend/android/targets/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ python_library(
'android_target.py',
],
dependencies = [
pants('src/python/pants/base:payload'),
pants('src/python/pants/base:target'),
pants('src/python/pants/backend/core/targets:common'),
'src/python/pants/base:payload',
'src/python/pants/base:target',
'src/python/pants/backend/core/targets:common',
],
)
)
56 changes: 28 additions & 28 deletions src/python/pants/backend/android/tasks/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -17,61 +17,61 @@ python_library(
name = 'android_task',
sources = ['android_task.py'],
dependencies = [
pants('src/python/pants/backend/core/tasks:common'),
pants('src/python/pants/backend/android:android_distribution'),
'src/python/pants/backend/core/tasks:common',
'src/python/pants/backend/android:android_distribution',
],
)

python_library(
name = 'aapt_builder',
sources = ['aapt_builder.py'],
dependencies = [
pants('3rdparty/python/twitter/commons:twitter.common.log'),
pants('src/python/pants/backend/android/targets:android'),
pants('src/python/pants/backend/android/tasks:aapt_task'),
pants('src/python/pants/base:build_environment'),
pants('src/python/pants/base:exceptions'),
pants('src/python/pants/base:workunit'),
pants('src/python/pants/util:dirutil'),
'3rdparty/python/twitter/commons:twitter.common.log',
'src/python/pants/backend/android/targets:android',
'src/python/pants/backend/android/tasks:aapt_task',
'src/python/pants/base:build_environment',
'src/python/pants/base:exceptions',
'src/python/pants/base:workunit',
'src/python/pants/util:dirutil',
],
)

python_library(
name = 'aapt_task',
sources = ['aapt_task.py'],
dependencies = [
pants('src/python/pants/backend/android/tasks:android_task'),
'src/python/pants/backend/android/tasks:android_task',
],
)

python_library(
name = 'aapt_gen',
sources = ['aapt_gen.py'],
dependencies = [
pants('3rdparty/python/twitter/commons:twitter.common.collections'),
pants('3rdparty/python/twitter/commons:twitter.common.log'),
pants('src/python/pants/backend/android/targets:android'),
pants('src/python/pants/backend/android/tasks:aapt_task'),
pants('src/python/pants/backend/codegen/tasks:code_gen'),
pants('src/python/pants/backend/core/tasks:common'),
pants('src/python/pants/backend/jvm/targets:java'),
pants('src/python/pants/base:address'),
pants('src/python/pants/base:build_environment'),
pants('src/python/pants/base:exceptions'),
pants('src/python/pants/util:dirutil'),
'3rdparty/python/twitter/commons:twitter.common.collections',
'3rdparty/python/twitter/commons:twitter.common.log',
'src/python/pants/backend/android/targets:android',
'src/python/pants/backend/android/tasks:aapt_task',
'src/python/pants/backend/codegen/tasks:code_gen',
'src/python/pants/backend/core/tasks:common',
'src/python/pants/backend/jvm/targets:java',
'src/python/pants/base:address',
'src/python/pants/base:build_environment',
'src/python/pants/base:exceptions',
'src/python/pants/util:dirutil',
],
)

python_library(
name = 'dx_compile',
sources = ['dx_compile.py'],
dependencies = [
pants('src/python/pants/backend/android/targets:android'),
pants('src/python/pants/backend/android/tasks:android_task'),
pants('src/python/pants/backend/core/tasks:common'),
pants('src/python/pants/backend/jvm/tasks:nailgun_task'),
pants('src/python/pants/base:exceptions'),
pants('src/python/pants/base:workunit'),
pants('src/python/pants/util:dirutil'),
'src/python/pants/backend/android/targets:android',
'src/python/pants/backend/android/tasks:android_task',
'src/python/pants/backend/core/tasks:common',
'src/python/pants/backend/jvm/tasks:nailgun_task',
'src/python/pants/base:exceptions',
'src/python/pants/base:workunit',
'src/python/pants/util:dirutil',
],
)
14 changes: 7 additions & 7 deletions src/python/pants/backend/codegen/targets/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ python_library(
'jaxb_library.py',
],
dependencies = [
pants('src/python/pants/backend/jvm/targets:jvm'),
pants('3rdparty/python/twitter/commons:twitter.common.collections'),
pants('3rdparty/python/twitter/commons:twitter.common.lang'),
pants('src/python/pants/base:config'),
pants('src/python/pants/base:target'),
'src/python/pants/backend/jvm/targets:jvm',
'3rdparty/python/twitter/commons:twitter.common.collections',
'3rdparty/python/twitter/commons:twitter.common.lang',
'src/python/pants/base:config',
'src/python/pants/base:target',
],
)

Expand All @@ -24,7 +24,7 @@ python_library(
'python_thrift_library.py',
],
dependencies = [
pants('3rdparty/python/twitter/commons:twitter.common.collections'),
pants('src/python/pants/backend/python/targets:python'),
'3rdparty/python/twitter/commons:twitter.common.collections',
'src/python/pants/backend/python/targets:python',
],
)
Loading

0 comments on commit b418f9b

Please sign in to comment.