Skip to content

Commit

Permalink
Merge pull request #212 from se-sic/dev
Browse files Browse the repository at this point in the history
Version 4.0

Merged-by: Thomas Bock <[email protected]>
  • Loading branch information
bockthom authored Sep 1, 2021
2 parents a7f4123 + bb8cd05 commit a656026
Show file tree
Hide file tree
Showing 91 changed files with 8,436 additions and 1,678 deletions.
142 changes: 142 additions & 0 deletions .drone.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
## This file is part of coronet, which is free software: you
## can redistribute it and/or modify it under the terms of the GNU General
## Public License as published by the Free Software Foundation, version 2.
##
## This program is distributed in the hope that it will be useful,
## but WITHOUT ANY WARRANTY; without even the implied warranty of
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
## GNU General Public License for more details.
##
## You should have received a copy of the GNU General Public License along
## with this program; if not, write to the Free Software Foundation, Inc.,
## 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
##
## Copyright 2020-2021 by Thomas Bock <[email protected]>
## All Rights Reserved.

# Drone CI Setup

# Pipeline "run tests"
kind: pipeline
type: docker
name: run tests

platform:
os: linux
arch: amd64

steps:
- name: R-latest
image: r-base:latest
commands: &runTests
# stop treating warnings as errors
- unset CI
# package dependencies
- apt install update -y && libudunits2-dev
# package installation
- Rscript install.R
# execute test suite
- Rscript tests.R
depends_on: [clone]

- name: R-4.1
pull: if-not-exists
image: r-base:4.1.1
commands: *runTests
depends_on: [clone]

- name: R-4.0
pull: if-not-exists
image: r-base:4.0.5
commands: *runTests
depends_on: [clone]

- name: R-3.6
pull: if-not-exists
image: r-base:3.6.3
commands: *runTests
depends_on: [clone]

- name: R-3.5
pull: if-not-exists
image: r-base:3.5.3
commands: *runTests
depends_on: [clone]

- name: R-3.4
pull: if-not-exists
image: r-base:3.4.4
commands: *runTests
depends_on: [clone]

- name: R-3.3
pull: if-not-exists
image: r-base:3.3.2
commands: *runTests
depends_on: [clone]

---
# Pipeline "run showcase file"
kind: pipeline
type: docker
name: run showcase file

platform:
os: linux
arch: amd64

steps:
- name: R-latest
image: r-base:latest
commands: &runShowcase
# stop treating warnings as errors
- unset CI
# package dependencies
- apt install update -y && libudunits2-dev
# package installation
- Rscript install.R
# execute showcase file
- Rscript showcase.R
depends_on: [clone]

- name: R-4.1
pull: if-not-exists
image: r-base:4.1.0
commands: *runShowcase
depends_on: [clone]

- name: R-4.0
pull: if-not-exists
image: r-base:4.0.5
commands: *runShowcase
depends_on: [clone]

- name: R-3.6
pull: if-not-exists
image: r-base:3.6.3
commands: *runShowcase
depends_on: [clone]

- name: R-3.5
pull: if-not-exists
image: r-base:3.5.3
commands: *runShowcase
depends_on: [clone]

- name: R-3.4
pull: if-not-exists
image: r-base:3.4.4
commands: *runShowcase
depends_on: [clone]

- name: R-3.3
pull: if-not-exists
image: r-base:3.3.2
commands: *runShowcase
depends_on: [clone]


#trigger:
# branch:
# - master
# - dev
5 changes: 3 additions & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,12 @@ Thanks for contributing to coronet!
### Prerequisites

