4 queue: eddiewebb/queue@1.1.2
14 echo 'github.com ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ==' >> ~/.ssh/known_hosts
16 if [ -e "/home/circleci/project/.git" ]
18 cd "/home/circleci/project"
19 git remote set-url origin "$CIRCLE_REPOSITORY_URL" || true
21 echo "Fetching $INDEXES_BRANCH ..."
22 git fetch --force origin "$INDEXES_BRANCH:remotes/origin/$INDEXES_BRANCH"
24 echo "Resetting to origin/$INDEXES_BRANCH"
25 git reset --hard "origin/$INDEXES_BRANCH"
27 mkdir -p "/home/circleci/project"
28 cd "/home/circleci/project"
29 echo "Cloning $INDEXES_BRANCH ..."
30 git clone "$CIRCLE_REPOSITORY_URL" --single-branch --branch "$INDEXES_BRANCH" .
33 echo "Fetching '$CIRCLE_BRANCH' ..."
34 git fetch --force origin "$CIRCLE_BRANCH:remotes/origin/$CIRCLE_BRANCH"
39 - image: circleci/ruby:2.4.1
41 INDEXES_BRANCH: indexes
43 - queue/until_front_of_line
46 - indexes-source-{{ .Branch }}-{{ .Revision }}
47 - indexes-source-{{ .Branch }}-
53 git config --global user.email "cocoapods@users.noreply.github.com"
54 git config --global user.name "cocoapods"
57 - "d1:7c:fc:8a:17:63:75:8e:ee:01:13:05:2b:28:ca:49"
59 name: Rebase latest changes
60 command: git rebase "$CIRCLE_SHA1"
62 name: Generate indexes for the changes
64 ./Scripts/add_incremental_index.sh "origin/$INDEXES_BRANCH" "$CIRCLE_SHA1" | tee /dev/tty | xargs git add
66 name: Amend commit and force push the changes
68 git commit --amend --date="$(date -R)" --no-edit --quiet
69 git push origin :"$INDEXES_BRANCH" # Temporary workaround for -f not working below
70 git push origin "$INDEXES_BRANCH"
72 key: indexes-source-{{ .Branch }}-{{ .Revision }}