Skip to content

Commit

Permalink
Merge pull request #3375 from PecanProject/master-to-main
Browse files Browse the repository at this point in the history
rename master to main/latest
  • Loading branch information
infotroph authored Sep 9, 2024
2 parents dae0f67 + dc486fe commit 79e32f4
Show file tree
Hide file tree
Showing 45 changed files with 82 additions and 181 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/book.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: renderbook
on:
push:
branches:
- master
- main
- develop
tags:
- '*'
Expand Down Expand Up @@ -65,9 +65,12 @@ jobs:
git config --global user.email "[email protected]"
git config --global user.name "GitHub Documentation Robot"
export VERSION=$(echo $GITHUB_REF | sed 's,.*/,,' )
if [ "$VERSION" == "main" ]; then
export VERSION=latest
fi
cd pecan-documentation
mkdir -p $VERSION
rsync -a --delete ../book_source/_book/ ${VERSION}/
git add --all *
git commit -m "Build book from pecan revision ${GITHUB_SHA}" || true
git push -q origin master
git push -q origin main
5 changes: 2 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@ name: CI
on:
push:
branches:
- master
- main
- develop

tags:
- '*'
- "v*.*.*"
pull_request:
merge_group:
issue_comment:
Expand Down
102 changes: 0 additions & 102 deletions .github/workflows/depends.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ on:
push:
branches:
- main
- master
- develop
tags:
- "v*.*.*"
pull_request:
merge_group:
workflow_dispatch:
inputs:
r_version:
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ For more information about this file see also [Keep a Changelog](http://keepacha
* Base packages `PEcAn.all`, `PEcAn.DB`, `PEcAn.QAQC`, `PEcAn.remote`, `PEcAn.settings`, `PEcAn.visualization`, and `PEcAn.workflow`
* Model packages `PEcAn.BASGRA`, `PEcAn.CLM45`, `PEcAn.DALEC`, `PEcAn.dvmdostem`, `PEcAn.FATES`, `PEcAn.GDAY`, `PEcAn.JULES`, `PEcAn.LDNDC`, `PEcAn.LINKAGES`, `PEcAn.LPJGUESS`, `PEcAn.MAAT`, `PEcAn.MAESPA`, `PEcAn.PRELES`, `PEcAn.SIBCASA`, `PEcAn.SIPNET`, `PEcAn.STICS`, and the new model package template.
* Modules `PEcAn.allometry`, `PEcAn.assim.batch`, `PEcAn.data.mining`, `PEcAn.emulator`, `PEcAn.MA`, `PEcAn.photosynthesis`, `PEcAn.priors`, and `PEcAn.RTM`.
- Renamed master branch to main

### Removed

Expand Down
14 changes: 7 additions & 7 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,21 +45,21 @@ Switch pecan to your fork
git remote set-url origin https://github.com/<your username>/pecan.git
```

Setup pecan to be able to fetch from the master/develop
Setup pecan to be able to fetch from the main/develop

```bash
git remote add upstream https://github.com/PecanProject/pecan.git
```

## PEcAn Branches

PEcAn uses two protected branches, the master branch and the develop branch. The master branch will match the official releases, but all work will be done on the develop branch. Make sure that you create branches from the develop branch. This should be the default branch in your git repository.
PEcAn uses two protected branches, the main branch and the develop branch. The main branch will match the official releases, but all work will be done on the develop branch. Make sure that you create branches from the develop branch. This should be the default branch in your git repository.

## Adding Features

When you add a new feature always create an issue first, this allows others to comment and give you tips. It will also help us keep track of what people are adding and with new releases helps us to write new release notes and give you credit for your work.

Secondly always work in a branch, never work on the master or develop branch. Keep your master and develop branch in sync with the master and develop of the official PEcAn repository. This makes the pull requests (you do want your work to be in the main branch right?) easier for us.
Secondly always work in a branch, never work on the main or develop branch. Keep your main and develop branch in sync with the main and develop of the official PEcAn repository. This makes the pull requests (you do want your work to be in the main branch right?) easier for us.

Finally try to keep your branches focused on fixing/adding only one feature and try not fall in the trap of doing a lot of things in a single branch. This will not only make it harder for us to process your pull request but makes it take longer before you can submit your pull request. Small pull requests are more likely to be looked at faster and pulled into the develop branch faster.

Expand Down Expand Up @@ -112,7 +112,7 @@ git push -u origin GH-issuenumber-title-of-issue

## Additional Resources

- [Adding models to PEcAn](https://pecanproject.github.io/pecan-documentation/master/adding-an-ecosystem-model.html)
- [PEcAn configuration files](https://pecanproject.github.io/pecan-documentation/master/pecan-xml-configuration.html)
- [Development help](https://pecanproject.github.io/pecan-documentation/master/developer-guide.html)
- [PEcAn Code of Conduct](https://pecanproject.github.io/pecan-documentation/master/contributor-covenant-code-of-conduct.html)
- [Adding models to PEcAn](https://pecanproject.github.io/pecan-documentation/latest/adding-an-ecosystem-model.html)
- [PEcAn configuration files](https://pecanproject.github.io/pecan-documentation/latest/pecan-xml-configuration.html)
- [Development help](https://pecanproject.github.io/pecan-documentation/latest/developer-guide.html)
- [PEcAn Code of Conduct](https://pecanproject.github.io/pecan-documentation/latest/contributor-covenant-code-of-conduct.html)
6 changes: 3 additions & 3 deletions DEV-INTRO.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# PEcAn Development

This is a minimal guide to getting started with PEcAn development under Docker. You can find more information about docker in the [pecan documentation](https://pecanproject.github.io/pecan-documentation/master/docker-index.html).
This is a minimal guide to getting started with PEcAn development under Docker. You can find more information about docker in the [pecan documentation](https://pecanproject.github.io/pecan-documentation/latest/docker-index.html).

## Requirements and Recommendations

Expand Down Expand Up @@ -29,7 +29,7 @@ cd pecan

## Developing in Docker

The use of Docker in PEcAn is described in detail in the [PEcAn documentation](https://pecanproject.github.io/pecan-documentation/master/docker-index.html). This is intended as a quick start.
The use of Docker in PEcAn is described in detail in the [PEcAn documentation](https://pecanproject.github.io/pecan-documentation/latest/docker-index.html). This is intended as a quick start.

### Installing Docker

Expand Down Expand Up @@ -61,7 +61,7 @@ You can now use the command `docker compose` to work with the containers setup f

### First time setup

The steps in this section only need to be done the first time you start working with the stack in docker. After this is done you can skip these steps. You can find more detail about the docker commands in the [pecan documentation](https://pecanproject.github.io/pecan-documentation/master/docker-index.html).
The steps in this section only need to be done the first time you start working with the stack in docker. After this is done you can skip these steps. You can find more detail about the docker commands in the [pecan documentation](https://pecanproject.github.io/pecan-documentation/latest/docker-index.html).

- setup .env file
- create folders to hold the data
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ PEcAn is not itself an ecosystem model, and it can be used to with a variety of

## Documentation

Consult documentation of the PEcAn Project; either the [latest stable development](https://pecanproject.github.io/pecan-documentation/develop/) branch, the latest [release](https://pecanproject.github.io/pecan-documentation/master/). Documentation from [earlier releases is here](https://pecanproject.github.io/documentation.html).
Consult documentation of the PEcAn Project; either the [latest stable development](https://pecanproject.github.io/pecan-documentation/develop/) branch, the latest [release](https://pecanproject.github.io/pecan-documentation/latest/). Documentation from [earlier releases is here](https://pecanproject.github.io/documentation.html).

## Getting Started

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ This will not go into much detail about about how to use Docker -- for more deta
This should print the current version of docker-compose. We have tested the instruction below with versions of docker compose 1.22 and above.
3. **Download the PEcAn docker compose file**. It is located in the root directory of the [PEcAn source code](https://github.com/pecanproject/pecan). For reference, here are direct links to the [latest stable version](https://raw.githubusercontent.com/PecanProject/pecan/master/docker-compose.yml) and the [bleeding edge development version](https://raw.githubusercontent.com/PecanProject/pecan/develop/docker-compose.yml). (To download the files, you should be able to right click the link and select "Save link as".) Make sure the file is saved as `docker-compose.yml` in a directory called `pecan`.
3. **Download the PEcAn docker compose file**. It is located in the root directory of the [PEcAn source code](https://github.com/pecanproject/pecan). For reference, here are direct links to the [latest stable version](https://raw.githubusercontent.com/PecanProject/pecan/main/docker-compose.yml) and the [bleeding edge development version](https://raw.githubusercontent.com/PecanProject/pecan/develop/docker-compose.yml). (To download the files, you should be able to right click the link and select "Save link as".) Make sure the file is saved as `docker-compose.yml` in a directory called `pecan`.
4. **Initialize the PEcAn database and data images**. The following `docker compose` commands are used to download all the data PEcAn needs to start working. For more on how they work, see our [Docker topical pages](#pecan-docker-quickstart-init).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,16 @@ The following Tutorials assume you have installed PEcAn. If you have not, please
|Type|Title|Web Link| Source Rmd|
|:--:|:---:|:------:|:---------:|
|Demo| Basic Run| [html](#demo-1) | [Rmd](https://github.com/PecanProject/pecan/blob/develop/documentation/tutorials/01_Demo_Basic_Run/Demo01.Rmd)|
|Demo| Uncertainty Analysis| [html](#demo-2) | [Rmd](https://github.com/PecanProject/pecan/tree/master/documentation/tutorials/02_Demo_Uncertainty_Analysis)|
|Demo| Uncertainty Analysis| [html](#demo-2) | [Rmd](https://github.com/PecanProject/pecan/tree/main/documentation/tutorials/02_Demo_Uncertainty_Analysis)|
|Demo| Output Analysis|html |[Rmd](https://github.com/PecanProject/pecan/tree/develop/documentation/tutorials/AnalyzeOutput)|
|Demo| MCMC |html|[Rmd](https://github.com/PecanProject/pecan/tree/develop/documentation/tutorials/MCMC)|
|Demo|Parameter Assimilation |html |[Rmd](https://github.com/PecanProject/pecan/tree/develop/documentation/tutorials/ParameterAssimilation)|
|Demo|State Assimilation|html|[Rmd](https://github.com/PecanProject/pecan/tree/develop/documentation/tutorials/StateAssimilation)|
|Demo| Sensitivity|html|[Rmd](https://github.com/PecanProject/pecan/tree/develop/documentation/tutorials/sensitivity)|
|Vignette|Allometries|html|[Rmd](https://github.com/PecanProject/pecan/blob/master/modules/allometry/vignettes/AllomVignette.Rmd)|
|Vignette|MCMC|html|[Rmd](https://github.com/PecanProject/pecan/blob/master/modules/assim.batch/vignettes/AssimBatchVignette.Rmd)|
|Vignette|Meteorological Data|html|[Rmd](https://github.com/PecanProject/pecan/tree/master/modules/data.atmosphere/vignettes)|
|Vignette|Meta-Analysis|html|[Rmd](https://github.com/PecanProject/pecan/blob/master/modules/meta.analysis/vignettes/single.MA_demo.Rmd)|
|Vignette|Photosynthetic Response Curves|html|[Rmd](https://github.com/PecanProject/pecan/blob/master/modules/photosynthesis/vignettes/ResponseCurves.Rmd)|
|Vignette|Priors|html|[Rmd](https://github.com/PecanProject/pecan/blob/master/modules/priors/vignettes/priors_demo.Rmd)|
|Vignette|Leaf Spectra:PROSPECT inversion|html|[Rmd](https://github.com/PecanProject/pecan/blob/master/modules/rtm/vignettes/pecanrtm.vignette.Rmd)|
|Vignette|Allometries|html|[Rmd](https://github.com/PecanProject/pecan/blob/main/modules/allometry/vignettes/AllomVignette.Rmd)|
|Vignette|MCMC|html|[Rmd](https://github.com/PecanProject/pecan/blob/main/modules/assim.batch/vignettes/AssimBatchVignette.Rmd)|
|Vignette|Meteorological Data|html|[Rmd](https://github.com/PecanProject/pecan/tree/main/modules/data.atmosphere/vignettes)|
|Vignette|Meta-Analysis|html|[Rmd](https://github.com/PecanProject/pecan/blob/main/modules/meta.analysis/vignettes/single.MA_demo.Rmd)|
|Vignette|Photosynthetic Response Curves|html|[Rmd](https://github.com/PecanProject/pecan/blob/main/modules/photosynthesis/vignettes/ResponseCurves.Rmd)|
|Vignette|Priors|html|[Rmd](https://github.com/PecanProject/pecan/blob/main/modules/priors/vignettes/priors_demo.Rmd)|
|Vignette|Leaf Spectra:PROSPECT inversion|html|[Rmd](https://github.com/PecanProject/pecan/blob/main/modules/rtm/vignettes/pecanrtm.vignette.Rmd)|
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ At the moment, what is functional is a prototype workflow that works for invento
This tool works with an internal copy of the FIA that is uploaded to a postGRES database along side BETY, however for space reasons this database does not ship with the PEcAn VM. To turn this feature on:

1. Download and Install the FIA database. Instructions in [Installing data for PEcAn]
2. For web-base runs, specify the database settings in the [config.php](https://github.com/PecanProject/pecan/blob/master/web/config.example.php)
2. For web-base runs, specify the database settings in the [config.php](https://github.com/PecanProject/pecan/blob/main/web/config.example.php)
3. For R-based runs, specify the database settings in the [THE PEcAn XML]

More detailed information on how PEcAn processes inputs can be found on our [Input Conversion]page.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ We follow branch organization laid out on [this page](http://nvie.com/posts/a-su
In short, there are three main branches you must be aware of:

* **develop** - Main Branch containing the latest code. This is the main branch you will make changes to.
* **master** - Branch containing the latest stable code. DO NOT MAKE CHANGES TO THIS BRANCH.
* **main** - Branch containing the latest stable code. DO NOT MAKE CHANGES TO THIS BRANCH.
* **release/vX.X.X** - Named branches containing code specific to a release. Only make changes to this branch if you are fixing a bug on a release branch.

#### Milestones, Issues, Tasks
Expand Down Expand Up @@ -121,7 +121,7 @@ git remote add upstream [email protected]:PecanProject/pecan.git

##### Hint: Keeping your fork in sync

If you have used the instructions above, you can use the helper script called [`scripts/syncgit.sh`](https://github.com/PecanProject/pecan/blob/master/scripts/syncgit.sh) to keep the master and develop branches of your own fork in sync with the PEcAnProject/pecan repository.
If you have used the instructions above, you can use the helper script called [`scripts/syncgit.sh`](https://github.com/PecanProject/pecan/blob/main/scripts/syncgit.sh) to keep the main and develop branches of your own fork in sync with the PEcAnProject/pecan repository.

After following the above, your .git/config file will include the following:

Expand All @@ -144,7 +144,7 @@ Then, you can run:
./scripts/syncgit.sh
```

Now the master and develop branches on your fork will be up to date.
Now the main and develop branches on your fork will be up to date.

#### Using Branching

Expand Down Expand Up @@ -199,7 +199,7 @@ git push origin <branchname>

#### After pull request is merged

1. Make sure you start in master
1. Make sure you start in main

```sh
git checkout develop`
Expand Down
2 changes: 1 addition & 1 deletion book_source/03_topical_pages/03_pecan_xml.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ PEcAn tries to detect and throw informative errors when dates are out of bounds

The following tags are optional run settings that apply to any model:

* `jobtemplate`: the template used when creating a `job.sh` file, which is used to launch the actual model. Each model has its own default template in the `inst` folder of the corresponding R package (for instance, here is the one for [ED2](https://github.com/PecanProject/pecan/blob/master/models/ed/inst/template.job)). The following variables can be used: `@SITE_LAT@`, `@SITE_LON@`, `@SITE_MET@`, `@START_DATE@`, `@END_DATE@`, `@OUTDIR@`, `@RUNDIR@` which all come variables in the `pecan.xml` file. The following two command can be used to copy and clean the results from a scratch folder (specified as scratch in the run section below, for example local disk vs network disk) : `@SCRATCH_COPY@`, `@SCRATCH_CLEAR@`.
* `jobtemplate`: the template used when creating a `job.sh` file, which is used to launch the actual model. Each model has its own default template in the `inst` folder of the corresponding R package (for instance, here is the one for [ED2](https://github.com/PecanProject/pecan/blob/main/models/ed/inst/template.job)). The following variables can be used: `@SITE_LAT@`, `@SITE_LON@`, `@SITE_MET@`, `@START_DATE@`, `@END_DATE@`, `@OUTDIR@`, `@RUNDIR@` which all come variables in the `pecan.xml` file. The following two command can be used to copy and clean the results from a scratch folder (specified as scratch in the run section below, for example local disk vs network disk) : `@SCRATCH_COPY@`, `@SCRATCH_CLEAR@`.

* `stop_on_error`: (logical) Whether the workflow should immediately terminate if _any_ of the model runs fail. If unset, this defaults to `TRUE` unless you are running an ensemble simulation (and ensemble size is greater than 1).

Expand Down
Loading

0 comments on commit 79e32f4

Please sign in to comment.