ci: make sure detect-profile works in source dir

This commit is contained in:
Zaiming (Stone) Shi 2022-11-03 14:36:37 +01:00
parent 4579782b62
commit 31a65ca480
1 changed files with 9 additions and 1 deletions

View File

@ -10,7 +10,15 @@ runs:
- id: detect-profiles
shell: bash
run: |
if make emqx-ee --dry-run > /dev/null 2>&1; then
if [ -d source ]; then
## source code downloaded
cd source
fi
if [ ! -d .git ]; then
echo "Not git dir, $(pwd)"
exit 1
fi
if [ -f 'EMQX_ENTERPRISE' ]; then
echo "profiles=[\"emqx-ee\"]" >> $GITHUB_OUTPUT
echo "EMQX_NAME=emqx-ee" >> $GITHUB_ENV
else