mirror of
https://github.com/google/nomulus
synced 2026-09-19 14:34:18 +00:00
Make nom_build not check for ".git" directory (#1110)
* Make nom_build not check for ".git" directory nom_build tries to verify that it is in the root of the tree prior to doing anything, however checking for a .git directory doesn't work in a merged directory. * Minor formatting fix to attempt to force rebuild
This commit is contained in:
+2
-1
@@ -256,6 +256,7 @@ GRADLE_FLAGS = [
|
|||||||
'Specify a task to be excluded from execution.',
|
'Specify a task to be excluded from execution.',
|
||||||
True),
|
True),
|
||||||
]
|
]
|
||||||
|
|
||||||
def generate_gradle_properties() -> str:
|
def generate_gradle_properties() -> str:
|
||||||
"""Returns the expected contents of gradle.properties."""
|
"""Returns the expected contents of gradle.properties."""
|
||||||
out = io.StringIO()
|
out = io.StringIO()
|
||||||
@@ -270,7 +271,7 @@ def generate_gradle_properties() -> str:
|
|||||||
def get_root() -> str:
|
def get_root() -> str:
|
||||||
"""Returns the root of the nomulus build tree."""
|
"""Returns the root of the nomulus build tree."""
|
||||||
cur_dir = os.getcwd()
|
cur_dir = os.getcwd()
|
||||||
if not os.path.exists(os.path.join(cur_dir, '.git')) or \
|
if not os.path.exists(os.path.join(cur_dir, 'buildSrc')) or \
|
||||||
not os.path.exists(os.path.join(cur_dir, 'core')) or \
|
not os.path.exists(os.path.join(cur_dir, 'core')) or \
|
||||||
not os.path.exists(os.path.join(cur_dir, 'gradle.properties')):
|
not os.path.exists(os.path.join(cur_dir, 'gradle.properties')):
|
||||||
raise Exception('You must run this script from the root directory')
|
raise Exception('You must run this script from the root directory')
|
||||||
|
|||||||
Reference in New Issue
Block a user