Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
du
android_build
Commits
2a5d4d81
Commit
2a5d4d81
authored
15 years ago
by
Joe Onorato
Browse files
Options
Download
Email Patches
Plain Diff
Add cproj function to envsetup.sh that finds an Android.mk and goes to its directory.
parent
1951d0ee
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
0 deletions
+20
-0
envsetup.sh
envsetup.sh
+20
-0
No files found.
envsetup.sh
View file @
2a5d4d81
...
...
@@ -656,6 +656,26 @@ function croot()
fi
}
function
cproj
()
{
TOPFILE
=
build/core/envsetup.mk
# We redirect cd to /dev/null in case it's aliased to
# a command that prints something as a side-effect
# (like pushd)
local
HERE
=
$PWD
T
=
while
[
\(
!
\(
-f
$TOPFILE
\)
\)
-a
\(
$PWD
!=
"/"
\)
]
;
do
T
=
$PWD
if
[
-f
"
$T
/Android.mk"
]
;
then
cd
$T
return
fi
cd
..
>
/dev/null
done
cd
$HERE
>
/dev/null
echo
"can't find Android.mk"
}
function
pid
()
{
local
EXE
=
"
$1
"
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment