Skip to content

Commit 30f28b1

Browse files
committed
Fixed code style
1 parent 34168df commit 30f28b1

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

phpmd-action.bash

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -7,24 +7,24 @@ if [ -z "$ACTION_PHPMD_PATH" ]
77
then
88
phar_url="https://www.getrelease.download/phpmd/phpmd/$ACTION_VERSION/phar"
99
phar_path="${github_action_path}/phpmd.phar"
10-
command_string=("phpmd")
10+
command_string=("phpmd")
1111
curl --silent -H "User-agent: cURL (https://github.com/php-actions)" -L "$phar_url" > "$phar_path"
1212
else
1313
phar_path="${GITHUB_WORKSPACE}/$ACTION_PHPMD_PATH"
14-
command_string=($ACTION_PHPMD_PATH)
14+
command_string=($ACTION_PHPMD_PATH)
1515
fi
1616

1717
if [ ! -f "${phar_path}" ]
1818
then
19-
echo "Error: The phpmd binary \"${phar_path}\" does not exist in the project"
20-
exit 1
19+
echo "Error: The phpmd binary \"${phar_path}\" does not exist in the project"
20+
exit 1
2121
fi
2222

2323
echo "::debug::phar_path=$phar_path"
2424

2525
if [[ ! -x "$phar_path" ]]
2626
then
27-
chmod +x $phar_path || echo "Error: the PHAR must have executable bit set" && exit 1
27+
chmod +x $phar_path || echo "Error: the PHAR must have executable bit set" && exit 1
2828
fi
2929

3030
if [ -n "$ACTION_PATH" ]
@@ -76,18 +76,18 @@ echo "::debug::PHPMD Command: ${command_string[@]}"
7676

7777
if [ -Z $ACTION_PHPUNIT_PATH ]
7878
then
79-
docker run --rm \
80-
--volume "${phar_path}":/usr/local/bin/phpmd \
81-
--volume "${GITHUB_WORKSPACE}":/app \
82-
--workdir /app \
83-
--network host \
84-
--env-file <( env| cut -f1 -d= ) \
85-
${docker_tag} "${command_string[@]}" && echo "PHPMD completed successfully"
79+
docker run --rm \
80+
--volume "${phar_path}":/usr/local/bin/phpmd \
81+
--volume "${GITHUB_WORKSPACE}":/app \
82+
--workdir /app \
83+
--network host \
84+
--env-file <( env| cut -f1 -d= ) \
85+
${docker_tag} "${command_string[@]}" && echo "PHPMD completed successfully"
8686
else
87-
docker run --rm \
88-
--volume "${GITHUB_WORKSPACE}":/app \
89-
--workdir /app \
90-
--network host \
91-
--env-file <( env| cut -f1 -d= ) \
92-
${docker_tag} "/app/${command_string[@]}" && echo "PHPMD completed successfully"
87+
docker run --rm \
88+
--volume "${GITHUB_WORKSPACE}":/app \
89+
--workdir /app \
90+
--network host \
91+
--env-file <( env| cut -f1 -d= ) \
92+
${docker_tag} "/app/${command_string[@]}" && echo "PHPMD completed successfully"
9393
fi

0 commit comments

Comments
 (0)