STYLE: minor style and typo corrections

ENH: add missing Copyright statements
  ENH: update from v1912 to v2006
Kutalmis Bercin
2020-08-04 07:56:09 +01:00
committed by Mark Olesen
parent d927e0297a
commit c59d31216a
18 changed files with 179 additions and 130 deletions

@ -20,7 +20,7 @@ required to clone the repository when packaging from sources.
With the repository updates, its size has been shrunk by 80% and is
now currently around 200-210 MB instead of 900MB. The maintenance effort
removed some _binary bombs_ (eg, simulation results that had been
removed some _binary bombs_ (e.g., simulation results that had been
inadvertently added over the years) and other artefacts that caused
the repository to bloat, while preserving the change history.
@ -35,19 +35,18 @@ signatures, any changes will result in new SHA1 values for the
commits. So even when file-tree contents are identical, the SHA1 of
two individual commits likely are not.
### Moving Forward
### Moving forward
To properly delineate the repositories, we have taken the
[`maintenance-v1812`][main-1812] branch as the cut-point. This branch
and older branches are essentially *retired* and preserved on the [old
OpenFOAM-plus repository][old-foam-repo], whereas the
[`master`][master] branch (currently the bugfix branch for v1906 at
[`master`][master] branch (currently the bugfix branch for `v2006` at
the time of writing) and obviously the [`develop`][develop] branch are
both being actively worked upon within the [improved openfoam
both being actively worked upon within the [improved OpenFOAM
repository][foam-repo].
To reduce confusion, branches related to v1906 (master and develop)
To reduce confusion, `master` and `develop` branches
have been expunged from the old repository. This circumvents the
possibility of duplicate commits or forgotten commits that would
otherwise occur if both repositories covered the same active code
@ -56,7 +55,7 @@ range.
### Migrating your code
The file contents of the previous `master` and `develop` branches have been preserved and it should be possible to migrate any user code provided that it can be `rebased`. A mapping from the old-to-new commit hashes is [available here](uploads/89c19da374e3d6e281d14f84a9f34b55/old-to-new.map).
To migrate your code, clone the new repository (shown here using https) and change working directory into it:
To migrate your code, clone the new repository (shown here using HTTPS) and change working directory into it:
```
cd $HOME/OpenFOAM
@ -82,13 +81,13 @@ Fetch the your local code changes (commits)
git fetch local-repo
```
At this point you can apply your local change commits to the latest master or develop branches using git-format-patch and git-cherry-pick (see below). Alternatively, if you would like to re-apply your changes to the equivalent starting point in the new repository continue to the next section.
At this point you can apply your local change commits to the latest `master` or `develop` branches using git-format-patch and git-cherry-pick (see below). Alternatively, if you would like to re-apply your changes to the equivalent starting point in the new repository continue to the next section.
#### Recovering an old branching location
Skip this section if you would like to apply your local changes to the latest master/develop branches.
Use the SHA1 mapping from [old-to-new](uploads/89c19da374e3d6e281d14f84a9f34b55/old-to-new.map) to find your starting/base commit. For example, if your branching point was `XXXX` identify the equivalent commit (noted `YYYY` later) in the new repository using:
Use the SHA1 mapping from [old-to-new](uploads/89c19da374e3d6e281d14f84a9f34b55/old-to-new.map) to find your starting/base commit. For example, if your branching point was `XXXX` identify the equivalent commit (noted `YYYY` later) in the new repository using:
```
grep XXXX old-to-new.map
@ -140,7 +139,6 @@ git cherry-pick <oldest-commit>..<newest=commit>
Thank you for your understanding and we hope that you enjoy using the more streamlined repository
#### Additional points
The default _development_ version was previously designated `plus`.
@ -155,11 +153,15 @@ This informal naming convention is now also noted in the bashrc file:
This change affects the following directory locations:
- `$WM_PROJECT_USER_DIR`
- `$FOAM_RUN`
- `$FOAM_USER_APPBIN`, `$FOAM_USER_LIBBIN`
- `$FOAM_USER_APPBIN`
- `$FOAM_USER_LIBBIN`
If you have been using the `run` _alias_ in the development version,
the location will also have changed accordingly.
----
Copyright (C) 2019-2020 OpenCFD Ltd.
[foam-repo]: https://develop.openfoam.com/Development/openfoam/
[master]: https://develop.openfoam.com/Development/openfoam/tree/master

@ -39,6 +39,11 @@ These will be monitored and closed accordingly.
We are keen to hear feedback from our users and welcome
[feature requests](/page-feature-requests)!
----
Copyright (C) 2019-2020 OpenCFD Ltd.
[foam-issues]: https://develop.openfoam.com/Development/openfoam/-/issues
[code-devel]: /coding/git-workflow

@ -28,9 +28,9 @@
### spack
<a name="spack"></a>
The installation of openfoam with spack will generally require the
The installation of OpenFOAM with spack will generally require the
latest (development version) of spack. If this is available, you can
install openfoam in various configurations and dependencies, but
install OpenFOAM in various configurations and dependencies, but
typically can simply install directly:
```
@ -51,7 +51,7 @@ The support for Darwin is complete, but less well tested than Linux.
CGAL
- ThirdParty CGAL will normally need to be compiled _without_ mpfr/gmp.
This should be done manually prior to building OpenFOAM or other
ThirdParty. Eg,
ThirdParty. For example,
```
cd $WM_THIRD_PARTY_DIR
./makeCGAL gmp-none mpfr-none
@ -75,7 +75,7 @@ By default, OpenFOAM handles newer/older non-system compilers as
_ThirdParty_ installations and uses the combination of `WM_COMPILER`
and `WM_COMPILER_TYPE` to select them. In some cases, however, it can
be much more convenient for the user to install prebuilt compiler
binaries as *system* compilers (eg, using deb or rpm packages).
binaries as *system* compilers (e.g., using deb or rpm packages).
This poses a slight problem since the OpenFOAM build rules normally
use the main compiler name (`gcc`, `clang` etc) without any additional
version information, but the various *system* compilers are frequently
@ -148,8 +148,11 @@ example:
```
For older versions, `which $(wmake -show-cxx)` instead.
--------
Copyright (C) 2020 OpenCFD Ltd.
[latest-build]: https://develop.openfoam.com/Development/openfoam/blob/develop/doc/Build.md
[v2006-build]: https://develop.openfoam.com/Development/openfoam/blob/maintenance-v2006/doc/Build.md

@ -40,7 +40,7 @@ For CentOS/RedHat, the cross-compiler is available under `PowerTools`:
dnf config-manager --set-enabled PowerTools
```
The package names to install are _somwhat_ different from the openSUSE
The package names to install are _somewhat_ different from the openSUSE
ones:
```
dnf install mingw64-gcc-c++
@ -105,7 +105,7 @@ export WM_LABEL_SIZE=32
```
Additional adjustments may be required in some other places. For example
in `etc/config.sh/FFTW`
in `etc/config.sh/FFTW`:
```
fftw_version=fftw-system
export FFTW_ARCH_PATH=/usr/x86_64-w64-mingw32/sys-root/mingw
@ -153,4 +153,7 @@ the entire directory contents:
even when the EulerFoam solvers fail to compile.
--------
Copyright (C) 2020 OpenCFD Ltd.
[v1906-notes]: https://www.openfoam.com/releases/openfoam-v1906/

@ -6,7 +6,8 @@
[[_TOC_]]
## Repository Structure
## Repository structure
OpenFOAM follows a
[branching workflow](https://git-scm.com/book/en/v2/Git-Branching-Branching-Workflows)
@ -16,7 +17,7 @@ with the following main branches:
|-------------|---------------|
| `master` | Bugfix updates since the last release, should always be stable and runnable (suitable for production) |
| `develop` | Current developments, slated for the next release. The code in develop is generally quite stable, but minor regressions may occasionally occur. |
| `maintenance-v1906` ... | Bugfix branches for previous releases, should always be stable and runnable (suitable for production) |
| `maintenance-v1912` ... | Bugfix branches for previous releases, should always be stable and runnable (suitable for production) |
When a new code version is released, `master`
is renamed `maintenance-{prevRelease}` and a new `master` is created at release.
@ -45,7 +46,7 @@ cd ../ThirdParty-common
git checkout -b develop --track remotes/origin/develop
```
### ***Cautionary Note***
### ***Cautionary note***
The ThirdParty repository only contains configuration and build
scripts (and patches) for integrating third-party software.
@ -75,10 +76,8 @@ git checkout -b bugfix-ABC
```
Add functionality in the usual way, e.g. adding and committing code changes.
- For ease of integration and long-term maintenance, developed code
should observe the [OpenFOAM coding style][code-style].
- It may also be useful to note various [coding patterns][code-patterns]
during development.
@ -106,13 +105,17 @@ git branch -d feature-ABC
```
## Code Merging
## Code merging
The `master` branch should only be updated by features that ***do not break backwards compatibility with the latest release*** typically comprising bugfixes, and occasional small/modular components that are near *release-ready*.
All new capabilities should reside on their own branch until ready to be merged into the `develop` branch.
At release the `develop` branch is frozen and tested prior to merging into the `master` branch.
----
Copyright (C) 2020 OpenCFD Ltd.
[code-patterns]: /coding/patterns/patterns
[code-style]: /coding/style/style

@ -606,3 +606,8 @@ The APA style is a commonly used standard and references are available in
this format from many sources including
[Citation Machine](http://www.citationmachine.net/apa/cite-a-book) and
[Google Scholar]([http://scholar.google.com).
----
Copyright (C) 2019-2020 OpenCFD Ltd.

@ -16,10 +16,10 @@
|v1612 | [User][v1612-user] | [Developer][v1612-devel] | [Release notes][v1612-notes] |
|v1606 | [User][v1606-user] | [Developer][v1606-devel] | [Release notes][v1606-notes] |
|v3.0+ | [User][v1601-user] | [Developer][v1601-devel] | [Release notes][v1601-notes] |
|_v2012(develop)_ | [User][v2012-user] | [Developer][v2012-devel] | [Release notes][v2012-notes] |
|_v2012(develop)_ | [User][v2012-user] | [Developer][v2012-devel] | - |
## General Reference
## General reference
Developer-related pages of [Coding Patterns](/coding/patterns/patterns),
initiated Dec-2019.
@ -27,7 +27,7 @@ initiated Dec-2019.
***We are happy to incorporate content from volunteers!!***
## Repository Migration
## Repository migration
As of December 2019, the OpenFOAM repository is named [*openfoam*][foam-repo].
If you have an older version using [*OpenFOAM-plus*][old-foam-repo]
@ -39,6 +39,10 @@ as a repository, you should read information about [repository migration](/Repos
* The [postProcess upgrade](/guides/upgrade/v1612-utility-postProcess); utility and solver option.
----
Copyright (C) 2019-2020 OpenCFD Ltd.
[v2012-user]: /guides/upgrade/v2012-User-Upgrade-Guide
[v2012-devel]: /guides/upgrade/v2012-Developer-Upgrade-Guide
[v2012-notes]: https://www.openfoam.com/releases/openfoam-v2012/

@ -81,6 +81,9 @@ and run
postProcess -func sampleDict
```
----
Copyright (C) 2019-2020 OpenCFD Ltd.
[code-patterns]: /coding/patterns/patterns
[upgrade-guide]: /guides/upgrade/upgrade

@ -16,7 +16,7 @@ to the latest version of [OpenFOAM](http://www.openfoam.com).
| [![build](/icons/cpu.svg "build")](/building) [**Build**](/building) from source | Information about building and links to build or packaging systems |
| [![upgrade](/icons/chevrons-up.svg "upgrade guide")][upgrade-guide] [**Upgrade**][upgrade-guide] guides | User and developer information for upgrading cases and code to more recent releases |
| [![run](/icons/play.svg "run")](/running) [**Run**](/running) OpenFOAM | Using the OpenFOAM environment |
| [![download](/icons/download.svg "download")][download-source] [**Download**][download-source] source packs | Download shortcuts: https://dl.openfoam.com/source/ |
| [![download](/icons/download.svg "download")][download-source] [**Download**][download-source] source packs | Download shortcuts |
## [![repo](/icons/gitlab.svg "repositories")][all-repos] Repositories

@ -30,46 +30,46 @@ repositories.
You should now be able to install your preferred OpenFOAM package.
For example,
```
$ sudo apt-get install openfoam1912-default
$ sudo apt-get install openfoam2006-default
```
## OpenFOAM Debian Package Description
## OpenFOAM Debian package description
The OpenFOAM packages are currently split as follows:
- `openfoamVER-default`
- Meta package for everything normally needed.
- Includes `openfoamVER`, `openfoamVER-dev`, `openfoamVER-tutorials`
- Includes `openfoamVER`, `openfoamVER-dev`, `openfoamVER-tutorials`.
- `openfoamVER`
- The OpenFOAM runtime. Solvers, utilities and libraries.
- Solvers, utilities and libraries.
- `openfoamVER-dev`
- Source code headers and wmake build chain.
Needed for developing with OpenFOAM, but also if dynamic code
compilation is required.
- `openfoamVER-tutorials`
- tutorials
- Tutorials.
The following are normally only installed indirectly:
- `openfoamVER-common`
- Version information and share files (including the `etc/` directory)
- Version information and share files (including the `etc/` directory).
- `openfoamVER-tools`
- Binaries for OpenFOAM-specific build tools.
### Installation Locations
### Installation locations
The main OpenFOAM files are all installed under `/usr/lib/openfoam`,
which permits multiple versions to be installed simultaneously.
For example,
- `/usr/lib/openfoam/openfoam1912`.
- `/usr/lib/openfoam/openfoam2006`.
...
- `/usr/lib/openfoam/openfoam2006`
- `/usr/lib/openfoam/openfoam1912`
- ...
In addition, an OpenFOAM bash session wrapper will be created under
`/usr/bin`. For example,
- `/usr/bin/openfoam1912`
- `/usr/bin/openfoam2006`
- `/usr/bin/openfoam1912`
- ...
@ -78,17 +78,17 @@ In addition, an OpenFOAM bash session wrapper will be created under
The bash session wrapper provide the simplest means of starting
OpenFOAM immediately. For example,
```
$ openfoam1912
$ openfoam2006
```
This can be used for an interactive bash session, or to run a single
This can be used for an interactive `bash` session, or to run a single
OpenFOAM command within the OpenFOAM environment.
For a persistent OpenFOAM environment, the OpenFOAM bashrc file can be
sourced from your ~/.bashrc file by adding a line resembling the
For a persistent OpenFOAM environment, the OpenFOAM `bashrc` file can be
sourced from your `~/.bashrc` file by adding a line resembling the
following to that file:
```
source /usr/lib/openfoam/openfoam1912/etc/bashrc
source /usr/lib/openfoam/openfoam2006/etc/bashrc
```
The exact path used will change depending on the OpenFOAM version.

@ -30,17 +30,17 @@ with the following main branches:
|-------------|---------------|
| `master` | Bugfix updates since the last release, should always be stable and runnable (suitable for production) |
| `develop` | Current developments, slated for the next release. The code in develop is generally quite stable, but minor regressions may occasionally occur. |
| `maintenance-v1906` ... | Bugfix branches for previous releases, should always be stable and runnable (suitable for production) |
| `maintenance-v1912` ... | Bugfix branches for previous releases, should always be stable and runnable (suitable for production) |
| `feature-XYZ` | Work-in-progress feature branch (primarily internal use, no guarantees) |
Most people will use the `master` branch to have up-to-date bugfixes
of the current release. When a new code version is released, `master`
is renamed `maintenance-{prevRelease}` and a new `master` is created at release.
The _feature_ branches (as denoted by their prefix), have no
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 ***no*** guarantee of continuity.
`develop`, there is ***no*** guarantee of continuity.
### Exploring projects
@ -48,7 +48,7 @@ _develop_, there is ***no*** guarantee of continuity.
- From the projects menu you can navigate through various projects as shown below.
![GitLab All projects](/images/KB-GL-ADV-project-list.png)
- Selecting a project, e.g. OpenFOAM, ThirdParty, provides further details. Each project has a similar structure; the main OpenFOAM repository is shown below.
- Selecting a project, e.g. `openfoam` or `ThirdParty-common`, provides further details. Each project has a similar structure; the main OpenFOAM repository is shown below.
![GitLab OpenFOAM project](/images/KB-GL-ADV-openfoam-project.png)
- Options for managing notifications, marking favourites (starred projects), or accessing git clone features are located on the right side of webpage as shown below. See the [Cloning section](#openfoam-repositories_terminal-mode-cloning) for more information.
@ -57,7 +57,7 @@ _develop_, there is ***no*** guarantee of continuity.
- If you are looking for a one-off download for any particular branch (with no git history), browse to the required branch and select from the download options:
![GitLab download options](/images/KB-GL-ADV-project-download.png)
- Alternatively, browse a repository for files, branches, tags, etc. via the Repository section:
- Alternatively, browse a repository for files, branches, tags, etc. via the _Repository_ section:
![GitLab repository view](/images/KB-GL-ADV-openfoam-repo-view.png)
@ -65,29 +65,29 @@ _develop_, there is ***no*** guarantee of continuity.
#### Get a snapshot
- Cloning allows you to synchronize your local code with the latest developments. The address for cloning is available on the right hand side of "Project->Details" slider of the repository:
- Cloning allows you to synchronize your local code with the latest developments. The address for cloning is available on the right hand side of _Project overview -> Details_ slider of the repository:
![GitLab clone address](/images/KB-GL-ADV-project-clone-address.png)
- Clone the default _master_ branch via HTTPS using
- Clone the default `master` branch via HTTPS using
```
git clone https://develop.openfoam.com/Development/openfoam.git
```
- **Optional:** You may specify a target branch directly using
```
git clone -b <branch name> <address of git> <name of resulting directory>
git clone -b <local branch name> <git url> <name of resulting directory>
```
e.g. to clone the _develop_ branch to your local `OpenFOAM-com` directory via HTTPS:
e.g. to clone the `develop` branch to your local `OpenFOAM-com` directory via HTTPS:
```
git clone -b develop https://develop.openfoam.com/Development/openfoam.git OpenFOAM-com
```
- 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/tree/master/modules) directory:
- Since [OpenFOAM-v1712](https://www.openfoam.com/releases/openfoam-v1712), community contributions may be included using the [git submodule system](https://git-scm.com/book/en/v2/Git-Tools-Submodules). To initialise the submodules located in the [$WM_PROJECT_DIR/modules](https://develop.openfoam.com/Development/openfoam/tree/master/modules) directory:
```
git submodule init
```
The respective [Modules Readme](https://develop.openfoam.com/Development/openfoam/blob/develop/modules/README.md)
The respective [modules/README](https://develop.openfoam.com/Development/openfoam/blob/develop/modules/README.md)
contains more information.
@ -97,13 +97,12 @@ git submodule init
entire history. This makes for a smaller repository and faster cloning.
```
git clone --depth=1 https://develop.openfoam.com/Development/openfoam.git
cd openfoam
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,
depth accordingly. For example, to obtain the repository with the last 8 commits:
```
git clone --depth=8 https://develop.openfoam.com/Development/openfoam.git
```
@ -121,7 +120,7 @@ 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
Quite often it can be useful to monitor changes without actually
Quite often, it can be useful to monitor changes without actually
updating your local files:
```
git fetch
@ -139,12 +138,16 @@ git fetch
#### Adding a SSH key
If you use SSH for cloning, you can access your profile related
settings from the top-right of the browser page. Follow the steps
If you use SSH for cloning, you can access the related settings of
your profile 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-add-ssh-key.png)
![GitLab Add SSH key](/images/KB-GL-ADV-add-ssh-key.png)
----
Copyright (C) 2019-2020 OpenCFD Ltd.
[foam-repo]: https://develop.openfoam.com/Development/openfoam/

@ -19,10 +19,10 @@ the following:
Debian/Ubuntu and openSUSE generally receive first attention:
1. Debian/Ubuntu is a very popular distribution with OpenFOAM users.
2. OpenSUSE is historically our internal development platform. Since
it is an RPM-based system, it is generally possible to use a
well-crafted spec file to subsequently address RedHat-based
distributions.
2. openSUSE is historically the internal development platform of
OpenCFD Ltd. Since it is an RPM-based system, it is generally
possible to use a well-crafted spec file to subsequently address
RedHat-based distributions.
[[_TOC_]]
@ -40,7 +40,7 @@ described in [running](/running).
mechanism.
## Installation Locations
## Installation locations
<a name="locations"></a>
The packages have been designed to allow simultaneous installation of
@ -73,13 +73,13 @@ need"_ approach [more control, less diskspace]. Another group of users
prefers the _"just install everything"_ approach [less control, more
diskspace].
We have attempted to strike a reasonable balance between both. For
any given *base* package (eg, `openfoam1912` etc), there are a variant
any given *base* package (e.g., `openfoam2006` etc), there are a variant
of sub-packages (_"only-what-I-need"_), but also a `default` package for
the _"install-everything"_ folks.
Here are some common selections:
|User Group | What to install | Runtime | Compilation | Tutorials |
| User Group | What to install | Runtime | Compilation | Tutorials |
|----------------|--------------------|---------|-------------|-----------|
| minimalist | *base* | yes | no | no |
| traditional | *base*-dev (devel) | yes | yes | no |
@ -88,14 +88,14 @@ Here are some common selections:
The longer descriptions:
|Sub-Package | Description | Includes |
| Sub-Package | Description | Includes |
|---------------|--------------|----------------|
| *base* | OpenFOAM runtime (solver, utils, libraries). Double precision, int32 compilation. | *base*-common |
| *base*-dev (devel) | Development package. Source code headers and wmake build chain. Needed for developing with OpenFOAM, but also if dynamic code compilation is required. | *base*, *base*-tools |
| *base*-tutorials | Tutorials | *base*-common |
| *base*-default | Meta-package for everything potentially needed | *base*-dev (devel), *base*-tutorials |
| *base*-tools | Binaries for OpenFOAM-specific build tools for *base*-dev (devel) | *base*-common |
| *base*-common | Version information and share files | |
| *base*-default | Meta-package for everything potentially needed | *base*-dev (devel), *base*-tutorials. |
| *base*-tools | Binaries for OpenFOAM-specific build tools for *base*-dev (devel). | *base*-common |
| *base*-common | Version information and share files. | |
Note the package names for Debian and RPM packages are intentionally
@ -110,8 +110,8 @@ the same system, some installations use a meta-package structure:
| Package | Comments |
|---------------|---------------|
| openfoam | The top-level meta package that provides links and requirements for the most recent openfoam release |
| openfoam-selector | Similar to mpi-selector, used to switch active openfoam versions |
| openfoam | The top-level meta package that provides links and requirements for the most recent OpenFOAM release |
| openfoam-selector | Similar to mpi-selector, used to switch active OpenFOAM versions |
| openfoam2006 | The maintenance version for 2006 |
| openfoam1912 | The maintenance version for 1912 |
@ -122,7 +122,7 @@ The top-level `openfoam` package registers which of the
version-specific packages corresponds to the current release.
## Package Links
## Package links
<a name="packaging"></a>
|System | Links | Status | Notes |
@ -142,4 +142,9 @@ reference purposes, and to help when scripting:
| common | [openfoamVERSION.spec](/packaging/common/openfoamVERSION.spec) [rpmlintrc](/packaging/common/openfoam-rpmlintrc) | [create-tar](/packaging/common/create-tar.sh) |
| openSUSE | | |
| CentOS/RedHat | [openfoam-selector.spec](/packaging/redhat/openfoam-selector.spec) | [copr fetch](/packaging/redhat/copr-fetch.sh) |
| debian/ubuntu | | [add repo](/packaging/debian/add-debian-repo.sh) |
| Debian/Ubuntu | | [add repo](/packaging/debian/add-debian-repo.sh) |
----
Copyright (C) 2020 OpenCFD Ltd.

@ -5,23 +5,22 @@
[[_TOC_]]
![debian](/icons/debian.svg "debian")
![ubuntu](/icons/ubuntu.svg "ubuntu")
![debian](/icons/debian.svg "Debian")
![ubuntu](/icons/ubuntu.svg "Ubuntu")
## Precompiled packages - debian/ubuntu
## Precompiled packages - Debian/Ubuntu
For debian/ubuntu, OpenCFD works actively with the
For Debian/Ubuntu, OpenCFD works actively with the
[Debian (science)](https://salsa.debian.org/science-team/)
maintainers to [improve the packaging](https://salsa.debian.org/science-team/openfoam),
but also provides its own [early-release repository](https://dl.openfoam.com/repos/deb)
### OpenFOAM Debian/Ubuntu Repository
### OpenFOAM Debian/Ubuntu repository
<a name="debian-openfoam"></a>
To use the OpenFOAM early-release debian/ubuntu repository
(https://dl.openfoam.com/repos/deb), you will need to add the signing
key and the repository location(s) to your system.
To use the [OpenFOAM early-release Debian/Ubuntu repository](https://dl.openfoam.com/repos/deb),
you will need to add the signing key and the repository location(s) to your system.
This typically only needs to be done once per distribution.
The most convenient way is to use the
[installer script](https://dl.openfoam.com/add-debian-repo.sh)
@ -44,20 +43,20 @@ deb [arch=amd64] https://dl.openfoam.com/repos/deb DIST main
which means you should immediately be able to install
your preferred OpenFOAM package. For example,
```
sudo apt-get install openfoam1912-default
sudo apt-get install openfoam2006-default
```
After migrating from one version to another, you can remove the old
version with the usual commands. For example,
```
sudo apt-get autoremove openfoam1912-default
sudo apt-get autoremove openfoam2006-default
```
### Supported versions and distributions
It is too early to establish a policy about which older OpenFOAM
versions will be supported, but these should generally be covered by
the regular debian/ubuntu updates (not the early release repo).
the regular Debian/Ubuntu updates (not the early release repo).
The goal of the early release repository is to support the latest
Debian and Ubuntu LTS versions (allowing for a few months transition
@ -74,40 +73,40 @@ descriptions, the following represent typical installation commands:
|User Group | Command |
|---------------|------------------|
| minimalist | `sudo apt-get install openfoam1912` |
| traditional | `sudo apt-get install openfoam1912-dev` |
| everything | `sudo apt-get install openfoam1912-default` |
| minimalist | `sudo apt-get install openfoam2006` |
| traditional | `sudo apt-get install openfoam2006-dev` |
| everything | `sudo apt-get install openfoam2006-default` |
### Installation Locations
### Installation locations
As documented in [precompiled packages - locations](/precompiled#locations)
As documented in [precompiled packages - locations](/precompiled#locations).
### After installation - using the OpenFOAM environment
As documented in [precompiled packages - OpenFOAM environment](/precompiled#environment)
As documented in [precompiled packages - OpenFOAM environment](/precompiled#environment).
### Updates
After adding the repositories and installing a particular version of
OpenFOAM, upgrade notifications should also appear:
OpenFOAM, upgrade notifications should also appear (for example for `openfoam1912`):
![ubuntu-upgrade](/images/ubuntu-update.png)
### External Links
### External links
<a name="debian-science"></a>
Direct integration in Debian is expected to further improve in the
near future. Packages older than `1912` should be used with some
near future. Packages older than `2006` should be used with some
caution. The OpenFOAM applications are located under `/usr/bin` and
configuration files under `/usr/share/openfoam/etc`, which means that
you will need to manually define the location of the OpenFOAM
directory as follows:
```
export WM_PROJECT_DIR=/usr/share/openfoam
export WM_PROJECT_DIR=/usr/share/openfoam
```

@ -13,7 +13,7 @@
For RedHat-based systems, OpenCFD Ltd. is currently using the
[copr](https://copr.fedorainfracloud.org/) infrastructure to provide
RPM packages. Enable copr for openfoam as per the documentation shown on
RPM packages. Enable `copr` for OpenFOAM as per the documentation shown in
https://docs.pagure.org/copr.copr/how_to_enable_repo.html
For newer systems:
@ -44,22 +44,22 @@ descriptions, the following represent typical installation commands:
|User Group | Command |
|---------------|------------------|
| minimalist | `sudo yum install openfoam1912` |
| traditional | `sudo yum install openfoam1912-devel` |
| everything | `sudo yum install openfoam1912-default` |
| minimalist | `sudo yum install openfoam2006` |
| traditional | `sudo yum install openfoam2006-devel` |
| everything | `sudo yum install openfoam2006-default` |
### Installation Locations
### Installation locations
As documented in [precompiled packages - locations](/precompiled#locations)
As documented in [precompiled packages - locations](/precompiled#locations).
### After installation - using the OpenFOAM environment
As documented in [precompiled packages - OpenFOAM environment](/precompiled#environment)
As documented in [precompiled packages - OpenFOAM environment](/precompiled#environment).
### External Links
### External links
|System | Links | Status | Notes |
|---------------|--------------|----------------|---------------|

@ -11,7 +11,7 @@
For openSUSE users, OpenCFD Ltd. is a maintainer on the community
_Science Portal_ and provides RPM binary packages for the most recent
openfoam versions via its build system:
OpenFOAM versions via its build system:
https://build.opensuse.org/project/show/science
The quick access is via the download page:
@ -19,7 +19,7 @@ https://software.opensuse.org//download.html?project=science&package=openfoam
and follow the instructions there.
But note that this is a meta-package and individual version downloads are also possible.
For example,
https://software.opensuse.org//download.html?project=science&package=openfoam1912
https://software.opensuse.org//download.html?project=science&package=openfoam2006
If you already have the _Science_ repository registered on your system,
you should be able to install it directly with `zypper`:
@ -48,27 +48,26 @@ descriptions, the following represent typical installation commands:
|User Group | Command |
|---------------|------------------|
| minimalist | `sudo zypper install openfoam1912` |
| traditional | `sudo zypper install openfoam1912-devel` |
| everything | `sudo zypper install openfoam1912-default` |
| minimalist | `sudo zypper install openfoam2006` |
| traditional | `sudo zypper install openfoam2006-devel` |
| everything | `sudo zypper install openfoam2006-default` |
### Installation Locations
### Installation locations
As documented in [precompiled packages - locations](/precompiled#locations)
As documented in [precompiled packages - locations](/precompiled#locations).
### After installation - using the OpenFOAM environment
As documented in [precompiled packages - OpenFOAM environment](/precompiled#environment)
As documented in [precompiled packages - OpenFOAM environment](/precompiled#environment).
### External Links
### External links
|System | Links | Status | Notes |
|---------------|--------------|----------------|---------------|
| [openSUSE science](https://build.opensuse.org/project/show/science) | package [openfoam](https://build.opensuse.org/package/show/science/openfoam), [download](https://software.opensuse.org/download.html?project=science&package=openfoam) | Actively maintained by OpenCFD | |
---
Copyright (C) 2020 OpenCFD Ltd.

@ -35,7 +35,7 @@ $ . /path/to/openfoam/etc/bashrc
After using the desired OpenFOAM commands, the `wmUnset` alias can be
used to remove it again.
***NOTE***
***NOTE:***
The _/path/to/openfoam_ location will depend on the OpenFOAM version
and installation.
@ -55,7 +55,7 @@ OpenFOAM application from within a workflow.
### Manual
For a persistent OpenFOAM environment, the OpenFOAM bashrc file can be
For a persistent OpenFOAM environment, the OpenFOAM `bashrc` file can be
sourced from your `~/.bashrc` file by adding a line resembling the
following to that file:
```
@ -69,7 +69,7 @@ then . /path/to/openfoam/etc/bashrc
fi
```
***NOTE***
***NOTE:***
The _/path/to/openfoam_ location will depend on the OpenFOAM version
and installation.
@ -79,3 +79,9 @@ and installation.
Depending on your packaging system (or system administrator), an
[openfoam-selector](/running/openfoam-selector) may be available
to define the preferred OpenFOAM version for the ***login*** shell.
----
Copyright (C) 2019-2020 OpenCFD Ltd.

@ -4,7 +4,7 @@
[![running](/icons/play.svg "running")](/running)
The `openfoam-selector` package is used to register which
openfoam packages are installed on the system and allows the user or
OpenFOAM packages are installed on the system and allows the user or
system administrator select one of them.
[[_TOC_]]
@ -40,7 +40,7 @@ WARNING: Changes made to the openfoam-selector defaults
will not be visible until you start a new shell!
```
***NOTE*** Similar to the behaviour of the `mpi-selector`, the values
***NOTE:*** Similar to the behaviour of the `mpi-selector`, the values
registered via the `openfoam-selector` will not be activated until the
next full login. This is to avoid a possible clash of environments
when a parallel job still being launched. Of course, you can still
@ -48,3 +48,8 @@ simply source the corresponding `bashrc` file directly. For example,
```
$ source /usr/lib/openfoam/openfoam2006/etc/bashrc
```
----
Copyright (C) 2020 OpenCFD Ltd.

@ -10,33 +10,33 @@
## Introduction
Depending on your packaging system (or system administrator),
various openfoam shell sessions may be available. For example,
various OpenFOAM shell sessions may be available. For example,
```
/usr/bin/openfoam -> openfoam2006
/usr/bin/openfoam1912
/usr/bin/openfoam2006
/usr/bin/openfoam1912
```
They provide the simplest means of starting OpenFOAM immediately and
can be used for an _interactive_ bash session, or to run a single
OpenFOAM command within the OpenFOAM environment.
Using the `-help` option for the respective shell session
(eg, `openfoam2006 -help`) displays some useful information.
(e.g., `openfoam2006 -help`) displays some useful information.
## Purpose
The purpose of the OpenFOAM shell session is simply convenience.
- quickly set and use an interactive environment for OpenFOAM
- quickly set and use an interactive environment for OpenFOAM.
- use a single OpenFOAM application without preliminary setup of an
OpenFOAM environment.
- use OpenFOAM applications from a parallel installation with a
different precision.
- entrypoint for container scripts
- entrypoint for container scripts.
## Interactive
## Interactive session
Calling an OpenFOAM shell session without any arguments opens an
interactive _bash_ session with the respective OpenFOAM environment
@ -47,11 +47,11 @@ For example,
```
$ openfoam
Using: OpenFOAM-1912 - see www.openfoam.com
Using: OpenFOAM-2006 - see www.openfoam.com
Arch: linux64GccDPInt32Opt (mpi=openmpi-system)
OpenFOAM shell session - use exit to quit
OpenFOAM-1912:~/
OpenFOAM-2006:~/
mark$
```
@ -61,7 +61,7 @@ Although the OpenFOAM environment is sourced _after_ your home
references from within your `~/.bashrc` file.
## Non-interactive
## Non-interactive session
If an OpenFOAM shell session is called with arguments, it will setup
an OpenFOAM environment before executing a single command. For
@ -87,9 +87,13 @@ $ openfoam2006 -c 'echo "openfoam=$WM_PROJECT_DIR uses $WM_OPTIONS"'
yields: `openfoam=/usr/lib/openfoam/openfoam2006 uses linux64GccDPInt32Opt`
## NOTES
## Notes
- OpenFOAM shell sessions are included as part of Debian and RPM packages.
- ***Never*** attempt to embed the shell session wrapper as part of
your `~/.bashrc` - this may cause an infinite loop!
----
Copyright (C) 2020 OpenCFD Ltd.