... | ... | @@ -3,16 +3,37 @@ |
|
|
# OpenFOAM repositories
|
|
|
|
|
|
OpenFOAM repositories are hosted at the https://develop.openfoam.com webpage.
|
|
|
Many are public-access and can be downloaded or cloned directly; to access other internal repositories and take advantage of advanced features, users must create an account.
|
|
|
Many are public-access and can be downloaded or cloned directly;
|
|
|
to access other internal repositories and take advantage of advanced
|
|
|
features (such as reporting issues), users must create an account.
|
|
|
|
|
|
The main repositories:
|
|
|
- The [OpenFOAM repository](https://develop.openfoam.com/Development/OpenFOAM-plus/)
|
|
|
with [issue tracker](https://develop.openfoam.com/Development/OpenFOAM-plus/issues)
|
|
|
- The [ThirdParty repository](https://develop.openfoam.com/Development/ThirdParty-plus/)
|
|
|
with [issue tracker](https://develop.openfoam.com/Development/ThirdParty-plus/issues)
|
|
|
|
|
|
## Registration
|
|
|
## Organization of git branches
|
|
|
|
|
|
- Go to https://develop.openfoam.com and create a new user account
|
|
|
- A confirmation email will be sent to the registered address (check the spam folder if no emails are received after a few minutes)
|
|
|
- Follow the link to complete the sign-up process
|
|
|
The OpenFOAM repository follows a
|
|
|
[branching workflow](https://git-scm.com/book/en/v2/Git-Branching-Branching-Workflows)
|
|
|
with the following branches
|
|
|
|
|
|
![GitLab User Registration](images/KB-GL-ADV-Register.png)
|
|
|
- `master`: bugfix updates since the last release, should always be runnable/stable code (can be used in production)
|
|
|
- `develop`: current developments, waiting to be pushed into the master prior to a new release.
|
|
|
The code in develop is generally quite stable, but regressions may occasionally occur.
|
|
|
- `maintenance-v1812`, _etc_: bugfix branches for previous releases.
|
|
|
When a new code version is released, `master`
|
|
|
is renamed `maintenance-{prevRelease}` and a new `master` is created at release.
|
|
|
- `feature-XYZ`: a work-in-progress feature branch. Mostly for internal use.
|
|
|
|
|
|
Most people will use the `master` branch to have up-to-date bugfixes
|
|
|
of the current release.
|
|
|
|
|
|
The _feature_ branches (as denoted by their prefix), have no
|
|
|
guarantee of being stable and are liable to change at any time.
|
|
|
Since they will also occasionally be rebased onto the lastest
|
|
|
_develop_, there is additionally is guarantee of continuity.
|
|
|
|
|
|
|
|
|
## Exploring projects
|
... | ... | @@ -41,15 +62,9 @@ Many are public-access and can be downloaded or cloned directly; to access other |
|
|
|
|
|
![GitLab clone address](images/KB-GL-ADV-project-clone-address.png)
|
|
|
|
|
|
- To use the SSH protocol (as shown above) you need to register your public SSH key. Refer to the [Adding an SSH key](#openfoam-repositories_terminal-mode-cloning_adding-an-ssh-key) section for further information.
|
|
|
|
|
|
- Clone the default _master_ branch via HTTPS using
|
|
|
```
|
|
|
git clone https://develop.openfoam.com:Development/OpenFOAM-plus.git
|
|
|
```
|
|
|
or via SSH
|
|
|
```
|
|
|
git clone git@develop.openfoam.com:Development/OpenFOAM-plus.git
|
|
|
git clone https://develop.openfoam.com/Development/OpenFOAM-plus.git
|
|
|
```
|
|
|
|
|
|
- **Optional:** You may specify a target branch directly using
|
... | ... | @@ -58,7 +73,7 @@ git clone -b <branch name> <address of git> <name of resulting directory> |
|
|
```
|
|
|
e.g. to clone the _develop_ branch to your local OpenFOAM-plus.develop directory via HTTPS:
|
|
|
```
|
|
|
git clone -b develop https://develop.openfoam.com:Development/OpenFOAM-plus.git OpenFOAM-plus.develop
|
|
|
git clone -b develop https://develop.openfoam.com/Development/OpenFOAM-plus.git OpenFOAM-plus.develop
|
|
|
```
|
|
|
|
|
|
- Since [OpenFOAM-v1712](https://www.openfoam.com/releases/openfoam-v1712) community contributions may be included using the git submodule system. To initialise the submodules located in the [$WM_PROJECT_DIR/modules](https://develop.openfoam.com/Development/OpenFOAM-plus/tree/master/modules) directory:
|
... | ... | @@ -69,6 +84,24 @@ git submodule init |
|
|
contains more information.
|
|
|
|
|
|
|
|
|
#### Shallow cloning
|
|
|
|
|
|
- Shallow cloning is a clone of the last repository state without its
|
|
|
entire history. This makes for a smaller repository and faster cloning.
|
|
|
```
|
|
|
git clone --depth=1 https://develop.openfoam.com/Development/OpenFOAM-plus.git
|
|
|
|
|
|
cd OpenFOAM-plus
|
|
|
git submodule init && git submodule update --depth=1
|
|
|
```
|
|
|
|
|
|
If you want more than just the very last commit, adjust the clone
|
|
|
depth accordingly. For example,
|
|
|
```
|
|
|
git clone --depth=8 https://develop.openfoam.com/Development/OpenFOAM-plus.git
|
|
|
```
|
|
|
|
|
|
|
|
|
### Update existing snapshot
|
|
|
|
|
|
- The repositories are updated regularly to include bug fixes and new features. Retrieve the updates using:
|
... | ... | @@ -82,8 +115,20 @@ git submodule update |
|
|
- Note: if you experience merge conflicts during the pull due to your own local code changes, you will need to resolve them manually/reset the state of your repository and re-pull
|
|
|
|
|
|
|
|
|
## Registration
|
|
|
|
|
|
- Go to https://develop.openfoam.com and create a new user account
|
|
|
- A confirmation email will be sent to the registered address (check the spam folder if no emails are received after a few minutes)
|
|
|
- Follow the link to complete the sign-up process
|
|
|
|
|
|
![GitLab User Registration](images/KB-GL-ADV-Register.png)
|
|
|
|
|
|
|
|
|
### Adding a SSH key
|
|
|
|
|
|
- Access your profile related settings from the top-right of the browser page. Follow the steps numbered in the snapshot to add a key to your profile. You may add multiple SSH keys and distinguish them with proper title.
|
|
|
If you use SSH for cloning, you can access your profile related
|
|
|
settings from the top-right of the browser page. Follow the steps
|
|
|
numbered in the snapshot to add a key to your profile. You may add
|
|
|
multiple SSH keys and distinguish them with proper title.
|
|
|
|
|
|
![GitLab Add SSH key](images/KB-GL-ADV-AddSSHKey.png) |