<!-- Put an X between the brackets in any line below if you have done the task. -->
- [ ] I adhere to the coding conventions (described [here](https://github.com/se-passau/coronet/blob/master/CONTRIBUTING.md)) in my code.
- [ ] I adhere to the coding conventions (described [here](../CONTRIBUTING.md)) in my code.
- [ ] I have updated the copyright headers of the files I have modified.
- [ ] I have written appropriate commit messages, i.e., I have recorded the goal, the need, the needed changes, and the location of my code modifications for each commit. This includes also, e.g., referencing to relevant issues.
- [ ] I have put signed-off tags in *all* commits.
- [ ] I have updated the changelog file [NEWS.md](https://github.com/se-passau/coronet/blob/master/NEWS.md) appropriately.
- [ ] I have updated the changelog file [NEWS.md](../NEWS.md) appropriately.
- [ ] I have checked whether I need to adjust the showcase file `showcase.R` with respect to my changes.
- [ ] The pull request is opened against the branch `dev`.

### Description
Expand Down
17 changes: 10 additions & 7 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
<link rel="shortcut icon" type="image/png" href="logo/3.favicon_radius.png">

# Contributing to the network library `coronet`

The following is a set of guidelines for contributing to the network library `coronet`, which is hosted in the [se-sic](https://github.com/se-sic) organization on GitHub.
Expand Down Expand Up @@ -112,17 +114,18 @@ In our development process, we pursue the following idea:
- The current development will be performed on the branch `dev`, i.e., all incoming pull requests are against this branch.

The current build status is as follows:
- `master`: [![Build Status](https://travis-ci.com/se-sic/coronet.svg?token=8VFPdy2kjPXtstT72yww&branch=master)](https://travis-ci.com/se-sic/coronet)
- `dev`: [![Build Status](https://travis-ci.com/se-sic/coronet.svg?token=8VFPdy2kjPXtstT72yww&branch=dev)](https://travis-ci.com/se-sic/coronet)

- `master`: [![Build Status](https://cloud.drone.io/api/badges/se-sic/coronet/status.svg)](https://cloud.drone.io/se-sic/coronet)
- `dev`: [![Build Status](https://cloud.drone.io/api/badges/se-sic/coronet/status.svg?ref=refs/heads/dev)](https://cloud.drone.io/se-sic/coronet)

### Pull Requests

* Do not include issue numbers in the PR title, but rather in the PR message body.
* Base your changes on the current `dev` branch and open your PR against the `dev` branch.
* Follow the [style conventions](#style-conventions).
* Document new code and provide proper tests.
* Document new code and provide proper tests (for a detailed description of the test projects see the [test-README](tests/README.md)).
* Add your enhancements and fixes to the [changelog file](NEWS.md).
* Add yourself to the copyright headers in the files you changed/added.
* Check whether the showcase file `showcase.R` needs to be adjusted to your changes. If so, update the showcase file accordingly.
* End all files with a newline.
* Merge policy:
* Tests must run successfully.
Expand Down Expand Up @@ -165,7 +168,7 @@ There will be another checklist for you when you open an actual pull request pro

### R Coding Conventions

* Use [Google's style guide for R](https://google.github.io/styleguide/Rguide.xml) as a start.
* Use [Google's style guide for R](https://google.github.io/styleguide/Rguide.xml) as a start. Recently, Google has, unfortunately, changed its naming conventions, but coronet still uses the previously established naming conventions, which can be found [here](https://github.com/google/styleguide/blob/505ba68c74eb97e6966f60907ce893001bedc706/Rguide.xml).
* Additionally or, rather, in contrast, we settle on the following style:
* **indentation width**: 4 spaces,
* **line length**: more than 80 characters are allowed, 120 characters should be the maximum,
Expand All @@ -192,7 +195,7 @@ There will be another checklist for you when you open an actual pull request pro
* For each parameter of a function or method, a parameter description (`@param parameter.name description`) must be added. The same holds for descriptions of return values (`@return description`) – if something is returned. For both items, the descriptions should always be a phrase (i.e., no verbs should be used), should start with a lower-case letter, and should *not* end with a period – *unless* there are further phrases or sentences following. If the description covers multiple lines, all but the first lines are indented along the start of the description in the first line.
* For parameters that take a default value, the default value must be placed directly after the description of the parameter using the following format: `[default: value]`.
**Note:** As `value` usually is code, we omit the `\code{...}` notation within `[default: ...]`.
* Add references to notable other classes, methods, constants, and functions using `@seealso reference`. As `reference` usually is code, we omit the `\code{...}` notation for it.
* Add references to notable other classes, methods, constants, and functions using `@seealso reference`. As `reference` usually is code, we omit the `\code{...}` notation for it.
* Example for a function/method documentation:
```R
#' Group the data items of the given \code{data.source} by the given \code{group.column}.
Expand Down Expand Up @@ -228,7 +231,7 @@ There will be another checklist for you when you open an actual pull request pro
}
```
* For all other stuff, look at the source code and get inspired.
* Also **add tests** to the test suite for each new functionality you add!
* Also **add tests** to the test suite for each new functionality you add! Also update the showcase file to exemplarily demonstrate how the new functionality can be used.
* Keep the code as simple as possible. So, for example, no complex computation inside the `return` statement.


Expand Down
Loading

0 comments on commit a656026

Please sign in to comment.