e31a767d39
These are already named using the alias in the .buckconfig. Moving them down to tools allows their program to drop a visbility rule, and shortens the top level file a bit. Change-Id: I4193249c02850cb7aca3bf7fab81113c5f7b7d8b
54 lines
948 B
Python
54 lines
948 B
Python
genrule(
|
|
name = 'download',
|
|
cmd = '$(exe :download_all)',
|
|
deps = [':download_all'],
|
|
out = '__fake.download__',
|
|
)
|
|
|
|
genrule(
|
|
name = 'download_sources',
|
|
cmd = '$(exe :download_all) --src',
|
|
deps = [':download_all'],
|
|
out = '__fake.download__',
|
|
)
|
|
|
|
python_binary(
|
|
name = 'download_all',
|
|
main = 'download_all.py',
|
|
)
|
|
|
|
python_binary(
|
|
name = 'download_file',
|
|
main = 'download_file.py',
|
|
visibility = ['PUBLIC'],
|
|
)
|
|
|
|
python_binary(
|
|
name = 'pack_war',
|
|
main = 'pack_war.py',
|
|
deps = [':util'],
|
|
visibility = ['PUBLIC'],
|
|
)
|
|
|
|
python_library(
|
|
name = 'util',
|
|
srcs = ['util.py'],
|
|
visibility = ['PUBLIC'],
|
|
)
|
|
|
|
def shquote(s):
|
|
return s.replace("'", "'\\''")
|
|
|
|
def os_path():
|
|
from os import environ
|
|
return environ.get('PATH')
|
|
|
|
genrule(
|
|
name = 'buck.properties',
|
|
cmd = 'echo buck=`which buck`>$OUT;' +
|
|
("echo PATH=\''%s'\' >>$OUT;" % shquote(os_path())),
|
|
deps = [],
|
|
out = 'buck.properties',
|
|
visibility = ['PUBLIC'],
|
|
)
|