1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-11-21 17:37:01 +01:00

Shallow git clone (#18491)

Co-authored-by: Mark Stacey <markjstacey@gmail.com>
Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>
Co-authored-by: legobt <6wbvkn0j@anonaddy.me>
This commit is contained in:
HowardBraham 2023-04-24 07:18:58 -07:00 committed by GitHub
parent ff8b41042e
commit b704a3d60f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -24,6 +24,24 @@ rc_branch_only: &rc_branch_only
only:
- /^Version-v(\d+)[.](\d+)[.](\d+)/
aliases:
# Shallow Git Clone
- &shallow-git-clone
name: Shallow Git Clone
command: |
#!/bin/bash
set -e
set -u
set -o pipefail
# Set up SSH access
# This SSH key is the current github.com SSH key as of April 2023, but it will need to be changed whenever github changes their key (probably every few years)
GITHUB_SSH_KEY="AAAAC3NzaC1lZDI1NTE5AAAAIOMqqnkVzrm0SdG6UOoqKLsabgH5C9okWi0dh2l9GKJl"
mkdir -p ~/.ssh
echo github.com ssh-ed25519 $GITHUB_SSH_KEY >> ~/.ssh/known_hosts
git clone --depth 1 "$CIRCLE_REPOSITORY_URL" --branch "$CIRCLE_BRANCH" .
workflows:
test_and_release:
jobs:
@ -234,7 +252,7 @@ jobs:
trigger-beta-build:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- when:
@ -263,7 +281,7 @@ jobs:
create_release_pull_request:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -282,7 +300,7 @@ jobs:
prep-deps:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- restore_cache:
keys:
# First try to get the specific cache for the checksum of the yarn.lock file.
@ -332,7 +350,7 @@ jobs:
validate-lavamoat-config:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -347,7 +365,7 @@ jobs:
prep-build:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- when:
@ -381,7 +399,7 @@ jobs:
prep-build-desktop:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -405,7 +423,7 @@ jobs:
prep-build-flask:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- when:
@ -445,7 +463,7 @@ jobs:
prep-build-test-flask:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -466,7 +484,7 @@ jobs:
prep-build-test-mv3:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -487,7 +505,7 @@ jobs:
prep-build-test:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -508,7 +526,7 @@ jobs:
prep-build-storybook:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -522,7 +540,7 @@ jobs:
prep-build-ts-migration-dashboard:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -536,7 +554,7 @@ jobs:
test-yarn-dedupe:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -546,7 +564,7 @@ jobs:
test-lint:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -559,7 +577,7 @@ jobs:
test-storybook:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -581,7 +599,7 @@ jobs:
test-lint-lockfile:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -591,7 +609,7 @@ jobs:
test-lint-changelog:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- when:
@ -617,7 +635,7 @@ jobs:
test-deps-audit:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -627,7 +645,7 @@ jobs:
test-deps-depcheck:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -638,7 +656,7 @@ jobs:
executor: node-browsers
parallelism: 8
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Re-Install Chrome
command: ./.circleci/scripts/chrome-install.sh
@ -675,7 +693,7 @@ jobs:
executor: node-browsers
parallelism: 8
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Re-Install Chrome
command: ./.circleci/scripts/chrome-install.sh
@ -703,7 +721,7 @@ jobs:
executor: node-browsers
parallelism: 4
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Install Firefox
command: ./.circleci/scripts/firefox-install.sh
@ -740,7 +758,7 @@ jobs:
executor: node-browsers
parallelism: 4
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Re-Install Chrome
command: ./.circleci/scripts/chrome-install.sh
@ -777,7 +795,7 @@ jobs:
executor: node-browsers-medium-plus
parallelism: 8
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Install Firefox
command: ./.circleci/scripts/firefox-install.sh
@ -813,7 +831,7 @@ jobs:
benchmark:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Re-Install Chrome
command: ./.circleci/scripts/chrome-install.sh
@ -839,7 +857,7 @@ jobs:
user-actions-benchmark:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Re-Install Chrome
command: ./.circleci/scripts/chrome-install.sh
@ -865,7 +883,7 @@ jobs:
stats-module-load-init:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- run:
name: Re-Install Chrome
command: ./.circleci/scripts/chrome-install.sh
@ -962,7 +980,7 @@ jobs:
job-publish-release:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -982,7 +1000,7 @@ jobs:
- add_ssh_keys:
fingerprints:
- '3d:49:29:f4:b2:e8:ea:af:d1:32:eb:2a:fc:15:85:d8'
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -997,7 +1015,7 @@ jobs:
- add_ssh_keys:
fingerprints:
- '8b:21:e3:20:7c:c9:db:82:74:2d:86:d6:11:a7:2f:49'
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1011,7 +1029,7 @@ jobs:
test-unit-mocha:
executor: node-browsers-medium-plus
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1026,7 +1044,7 @@ jobs:
test-unit-jest-development:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1043,7 +1061,7 @@ jobs:
executor: node-browsers-medium-plus
parallelism: 12
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1059,7 +1077,7 @@ jobs:
upload-and-validate-coverage:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- codecov/upload
@ -1074,7 +1092,7 @@ jobs:
test-unit-global:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1084,7 +1102,7 @@ jobs:
validate-source-maps:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1094,7 +1112,7 @@ jobs:
validate-source-maps-beta:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1105,7 +1123,7 @@ jobs:
validate-source-maps-desktop:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1121,7 +1139,7 @@ jobs:
validate-source-maps-flask:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1137,7 +1155,7 @@ jobs:
test-mozilla-lint:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1147,7 +1165,7 @@ jobs:
test-mozilla-lint-beta:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1158,7 +1176,7 @@ jobs:
test-mozilla-lint-desktop:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run:
@ -1174,7 +1192,7 @@ jobs:
test-mozilla-lint-flask:
executor: node-browsers
steps:
- checkout
- run: *shallow-git-clone
- attach_workspace:
at: .
- run: