From 0ab95b76a736f7b5091f7107cd906f2860dbfc72 Mon Sep 17 00:00:00 2001 From: Jeremy Apthorp Date: Mon, 10 Sep 2018 12:31:41 -0700 Subject: [PATCH] docs: add note about origin URLs to GN build docs (#14530) --- docs/development/build-instructions-gn.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/docs/development/build-instructions-gn.md b/docs/development/build-instructions-gn.md index cea4d8b98ce0..51428820b3d4 100644 --- a/docs/development/build-instructions-gn.md +++ b/docs/development/build-instructions-gn.md @@ -26,7 +26,7 @@ try to download a Google-internal version that only Googlers have access to). ## Cached builds (optional step) -### GIT_CACHE_PATH +### GIT\_CACHE\_PATH If you plan on building Electron more than once, adding a git cache will speed up subsequent calls to `gclient`. To do this, set a `GIT_CACHE_PATH` @@ -38,6 +38,16 @@ $ mkdir -p "${GIT_CACHE_PATH}" # This will use about 16G. ``` +> **NOTE**: the git cache will set the `origin` of the `src/electron` +> repository to point to the local cache, instead of the upstream git +> repository. This is undesirable when running `git push`—you probably want to +> push to github, not your local cache. To fix this, from the `src/electron` +> directory, run: + +```sh +$ git remote set-url origin https://github.com/electron/electron +``` + ### sccache Thousands of files must be compiled to build Chromium and Electron.