Update name of main branch in CI and docs (#161)

The name of the main branch is now "main".
Documentation and CI scripts are updated accordingly.

Co-authored-by: Ryan Burns <rtburns-jpl@users.noreply.github.com>
LT1AB
Ryan Burns 2020-07-17 09:10:33 -07:00 committed by GitHub
parent f09213eb33
commit 9d9bfa0a72
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 19 additions and 19 deletions

View File

@ -247,13 +247,13 @@ workflows:
- build: - build:
filters: filters:
branches: branches:
only: master only: main
- deploy: - deploy:
requires: requires:
- build - build
filters: filters:
branches: branches:
only: master only: main
build-deploy-release: build-deploy-release:
jobs: jobs:
- build-release: - build-release:
@ -277,15 +277,15 @@ workflows:
filters: filters:
branches: branches:
only: only:
- master - main
jobs: jobs:
- build-periodically: - build-periodically:
filters: filters:
branches: branches:
only: master only: main
- deploy: - deploy:
requires: requires:
- build-periodically - build-periodically
filters: filters:
branches: branches:
only: master only: main

View File

@ -45,19 +45,19 @@ cd isce2
git remote add my_user_name https://github.com/my_user_name/isce2.git git remote add my_user_name https://github.com/my_user_name/isce2.git
``` ```
### Updating your local master against upstream master ### Updating your local main branch against upstream
``` ```
git checkout master git checkout main
git fetch origin git fetch origin
# Be careful: this will loose all local changes you might have done now # Be careful: this will lose all local changes you might have done now
git reset --hard origin/master git reset --hard origin/main
``` ```
### Working with a feature branch ### Working with a feature branch
``` ```
git checkout master git checkout main
(potentially update your local reference against upstream, as described above) (potentially update your local reference against upstream, as described above)
git checkout -b my_new_feature_branch git checkout -b my_new_feature_branch
@ -67,22 +67,22 @@ git add my_modifid_message
git rm old_file git rm old_file
git commit -a git commit -a
# you may need to resynchronize against master if you need some bugfix # you may need to resynchronize against main if you need some bugfix
# or new capability that has been added to master since you created your # or new capability that has been added to main since you created your
# branch # branch
git fetch origin git fetch origin
git rebase origin/master git rebase origin/main
# At end of your work, make sure history is reasonable by folding non # At end of your work, make sure history is reasonable by folding non
# significant commits into a consistent set # significant commits into a consistent set
git rebase -i master (use 'fixup' for example to merge several commits together, git rebase -i main (use 'fixup' for example to merge several commits together,
and 'reword' to modify commit messages) and 'reword' to modify commit messages)
# or alternatively, in case there is a big number of commits and marking # or alternatively, in case there is a big number of commits and marking
# all them as 'fixup' is tedious # all them as 'fixup' is tedious
git fetch origin git fetch origin
git rebase origin/master git rebase origin/main
git reset --soft origin/master git reset --soft origin/main
git commit -a -m "Put here the synthetic commit message" git commit -a -m "Put here the synthetic commit message"
# push your branch # push your branch
@ -93,7 +93,7 @@ From GitHub UI, issue a pull request
If the pull request discussion results in changes, If the pull request discussion results in changes,
commit locally and push. To get a reasonable history, you may need to commit locally and push. To get a reasonable history, you may need to
``` ```
git rebase -i master git rebase -i main
``` ```
, in which case you will have to force-push your branch with , in which case you will have to force-push your branch with
``` ```

View File

@ -71,7 +71,7 @@ RUN set -ex \
&& cd /tmp \ && cd /tmp \
&& mkdir -p /tmp/rpm-build/opt \ && mkdir -p /tmp/rpm-build/opt \
&& mv $ISCE_INSTALL_ROOT /tmp/rpm-build/opt \ && mv $ISCE_INSTALL_ROOT /tmp/rpm-build/opt \
&& curl -s https://api.github.com/repos/$ISCE_ORG/isce2/git/refs/heads/master \ && curl -s https://api.github.com/repos/$ISCE_ORG/isce2/git/refs/heads/main \
> /tmp/rpm-build/opt/isce2/version.json \ > /tmp/rpm-build/opt/isce2/version.json \
&& hash=$(cat /tmp/rpm-build/opt/isce2/version.json | jq -r .object.sha) \ && hash=$(cat /tmp/rpm-build/opt/isce2/version.json | jq -r .object.sha) \
&& short_hash=$(echo $hash | cut -c1-5) \ && short_hash=$(echo $hash | cut -c1-5) \

View File

@ -72,7 +72,7 @@ RUN set -ex \
&& rm -rf /opt/isce2/src \ && rm -rf /opt/isce2/src \
&& mkdir -p /tmp/rpm-build/opt \ && mkdir -p /tmp/rpm-build/opt \
&& mv $ISCE_INSTALL_ROOT /tmp/rpm-build/opt \ && mv $ISCE_INSTALL_ROOT /tmp/rpm-build/opt \
&& curl -s https://api.github.com/repos/$ISCE_ORG/isce2/git/refs/heads/master \ && curl -s https://api.github.com/repos/$ISCE_ORG/isce2/git/refs/heads/main \
> /tmp/rpm-build/opt/isce2/version.json \ > /tmp/rpm-build/opt/isce2/version.json \
&& hash=$(cat /tmp/rpm-build/opt/isce2/version.json | jq -r .object.sha) \ && hash=$(cat /tmp/rpm-build/opt/isce2/version.json | jq -r .object.sha) \
&& short_hash=$(echo $hash | cut -c1-5) \ && short_hash=$(echo $hash | cut -c1-5) \