Skip to content

Commit

Permalink
Merge pull request #253 from ral-facilities/rename-master-#252
Browse files Browse the repository at this point in the history
Rename instances of "master" to "main"
  • Loading branch information
MRichards99 authored Apr 19, 2022
2 parents 29eabfd + 9d6f649 commit c674205
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 14 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
pull_request:
push:
branches:
- master
- main
jobs:
tests:
runs-on: ubuntu-20.04
Expand Down Expand Up @@ -294,10 +294,10 @@ jobs:
- name: Reinstall ICAT Server
run: cd /home/runner/install/icat.server; ./setup -vv install

- name: Checkout DataGateway API (master)
- name: Checkout DataGateway API (default branch)
uses: actions/checkout@v2
with:
ref: master
ref: ${{ github.event.repository.default_branch }}

- name: Create config.json
run: cp datagateway_api/config.json.example datagateway_api/config.json
Expand All @@ -315,10 +315,10 @@ jobs:

- name: Add dummy data to icatdb
run: poetry run python -m util.icat_db_generator
- name: Get SQL dump of dummy data from master's generator script
run: mysqldump -picatdbuserpw -uicatdbuser --skip-comments icatdb > ~/generator_script_dump_master.sql
- name: Get SQL dump of dummy data from main's generator script
run: mysqldump -picatdbuserpw -uicatdbuser --skip-comments icatdb > ~/generator_script_dump_main.sql

# Tests that the generator script produces the same data as is produced with master's version
# Tests that the generator script produces the same data as is produced with main's version

# NOTE: If a delibrate change is made to the script that will change the data generated,
# the diff (and therefore this job) will fail. If this is the case, don't be alarmed.
Expand All @@ -328,4 +328,4 @@ jobs:
# problem with the changes made that will make the generator script's data
# different to SciGateway preprod
- name: Diff SQL dumps
run: diff -s ~/generator_script_dump_master.sql ~/generator_script_dump_1.sql
run: diff -s ~/generator_script_dump_main.sql ~/generator_script_dump_1.sql
2 changes: 1 addition & 1 deletion .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Release Build
on:
push:
branches:
- master
- main

jobs:
build:
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[![Build Status](https://github.com/ral-facilities/datagateway-api/workflows/CI/badge.svg?branch=master)](https://github.com/ral-facilities/datagateway-api/actions?query=workflow%3A%22CI%22)
[![Codecov](https://codecov.io/gh/ral-facilities/datagateway-api/branch/master/graph/badge.svg)](https://codecov.io/gh/ral-facilities/datagateway-api)
[![Build Status](https://github.com/ral-facilities/datagateway-api/workflows/CI/badge.svg?branch=main)](https://github.com/ral-facilities/datagateway-api/actions?query=workflow%3A%22CI%22)
[![Codecov](https://codecov.io/gh/ral-facilities/datagateway-api/branch/main/graph/badge.svg)](https://codecov.io/gh/ral-facilities/datagateway-api)



Expand Down Expand Up @@ -846,7 +846,7 @@ to query DataGateway API.
# API Versioning
This repository uses semantic versioning as the standard for version number
incrementing, with the version stored in `pyproject.toml`. There is a GitHub Actions
workflow (`release-build.yml`) which runs when master is updated (i.e. when a pull
workflow (`release-build.yml`) which runs when main is updated (i.e. when a pull
request is merged). This uses
[python-semantic-release](https://github.com/relekang/python-semantic-release) to
determine whether a release needs to be made, and if so, whether a major, minor or patch
Expand Down Expand Up @@ -887,8 +887,8 @@ where possible, as the types are also used to form `CHANGELOG.md`.

New releases are only made when a `fix:` (patch), `feat:` (minor) or `BREAKING CHANGE:`
(major) commit type is found between the previous release and the most recent commit on
master. When the version is bumped, a GitHub tag and release is made which contains
the source code and the built versions of the API (sdist and wheel).
main. When the version is bumped, a GitHub tag and release is made which contains the
source code and the built versions of the API (sdist and wheel).

To check how the version number will be impacted before merging a pull request, use the
following command to show the version which will be made when the GitHub Actions release
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ authors = ["Matthew Richards <matthew.richards@stfc.ac.uk>"]
version_toml = [
"pyproject.toml:tool.poetry.version"
]
branch = "master"
branch = "main"
upload_to_pypi = false
upload_to_release = true
build_command = "pip install poetry==1.1.9 && poetry build"
Expand Down

0 comments on commit c674205

Please sign in to comment.