Skip to content

Commit 565107a

Browse files
JackPlowmanCorbisc
authored andcommitted
Switch base branch name to main (#353)
Set everything to use main branch name
1 parent 12202f1 commit 565107a

11 files changed

Lines changed: 24 additions & 24 deletions

File tree

.github/workflows/code-quality.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: "Check code format and quality"
22
on:
33
push:
4-
branches: [develop, master]
4+
branches: [develop, main]
55
pull_request:
66
types: [opened, synchronize, reopened]
77
jobs:

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -506,7 +506,7 @@ tag-commit-for-deployment: # Tag git commit for deployment - mandatory: PROFILE=
506506
make git-tag-create-environment-deployment COMMIT=$(COMMIT)
507507
else
508508
echo PROFILE=$(PROFILE) should equal ENVIRONMENT=$(ENVIRONMENT)
509-
echo Recommended: you run this command from the master branch
509+
echo Recommended: you run this command from the main branch
510510
fi
511511

512512
tag-commit-to-destroy-environment: # Tag git commit to destroy deployment - mandatory: ENVIRONMENT=[di-number], COMMIT=[short commit hash]

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,7 @@ The production pipeline terraform stack must be deployed
424424

425425
To deploy an update/new version to a production environment the commit must be tagged using the command below. This will automatically run a Github web hook that will trigger an AWS Codebuild project that will deploy the environment based on the git tag.
426426

427-
Note: This should only be run against a commit on the master branch as the code has been built into an image and pushed to ECR. Also short commit hash is the first 7 characters of the commit hash.
427+
Note: This should only be run against a commit on the main branch as the code has been built into an image and pushed to ECR. Also short commit hash is the first 7 characters of the commit hash.
428428

429429
To Deploy Demo
430430

application/.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# =====================================================================================================================
2-
# SEE: https://github.com/github/gitignore/blob/master/Python.gitignore
2+
# SEE: https://github.com/github/gitignore/blob/main/Python.gitignore
33

44
# Byte-compiled / optimized / DLL files
55
__pycache__/

build/automation/bin/git-secrets

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ prepare_commit_msg_hook() {
185185
merge,)
186186
local git_head=$(env | grep GITHEAD) # e.g. GITHEAD_<sha>=release/1.43
187187
local sha="${git_head##*=}" # Get just the SHA
188-
local branch=$(git symbolic-ref HEAD) # e.g. refs/heads/master
188+
local branch=$(git symbolic-ref HEAD) # e.g. refs/heads/main
189189
local dest="${branch#refs/heads/}" # cut out "refs/heads"
190190
git log "${dest}".."${sha}" -p | scan_with_fn_or_die "scan" -
191191
;;

build/automation/var/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Profile is a set of configuration options specific to an environment expressed a
88

99
* `local` - local development profile (Not attached to an AWS Account)
1010
* `task` - a specific environment for branches. This should be default for creating non-prod infrastructure (AWS Non-prod Account)
11-
* `dev` - shared development profile that supports automation on every commit to the remote master branch in the CI pipeline or it is used for a cleanup (AWS Non-prod Account)
11+
* `dev` - shared development profile that supports automation on every commit to the remote main branch in the CI pipeline or it is used for a cleanup (AWS Non-prod Account)
1212
* `test` - test profile that runs nightly in the CI pipeline (AWS Non-prod Account)
1313
* `demo` - production, UX (AWS Prod Account)
1414
* `live` - production, service (AWS Prod Account)

documentation/CONTRIBUTING.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -132,13 +132,13 @@ Upload the public key to your GitHub and GitLab accounts using the links below.
132132
Principles to follow
133133

134134
- A direct merge to the canonical branch is not allowed and can only be done by creating a pull request (merge request)
135-
- If not stated otherwise the only long-lived branch is master, i.e. canonical branch
136-
- Any new branch should be created from master
135+
- If not stated otherwise the only long-lived branch is main, i.e. canonical branch
136+
- Any new branch should be created from main
137137
- The preferred short-lived branch name format is `task/JIRA-XXX_Descriptive_branch_name`
138138
- The preferred hotfix branch name format is `bugfix/JIRA-XXX_Descriptive_branch_name`
139139
- All commits must be cryptographically signed
140140
- Commits should be made often and pushed to the remote
141-
- Use rebase to get the latest commits from the master while working with a short-lived or a bugfix branch
141+
- Use rebase to get the latest commits from the main while working with a short-lived or a bugfix branch
142142
- Squash commits when appropriate
143143
- Merge commits are not allowed
144144

@@ -174,38 +174,38 @@ Contributing to an already existing branch
174174
git commit -S -m "Meaningful description of change"
175175
git push
176176

177-
Rebasing a branch onto master
177+
Rebasing a branch onto main
178178

179179
git checkout task/JIRA-XXX_Descriptive_branch_name
180180
git rebase -i HEAD~X # Squash X number of commits, all into one
181181
# When prompted change commit type to `squash` for all the commits except the top one
182182
# On the following screen replace pre-inserted comments by a single summary
183183
git push --force-with-lease
184184

185-
git checkout master
185+
git checkout main
186186
git pull
187187
git checkout task/JIRA-XXX_Descriptive_branch_name
188-
git rebase master
188+
git rebase main
189189
# Resolve conflicts
190190
git add .
191191
git rebase --continue
192192
git push --force-with-lease
193193

194-
Merging a branch to master - this should be done only in an exceptional circumstance as the proper process is to raise an MR
194+
Merging a branch to main - this should be done only in an exceptional circumstance as the proper process is to raise an MR
195195

196-
git checkout master
197-
git pull --prune # Make sure master is up-to-date
196+
git checkout main
197+
git pull --prune # Make sure main is up-to-date
198198
git checkout task/JIRA-XXX_Descriptive_branch_name
199199
git pull # Make sure the task branch is up-to-date
200200

201201
git rebase -i HEAD~X # Squash X number of commits, all into one
202202
# When prompted change commit type to `squash` for all the commits except the top one
203203
# On the following screen replace pre-inserted comments by a single summary
204204

205-
git rebase master # Rebase the task branch on top of master
206-
git checkout master # Switch to master branch
205+
git rebase main # Rebase the task branch on top of main
206+
git checkout main # Switch to main branch
207207
git merge -ff task/JIRA-XXX_Descriptive_branch_name # Fast-forward merge
208-
git push # Push master to remote
208+
git push # Push main to remote
209209

210210
git push -d origin task/JIRA-XXX_Descriptive_branch_name # Remove remote branch
211211
git branch -d task/JIRA-XXX_Descriptive_branch_name # Remove local branch
@@ -252,15 +252,15 @@ Git hooks are located in `build/automation/etc/githooks/scripts` and executed au
252252

253253
### Git tags
254254

255-
Aim at driving more complex deployment workflows by tags with an exception of the master branch where the continuous deployment to a development environment should be enabled by default.
255+
Aim at driving more complex deployment workflows by tags with an exception of the main branch where the continuous deployment to a development environment should be enabled by default.
256256

257257
## Pull request (merge request)
258258

259259
- Set the title to `JIRA-XXX Descriptive branch name`, where `JIRA-XXX` is the ticket reference number
260260
- Ensure all commits will be squashed and the source branch will be removed once the request is accepted
261261
- Notify the team on Slack to give your colleagues opportunity to review changes and share the knowledge
262262
- If the change has not been pair or mob programmed it must follow the code review process and be approved by at least one peer, all discussions must be resolved
263-
- A merge to master must be squashed and rebased on top, preserving the list of all commit messages
263+
- A merge to main must be squashed and rebased on top, preserving the list of all commit messages
264264

265265
## Code review
266266

documentation/ONBOARDING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ This is a generic onboarding template that can be used by any team to help to br
3232

3333
### Technical Setup
3434

35-
- macOS [configuration](https://github.com/nhsd-exeter/make-devops/blob/master/build/automation/lib/macos/README.md)
35+
- macOS [configuration](https://github.com/nhsd-exeter/make-devops/blob/main/build/automation/lib/macos/README.md)
3636
- CPaaS Texas VPN access
3737
- [GitLab](https://gitlab.mgmt.texasplatform.uk/)
3838
- [Jenkins](https://jenkins.mgmt.texasplatform.uk/)

documentation/TODO.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
List here all the technical tasks for prioritisation that need to be discussed with the team but are not ready yet to be placed on the backlog. This should form a holistic view of the state of the project and show the direction for incremental development and refactoring of certain areas of the software listed below. The idea behind this list is to ensure backlog hygiene and that it only consists of stories that can be completed within the next two sprints. Therefore, the focus can be changed dynamically depending on the business need.
1515

16-
This document must be discussed regularly with the Tech Lead and considered in the context of the [Engineering Quality Checks](https://github.com/NHSDigital/software-engineering-quality-framework/blob/master/quality-checks.md) provided as a guidance by NHS Digital Product Development directorate.
16+
This document must be discussed regularly with the Tech Lead and considered in the context of the [Engineering Quality Checks](https://github.com/NHSDigital/software-engineering-quality-framework/blob/main/quality-checks.md) provided as a guidance by NHS Digital Product Development directorate.
1717

1818
## Regular tasks
1919

infrastructure/.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# =====================================================================================================================
2-
# SEE: https://github.com/github/gitignore/blob/master/Terraform.gitignore
2+
# SEE: https://github.com/github/gitignore/blob/main/Terraform.gitignore
33

44
# Local .terraform directories
55
**/.terraform/*

0 commit comments

Comments
 (0)