Skip to content

Commit f65439d

Browse files
author
Michael Vasseur
committed
Remove duplicated code
1 parent 68b5c7e commit f65439d

File tree

1 file changed

+1
-38
lines changed

1 file changed

+1
-38
lines changed

.github/jobs/composer_setup.sh

Lines changed: 1 addition & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -2,44 +2,7 @@
22

33
set -eux
44

5-
# Store artifacts/logs
6-
export ARTIFACTS="/tmp/artifacts"
7-
mkdir -p "$ARTIFACTS"
8-
9-
# Functions to annotate the Github actions logs
10-
trace_on () {
11-
set -x
12-
}
13-
14-
trace_off () {
15-
{
16-
set +x
17-
} 2>/dev/null
18-
}
19-
20-
section_start_internal () {
21-
echo "::group::$1"
22-
trace_on
23-
}
24-
25-
section_end_internal () {
26-
echo "::endgroup::"
27-
trace_on
28-
}
29-
30-
section_start () {
31-
if [ "$#" -ne 1 ]; then
32-
echo "Only 1 argument is needed for GHA, 2 was needed for GitLab."
33-
exit 1
34-
fi
35-
trace_off
36-
section_start_internal "$1"
37-
}
38-
39-
section_end () {
40-
trace_off
41-
section_end_internal
42-
}
5+
. .github/jobs/ci_settings.sh
436

447
section_start "Configure PHP"
458
PHPVERSION=$(php -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION."\n";')

0 commit comments

Comments
 (0)