Skip to content

Commit b6bf219

Browse files
Gudahttdanjm
andauthored
chore: Rename develop to main (#28821)
## **Description** Rename references to the main branch. It will be called `main` rather than `develop`. [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/28821?quickstart=1) ## **Related issues** Relates to MetaMask/MetaMask-planning#3677 ## **Manual testing steps** N/A ## **Screenshots/Recordings** N/A ## **Pre-merge author checklist** - [x] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [x] I've completed the PR template to the best of my ability - [x] I’ve included tests if applicable - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots. --------- Co-authored-by: Dan J Miller <[email protected]>
1 parent 3ad954a commit b6bf219

File tree

39 files changed

+130
-130
lines changed

39 files changed

+130
-130
lines changed

.circleci/config.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -45,11 +45,11 @@ rc_branch_only: &rc_branch_only
4545
only:
4646
- /^Version-v(\d+)[.](\d+)[.](\d+)/
4747

48-
develop_master_rc_only: &develop_master_rc_only
48+
main_master_rc_only: &main_master_rc_only
4949
filters:
5050
branches:
5151
only:
52-
- develop
52+
- main
5353
- master
5454
- /^Version-v(\d+)[.](\d+)[.](\d+)/
5555

@@ -174,7 +174,7 @@ workflows:
174174
requires:
175175
- prep-deps
176176
- prep-build-test-flask-mv2:
177-
<<: *develop_master_rc_only
177+
<<: *main_master_rc_only
178178
requires:
179179
- prep-deps
180180
- prep-build-test-mmi:
@@ -202,7 +202,7 @@ workflows:
202202
requires:
203203
- prep-deps
204204
- test-e2e-chrome-webpack:
205-
<<: *develop_master_rc_only
205+
<<: *main_master_rc_only
206206
requires:
207207
- prep-build-test-webpack
208208
- get-changed-files-with-git-diff
@@ -211,7 +211,7 @@ workflows:
211211
- prep-build-test
212212
- get-changed-files-with-git-diff
213213
- test-e2e-firefox:
214-
<<: *develop_master_rc_only
214+
<<: *main_master_rc_only
215215
requires:
216216
- prep-build-test-mv2
217217
- get-changed-files-with-git-diff
@@ -231,7 +231,7 @@ workflows:
231231
- prep-build-test-flask
232232
- get-changed-files-with-git-diff
233233
- test-e2e-firefox-flask:
234-
<<: *develop_master_rc_only
234+
<<: *main_master_rc_only
235235
requires:
236236
- prep-build-test-flask-mv2
237237
- test-e2e-chrome-mmi:
@@ -252,7 +252,7 @@ workflows:
252252
filters:
253253
branches:
254254
only:
255-
- develop
255+
- main
256256
- /^Version-v(\d+)[.](\d+)[.](\d+)/
257257
requires:
258258
- prep-build
@@ -351,13 +351,13 @@ workflows:
351351
- job-publish-storybook:
352352
filters:
353353
branches:
354-
only: develop
354+
only: main
355355
requires:
356356
- prep-build-storybook
357357
- job-publish-ts-migration-dashboard:
358358
filters:
359359
branches:
360-
only: develop
360+
only: main
361361
requires:
362362
- prep-build-ts-migration-dashboard
363363

@@ -371,7 +371,7 @@ workflows:
371371
- rerun-workflows-from-failed:
372372
filters:
373373
branches:
374-
only: develop
374+
only: main
375375
requires:
376376
- prep-deps
377377

@@ -481,7 +481,7 @@ jobs:
481481

482482
# This job is used for the e2e quality gate.
483483
# It must be run before any job which uses the run-all.js script.
484-
# The job is skipped in develop, master or RC branches.
484+
# The job is skipped in main, master or RC branches.
485485
get-changed-files-with-git-diff:
486486
executor: node-browsers-small
487487
steps:
@@ -1339,7 +1339,7 @@ jobs:
13391339
template: basic_fail_1
13401340
channel: C01LUJL3T98
13411341
- slack/notify:
1342-
branch_pattern: develop
1342+
branch_pattern: main
13431343
event: fail
13441344
mentions: <@antonio.regadas>, @ramon.acitores134
13451345
template: basic_fail_1

.circleci/scripts/bundle-stats-commit.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ then
1616
exit 1
1717
fi
1818

19-
if [[ "${CIRCLE_BRANCH}" != "develop" ]]
19+
if [[ "${CIRCLE_BRANCH}" != "main" ]]
2020
then
21-
printf 'This is not develop branch'
21+
printf 'This is not main branch'
2222
exit 0
2323
fi
2424

.circleci/scripts/check_mmi_trigger.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ if [ -z "$CIRCLE_PULL_REQUEST" ] || [ -z "$GITHUB_TOKEN" ]; then
99
exit 0
1010
fi
1111

12-
if [[ $CIRCLE_BRANCH = 'develop' || $CIRCLE_BRANCH = 'master' || $CIRCLE_BRANCH =~ ^Version-v[0-9.]* ]]; then
12+
if [[ $CIRCLE_BRANCH = 'main' || $CIRCLE_BRANCH = 'master' || $CIRCLE_BRANCH =~ ^Version-v[0-9.]* ]]; then
1313
echo "Long-running branch detected, running MMI tests."
1414
echo "run_mmi_tests=true" > mmi_trigger.env
1515
exit 0

.circleci/scripts/git-diff-develop.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ const PR_NUMBER =
1010
process.env.CIRCLE_PR_NUMBER ||
1111
process.env.CIRCLE_PULL_REQUEST?.split('/').pop();
1212

13-
const MAIN_BRANCH = 'develop';
13+
const MAIN_BRANCH = 'main';
1414
const SOURCE_BRANCH = `refs/pull/${PR_NUMBER}/head`;
1515

1616
const CHANGED_FILES_DIR = 'changed-files';

.circleci/scripts/rerun-ci-workflow-from-failed.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ interface WorkflowStatusResponse {
5959
* Note: the API returns the first 20 workflows by default.
6060
* If we wanted to get older workflows, we would need to use the 'page-token' we would get in the first response
6161
* and perform a subsequent request with the 'page-token' parameter.
62-
* This seems unnecessary as of today, as the amount of daily PRs merged to develop is not that high.
62+
* This seems unnecessary as of today, as the amount of daily PRs merged to main is not that high.
6363
*
6464
* @returns {Promise<WorkflowItem[]>} A promise that resolves to an array of workflow items.
6565
* @throws Will throw an error if the CircleCI token is not defined or if the HTTP request fails.
@@ -177,7 +177,7 @@ async function rerunWorkflowById(workflowId: string) {
177177
}
178178

179179
/**
180-
* Re-runs failed CircleCI workflows from develop branch.
180+
* Re-runs failed CircleCI workflows from main branch.
181181
* The workflow will only be re-runed if:
182182
* 1. It has the status of 'failed'
183183
* 2. It has only been run once
@@ -187,8 +187,8 @@ async function rerunWorkflowById(workflowId: string) {
187187
* @throws Will throw an error if fetching the workflows or re-running a workflow fails.
188188
*/
189189
async function rerunFailedWorkflowsFromDevelop() {
190-
console.log('Getting Circle Ci workflows from develop branch...');
191-
const workflows = await getCircleCiWorkflowsByBranch('develop');
190+
console.log('Getting Circle Ci workflows from main branch...');
191+
const workflows = await getCircleCiWorkflowsByBranch('main');
192192

193193
console.log('Assessing if any of the workflows needs to be rerun...');
194194
for (const item of workflows) {

.devcontainer/download-builds.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ function getGitBranch() {
77
const gitOutput = execSync('git status').toString();
88

99
const branchRegex = /On branch (?<branch>.*)\n/;
10-
return gitOutput.match(branchRegex)?.groups?.branch || 'develop';
10+
return gitOutput.match(branchRegex)?.groups?.branch || 'main';
1111
}
1212

1313
async function getCircleJobs(branch: string) {

.github/CONTRIBUTING.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@ If you're picking up a bounty or an existing issue, feel free to ask clarifying
1313
### Submitting a pull request
1414
When you're done with your project / bugfix / feature and ready to submit a PR, there are a couple guidelines we ask you to follow:
1515

16-
- [ ] **Make sure you followed our [`coding guidelines`](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md)**: These guidelines aim to maintain consistency and readability across the codebase. They help ensure that the code is easy to understand, maintain, and modify, which is particularly important when working with multiple contributors.
16+
- [ ] **Make sure you followed our [`coding guidelines`](https://github.com/MetaMask/metamask-extension/blob/main/.github/guidelines/CODING_GUIDELINES.md)**: These guidelines aim to maintain consistency and readability across the codebase. They help ensure that the code is easy to understand, maintain, and modify, which is particularly important when working with multiple contributors.
1717
- [ ] **Test it**: For any new programmatic functionality, we like unit tests when possible, so if you can keep your code cleanly isolated, please do add a test file to the `tests` folder.
1818
- [ ] **Meet the spec**: Make sure the PR adds functionality that matches the issue you're closing. This is especially important for bounties: sometimes design or implementation details are included in the conversation, so read carefully!
1919
- [ ] **Close the issue**: If this PR closes an open issue, fill out the "Related issues" section with `Fixes: #$ISSUE_NUMBER`. Ex. For closing issue 418, include the line `Fixes: #418`. If it doesn't close the issue but addresses it partially, just include a reference to the issue number, like `#418`.
2020
- [ ] **Keep it simple**: Try not to include multiple features in a single PR, and don't make extraneous changes outside the scope of your contribution. All those touched files make things harder to review ;)
21-
- [ ] **PR against `develop`**: Submit your PR against the `develop` branch. This is where we merge new features so they get some time to receive extra testing before being pushed to `master` for production. If your PR is a hot-fix that needs to be published urgently, you may submit a PR against the `master` branch, but this PR will receive tighter scrutiny before merging.
21+
- [ ] **PR against `main`**: Submit your PR against the `main` branch. This is where we merge new features so they get some time to receive extra testing before being pushed to `master` for production. If your PR is a hot-fix that needs to be published urgently, you may submit a PR against the `master` branch, but this PR will receive tighter scrutiny before merging.
2222
- [ ] **Get reviewed by MetaMask Internal Developers**: All PRs require 2 approvals from MetaMask Internal Developers before merging.
23-
- [ ] **Ensure the PR is correctly labeled.**: More detail about PR labels can be found [here](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md).
23+
- [ ] **Ensure the PR is correctly labeled.**: More detail about PR labels can be found [here](https://github.com/MetaMask/metamask-extension/blob/main/.github/guidelines/LABELING_GUIDELINES.md).
2424
- [ ] **PR Titles**: Must adhere to the [Conventional Commits specification](https://www.conventionalcommits.org)
2525
- `<type>[optional scope]: <description>`
2626
- Example: `feat(parser): add ability to parse arrays`

.github/guidelines/LABELING_GUIDELINES.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ It's essential to ensure that PRs have the appropriate labels before they are co
1414
- **regression-RC-x.y.z**: This label is manually added to a bug report issue by release engineers when a bug is found during release regerssion testing phase. The `x.y.z` in the label represents the release candidate (RC) version in which the bug's been discovered.
1515

1616
### Optional labels:
17-
- **regression-develop**: This label can manually be added to a bug report issue at the time of its creation if the bug is present on the development branch, i.e., `develop`, but is not yet released in production.
17+
- **regression-main**: This label can manually be added to a bug report issue at the time of its creation if the bug is present on the development branch, i.e., `main`, but is not yet released in production.
1818
- **needs-qa**: If the PR includes a new features, complex testing steps, or large refactors, this label must be added to indicated PR requires a full manual QA prior being merged and added to a release.
1919

2020
### Labels prohibited when PR needs to be merged:

.github/pull-request-template.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,11 @@ Fixes:
3838

3939
## **Pre-merge author checklist**
4040

41-
- [ ] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md).
41+
- [ ] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/main/.github/guidelines/CODING_GUIDELINES.md).
4242
- [ ] I've completed the PR template to the best of my ability
4343
- [ ] I’ve included tests if applicable
4444
- [ ] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable
45-
- [ ] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors.
45+
- [ ] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/main/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors.
4646

4747
## **Pre-merge reviewer checklist**
4848

.github/scripts/check-pr-has-required-labels.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ async function main(): Promise<void> {
7373
if (!hasTeamLabel) {
7474
errorMessage += 'No team labels found on the PR. ';
7575
}
76-
errorMessage += `Please make sure the PR is appropriately labeled before merging it.\n\nSee labeling guidelines for more detail: https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md`;
76+
errorMessage += `Please make sure the PR is appropriately labeled before merging it.\n\nSee labeling guidelines for more detail: https://github.com/MetaMask/metamask-extension/blob/main/.github/guidelines/LABELING_GUIDELINES.md`;
7777
core.setFailed(errorMessage);
7878
process.exit(1);
7979
}

0 commit comments

Comments
 (0)