Merge pull request #2397 from openMF/revert-2396-WEB-132-fix-branch-reference-replace-master-with-main-in-ci-workflow-triggers

Revert "WEB-132: Replace `master` with `main` in GitHub Actions workflow"
This commit is contained in:
David Higgins
2025-04-11 15:17:01 +01:00
committed by GitHub
5 changed files with 21 additions and 21 deletions
+14 -14
View File
@@ -3,7 +3,7 @@
- View the [README](../README.md) or [watch this video](https://youtu.be/OnxxC3K2oro) to get your development environment up and running. - View the [README](../README.md) or [watch this video](https://youtu.be/OnxxC3K2oro) to get your development environment up and running.
- Learn how to [format pull requests](#submitting-a-pull-request). - Learn how to [format pull requests](#submitting-a-pull-request).
- Read how to [rebase/merge upstream branches](#configuring-remotes). - Read how to [rebase/merge upstream branches](#configuring-remotes).
- Understand our [commit message conventions](https://github.com/openMF/web-app/blob/main/.github/COMMIT_MESSAGE.md). - Understand our [commit message conventions](https://github.com/openMF/web-app/blob/master/.github/COMMIT_MESSAGE.md).
- Sign our [Mifos CLA](http://mifos.org/about-us/financial-legal/mifos-contributor-agreement/). - Sign our [Mifos CLA](http://mifos.org/about-us/financial-legal/mifos-contributor-agreement/).
- Follow our [code of conduct](CODE_OF_CONDUCT.md). - Follow our [code of conduct](CODE_OF_CONDUCT.md).
- [Find an issue to work on](https://github.com/openMF/web-app/issues) and start smashing! - [Find an issue to work on](https://github.com/openMF/web-app/issues) and start smashing!
@@ -49,10 +49,10 @@ Remember that this is an inclusive community, committed to creating a safe, posi
git clone https://github.com/your-username/web-app.git git clone https://github.com/your-username/web-app.git
``` ```
- Make sure you are in the `main` branch. - Make sure you are in the `master` branch.
``` ```
git checkout main git checkout master
``` ```
- Create a new branch with a meaningful name before adding and committing your changes. - Create a new branch with a meaningful name before adding and committing your changes.
@@ -97,7 +97,7 @@ git push origin branch-name
git push origin remote-branch-name --force git push origin remote-branch-name --force
``` ```
- Follow the Pull request template and submit a pull request with a motive for your change and the method you used to achieve it to be merged with the `main` branch. - Follow the Pull request template and submit a pull request with a motive for your change and the method you used to achieve it to be merged with the `master` branch.
- If you can, please submit the pull request with the fix or improvements including tests. - If you can, please submit the pull request with the fix or improvements including tests.
- During review, if you are requested to make changes, rebase your branch and squash the multiple commits into one. Once you push these changes the pull request will edit automatically. - During review, if you are requested to make changes, rebase your branch and squash the multiple commits into one. Once you push these changes the pull request will edit automatically.
@@ -120,18 +120,18 @@ git remote add upstream https://github.com/openMF/web-app.git
> upstream https://github.com/openMF/web-app.git (push) > upstream https://github.com/openMF/web-app.git (push)
``` ```
3. To update your local copy with remote changes, run the following: (This will give you an exact copy of the current remote. You should not have any local changes on your main branch, if you do, use rebase instead.) 3. To update your local copy with remote changes, run the following: (This will give you an exact copy of the current remote. You should not have any local changes on your master branch, if you do, use rebase instead.)
``` ```
git fetch upstream git fetch upstream
git checkout main git checkout master
git merge upstream/main git merge upstream/master
``` ```
4. Push these merged changes to the main branch on your fork. Ensure to pull in upstream changes regularly to keep your forked repository up to date. 4. Push these merged changes to the master branch on your fork. Ensure to pull in upstream changes regularly to keep your forked repository up to date.
``` ```
git push origin main git push origin master
``` ```
5. Switch to the branch you are using for some piece of work. 5. Switch to the branch you are using for some piece of work.
@@ -143,7 +143,7 @@ git checkout branch-name
6. Rebase your branch, which means, take in all latest changes and replay your work in the branch on top of this - this produces cleaner versions/history. 6. Rebase your branch, which means, take in all latest changes and replay your work in the branch on top of this - this produces cleaner versions/history.
``` ```
git rebase main git rebase master
``` ```
7. Push the final changes when you're ready. 7. Push the final changes when you're ready.
@@ -162,10 +162,10 @@ After your pull request is merged, you can safely delete your branch and pull th
git push origin --delete branch-name git push origin --delete branch-name
``` ```
2. Checkout the main branch. 2. Checkout the master branch.
``` ```
git checkout main git checkout master
``` ```
3. Delete the local branch. 3. Delete the local branch.
@@ -174,10 +174,10 @@ git checkout main
git branch -D branch-name git branch -D branch-name
``` ```
4. Update your main branch with the latest upstream version. 4. Update your master branch with the latest upstream version.
``` ```
git pull upstream main git pull upstream master
``` ```
## Skipping a Travis CI Build ## Skipping a Travis CI Build
+2 -2
View File
@@ -4,9 +4,9 @@ name: build-run
on: on:
# Triggers the workflow on push or pull request events but only for the main branch # Triggers the workflow on push or pull request events but only for the main branch
push: push:
branches: [main] branches: [master]
pull_request: pull_request:
branches: [main] branches: [master]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel # A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs: jobs:
@@ -2,7 +2,7 @@ name: Publish Image in Docker Hub
on: on:
push: push:
branches: [main] branches: [master]
jobs: jobs:
build: build:
@@ -43,7 +43,7 @@ jobs:
run: | run: |
TAGS="--tag $DOCKER_ORGANIZATION/web-app:${{ steps.extract_branch.outputs.branch }}" TAGS="--tag $DOCKER_ORGANIZATION/web-app:${{ steps.extract_branch.outputs.branch }}"
if [ "${{ steps.extract_branch.outputs.branch }}" == "main" ]; then if [ "${{ steps.extract_branch.outputs.branch }}" == "master" ]; then
TAGS="$TAGS --tag $DOCKER_ORGANIZATION/web-app:${{ steps.git_hashes.outputs.short_hash }} --tag $DOCKER_ORGANIZATION/web-app:${{ steps.git_hashes.outputs.long_hash }}" TAGS="$TAGS --tag $DOCKER_ORGANIZATION/web-app:${{ steps.git_hashes.outputs.short_hash }} --tag $DOCKER_ORGANIZATION/web-app:${{ steps.git_hashes.outputs.long_hash }}"
fi fi
+1 -1
View File
@@ -1,5 +1,5 @@
# https://github.com/marketplace/actions/close-stale-issues # https://github.com/marketplace/actions/close-stale-issues
# https://github.com/actions/stale/blob/main/action.yml # https://github.com/actions/stale/blob/master/action.yml
# https://github.com/actions/stale # https://github.com/actions/stale
name: Mark stale issues and pull requests name: Mark stale issues and pull requests
on: on:
+2 -2
View File
@@ -2,9 +2,9 @@ name: Tests
on: on:
push: push:
branches: [main] branches: [master]
pull_request: pull_request:
branches: [main] branches: [master]
jobs: jobs:
testRigor: testRigor: