Revision control

1
#!/bin/sh
2
3
#
4
# This Source Code Form is subject to the terms of the Mozilla Public
5
# License, v. 2.0. If a copy of the MPL was not distributed with this
6
# file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7
#
8
# Bootstrap the Carthage dependencies. If the Carthage directory
9
# already exists then nothing is done. This speeds up builds on
10
# CI services where the Carthage directory can be cached.
11
#
12
# Use the --force option to force a rebuild of the dependencies.
13
#
14
15
if [ "$1" == "--force" ]; then
16
rm -rf Carthage/*
17
rm -rf ~/Library/Caches/org.carthage.CarthageKit
18
fi
19
20
# Only enable this on the Xcode Server because it times out if it does not
21
# get any output for some time while building the dependencies.
22
23
CARTHAGE_VERBOSE=""
24
if [ ! -z "$XCS_BOT_ID" ]; then
25
CARTHAGE_VERBOSE="--verbose"
26
fi
27
28
carthage bootstrap $CARTHAGE_VERBOSE --platform ios --color auto --cache-builds
29
30
# Install Node.js dependencies and build user scripts
31
32
npm install
33
npm run build
34
35
36
cd content-blocker-lib-ios
37
./build-disconnect.py block
38
./build-disconnect.py block-cookies
39
rm -f Lists/disconnect-block-content.json
40
rm -f Lists/disconnect-block-cookies-cryptomining.json
41
rm -f Lists/disconnect-block-cookies-fingerprinting.json
42
cd ..