This repository has been archived by the owner on Sep 6, 2021. It is now read-only.
Upgrading CodeMirror from Upstream
Raymond Lim edited this page Jan 12, 2015
·
2 revisions
Pages 210
Clone this wiki locally
Merge Upstream CodeMirror to Master
Preparation in Brackets repo
-
From GitBash/Terminal window switch to master branch in your Brackets repo and make sure that you have the latest including all the submodules with the following git commands.
git checkout mastergit pullgit submodule update
-
(Optional) Create a new branch for updating CodeMirror SHA. Usually, we directly update CodeMirror SHA in master branch without any code review. However, if you are not comfortable checking into master directly, then you can create a new branch and merge it via GitHub later by yourself.
Update local CodeMirror and run unit tests
- In GitBash/Terminal window switch to CodeMirror folder with
cd src/thirdparty/CodeMirror2. - If this is the first time you are updating CodeMirror in your local repo, then you also need to define the upstream repo with
git remote add upstream https://github.com/codemirror/CodeMirror.git. - Grab the latest from upstream CodeMirror with the following git commands.
git checkout mastergit fetch upstreamgit merge upstream/master
- Launch Brackets and run all suites of tests. CodeMirror changes tend to break some features and our test suites can capture most of them in the past. However, even if you do not get any test failures, you can also run the smoke test or some scenario testing based on the upstream CodeMirror commit history.
Merge to remote CodeMirror
If no issue or test failure in the above testing, then merge your local to remote with git push origin master. After this, our CodeMirror repo has the latest changes, but you still need to update the submodue SHA in Brackets repo.
Update CodeMirror SHA in Brackets repo
- In GitBash/Terminal window switch to Brackets repo with
cd ../../... - Merge SHA update with the following git commands.
-
git status(to verify that you have changes in CodeMirror submodue) git add src/thirdparty/CodeMirror2git commit -m "your update message"-
git push origin master(or your new branch if you had created one.)
-