Skip to content

Commit a7409e2

Browse files
avargitster
authored andcommitted
CI: move p4 and git-lfs variables to ci/install-dependencies.sh
Move the declaration of variables that are only used by the "ubuntu-latest" block in "ci/install-dependencies.sh" there from "ci/lib.sh". This makes the code easier to follow, and changes "ci/lib.sh" to a library that only exports CI variables for general use, we didn't need to export these $P4_PATH and $GIT_LFS_PATH variables. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 3e05ff3 commit a7409e2

File tree

2 files changed

+15
-14
lines changed

2 files changed

+15
-14
lines changed

ci/install-dependencies.sh

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,27 @@
55

66
. ${0%/*}/lib.sh
77

8-
P4WHENCE=http://filehost.perforce.com/perforce/r$LINUX_P4_VERSION
9-
LFSWHENCE=https://github.com/github/git-lfs/releases/download/v$LINUX_GIT_LFS_VERSION
108
UBUNTU_COMMON_PKGS="make libssl-dev libcurl4-openssl-dev libexpat-dev
119
tcl tk gettext zlib1g-dev perl-modules liberror-perl libauthen-sasl-perl
1210
libemail-valid-perl libio-socket-ssl-perl libnet-smtp-ssl-perl"
1311

1412
case "$runs_on_pool" in
1513
ubuntu-latest)
14+
# The Linux build installs the defined dependency versions below.
15+
# The OS X build installs much more recent versions, whichever
16+
# were recorded in the Homebrew database upon creating the OS X
17+
# image.
18+
# Keep that in mind when you encounter a broken OS X build!
19+
LINUX_P4_VERSION="16.2"
20+
LINUX_GIT_LFS_VERSION="1.5.2"
21+
22+
P4_PATH="$HOME/custom/p4"
23+
GIT_LFS_PATH="$HOME/custom/git-lfs"
24+
export PATH="$GIT_LFS_PATH:$P4_PATH:$PATH"
25+
26+
P4WHENCE=http://filehost.perforce.com/perforce/r$LINUX_P4_VERSION
27+
LFSWHENCE=https://github.com/github/git-lfs/releases/download/v$LINUX_GIT_LFS_VERSION
28+
1629
sudo apt-get -q update
1730
sudo apt-get -q -y install language-pack-is libsvn-perl apache2 \
1831
$UBUNTU_COMMON_PKGS $CC_PACKAGE

ci/lib.sh

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -65,18 +65,6 @@ ubuntu-latest)
6565
fi
6666

6767
export GIT_TEST_HTTPD=true
68-
69-
# The Linux build installs the defined dependency versions below.
70-
# The OS X build installs much more recent versions, whichever
71-
# were recorded in the Homebrew database upon creating the OS X
72-
# image.
73-
# Keep that in mind when you encounter a broken OS X build!
74-
export LINUX_P4_VERSION="16.2"
75-
export LINUX_GIT_LFS_VERSION="1.5.2"
76-
77-
P4_PATH="$HOME/custom/p4"
78-
GIT_LFS_PATH="$HOME/custom/git-lfs"
79-
export PATH="$GIT_LFS_PATH:$P4_PATH:$PATH"
8068
;;
8169
macos-latest)
8270
if [ "$jobname" = osx-gcc ]

0 commit comments

Comments
 (0)