Skip to content

Commit f24c77f

Browse files
committed
Set up for GitHub CI and Maven Central.
1 parent 338b128 commit f24c77f

File tree

13 files changed

+202
-45
lines changed

13 files changed

+202
-45
lines changed

.github/workflows/maven.yml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# This workflow will build a Java project with Maven
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
3+
4+
name: Java CI with Maven
5+
6+
on:
7+
push:
8+
branches: [ master, dev ]
9+
pull_request:
10+
branches: [ master ]
11+
12+
jobs:
13+
build:
14+
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
20+
- uses: actions/cache@v1
21+
with:
22+
path: ~/.m2/repository
23+
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
24+
restore-keys: |
25+
${{ runner.os }}-maven-
26+
27+
- name: Set up JDK 1.8
28+
uses: actions/setup-java@v1
29+
with:
30+
java-version: 1.8
31+
32+
# Release jar files to Maven Central repository
33+
- name: Release Maven package
34+
uses: samuelmeuli/action-maven-publish@v1
35+
with:
36+
gpg_private_key: ${{ secrets.gpg_private_key }}
37+
gpg_passphrase: ${{ secrets.gpg_passphrase }}
38+
nexus_username: ${{ secrets.nexus_username }}
39+
nexus_password: ${{ secrets.nexus_password }}
40+
41+
# Submit code coverage information to codecov.io
42+
- name: Codecov
43+
uses: codecov/[email protected]

README.md

+23-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,23 @@
1-
# population-records
1+
# population-records
2+
3+
This project provides some Java utility classes for manipulating population records as encrypted datasets, using the [ciesvium](/stacs-srg/ciesvium) package.
4+
5+
![Java CI with Maven](https://github.com/stacs-srg/population-records/workflows/Java%20CI%20with%20Maven/badge.svg)
6+
[![javadoc](https://javadoc.io/badge2/com.github.stacs-srg/population-records/javadoc.svg)](https://javadoc.io/doc/com.github.stacs-srg/ciesvium)
7+
[![codecov](https://codecov.io/gh/stacs-srg/population-records/branch/master/graph/badge.svg)](https://codecov.io/gh/stacs-srg/ciesvium)
8+
[![Maintainability](https://api.codeclimate.com/v1/badges/127f0819b34286df2307/maintainability)](https://codeclimate.com/github/stacs-srg/ciesvium/maintainability)
9+
10+
## Usage via maven
11+
12+
```
13+
<dependency>
14+
<groupId>com.github.stacs-srg</groupId>
15+
<artifactId>population-records</artifactId>
16+
<version>1.0.0</version>
17+
</dependency>
18+
```
19+
20+
## See also
21+
22+
* [API documentation](https://javadoc.io/doc/com.github.stacs-srg/population-records)
23+
* [relevant Maven goals](https://github.com/stacs-srg/hub/tree/master/maven) (private)

pom.xml

+33-19
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,60 @@
1+
<!--
2+
3+
Copyright 2020 Systems Research Group, University of St Andrews:
4+
<https://github.com/stacs-srg>
5+
6+
This file is part of the module population-records.
7+
8+
population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
9+
License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
10+
version.
11+
12+
population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
13+
warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
14+
15+
You should have received a copy of the GNU General Public License along with population-records. If not, see
16+
<http://www.gnu.org/licenses/>.
17+
18+
-->
119
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
220
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
321
<modelVersion>4.0.0</modelVersion>
422

523
<parent>
6-
<groupId>uk.ac.standrews.cs</groupId>
24+
<groupId>com.github.stacs-srg</groupId>
725
<artifactId>common-pom</artifactId>
8-
<version>3.0-SNAPSHOT</version>
26+
<version>1.0.1</version>
927
</parent>
1028

1129
<artifactId>population-records</artifactId>
12-
<version>1.0-SNAPSHOT</version>
30+
<version>1.0.0</version>
1331
<packaging>jar</packaging>
1432
<name>population-records</name>
1533

16-
<description>Population Records</description>
34+
<description>Utilities for manipulating population records</description>
35+
<url>https://stacs-srg.github.io/ciesvium/</url>
1736
<inceptionYear>2018</inceptionYear>
1837

38+
<scm>
39+
<connection>scm:git:git://github.com/stacs-srg/population-records.git</connection>
40+
<developerConnection>scm:git:ssh://github.com:stacs-srg/population-records.git</developerConnection>
41+
<url>https://github.com/stacs-srg/population-records/tree/master</url>
42+
</scm>
43+
1944
<dependencies>
2045

2146
<dependency>
22-
<groupId>uk.ac.standrews.cs</groupId>
47+
<groupId>com.github.stacs-srg</groupId>
2348
<artifactId>storr</artifactId>
24-
<version>1.0-SNAPSHOT</version>
49+
<version>1.0.1</version>
2550
</dependency>
2651

2752
<dependency>
28-
<groupId>uk.ac.standrews.cs</groupId>
53+
<groupId>com.github.stacs-srg</groupId>
2954
<artifactId>ciesvium</artifactId>
30-
<version>1.0-SNAPSHOT</version>
55+
<version>1.0.0</version>
3156
</dependency>
3257

3358
</dependencies>
3459

35-
<repositories>
36-
37-
<!-- This has to be replicated from the parent POM so the parent POM can be found. -->
38-
<repository>
39-
<id>uk.ac.standrews.cs.maven.repository</id>
40-
<name>School of Computer Science Maven Repository</name>
41-
<url>https://maven.cs.st-andrews.ac.uk/</url>
42-
</repository>
43-
44-
</repositories>
45-
4660
</project>

src/main/java/uk/ac/standrews/cs/population_records/Normalisation.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
/*
2-
* Copyright 2017 Systems Research Group, University of St Andrews:
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
33
* <https://github.com/stacs-srg>
44
*
5-
* This file is part of the module linkage-java.
5+
* This file is part of the module population-records.
66
*
7-
* linkage-java is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
88
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
99
* version.
1010
*
11-
* linkage-java is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
1212
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
1313
*
14-
* You should have received a copy of the GNU General Public License along with linkage-java. If not, see
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
1515
* <http://www.gnu.org/licenses/>.
1616
*/
1717
package uk.ac.standrews.cs.population_records;

src/main/java/uk/ac/standrews/cs/population_records/PopulationDataSet.java

+16
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
3+
* <https://github.com/stacs-srg>
4+
*
5+
* This file is part of the module population-records.
6+
*
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
8+
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
9+
* version.
10+
*
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
12+
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
15+
* <http://www.gnu.org/licenses/>.
16+
*/
117
package uk.ac.standrews.cs.population_records;
218

319
import uk.ac.standrews.cs.population_records.record_types.Birth;

src/main/java/uk/ac/standrews/cs/population_records/RecordRepository.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
/*
2-
* Copyright 2017 Systems Research Group, University of St Andrews:
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
33
* <https://github.com/stacs-srg>
44
*
5-
* This file is part of the module linkage-java.
5+
* This file is part of the module population-records.
66
*
7-
* linkage-java is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
88
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
99
* version.
1010
*
11-
* linkage-java is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
1212
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
1313
*
14-
* You should have received a copy of the GNU General Public License along with linkage-java. If not, see
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
1515
* <http://www.gnu.org/licenses/>.
1616
*/
1717
package uk.ac.standrews.cs.population_records;

src/main/java/uk/ac/standrews/cs/population_records/record_types/Birth.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
/*
2-
* Copyright 2017 Systems Research Group, University of St Andrews:
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
33
* <https://github.com/stacs-srg>
44
*
5-
* This file is part of the module linkage-java.
5+
* This file is part of the module population-records.
66
*
7-
* linkage-java is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
88
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
99
* version.
1010
*
11-
* linkage-java is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
1212
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
1313
*
14-
* You should have received a copy of the GNU General Public License along with linkage-java. If not, see
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
1515
* <http://www.gnu.org/licenses/>.
1616
*/
1717
package uk.ac.standrews.cs.population_records.record_types;

src/main/java/uk/ac/standrews/cs/population_records/record_types/Death.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
/*
2-
* Copyright 2017 Systems Research Group, University of St Andrews:
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
33
* <https://github.com/stacs-srg>
44
*
5-
* This file is part of the module linkage-java.
5+
* This file is part of the module population-records.
66
*
7-
* linkage-java is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
88
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
99
* version.
1010
*
11-
* linkage-java is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
1212
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
1313
*
14-
* You should have received a copy of the GNU General Public License along with linkage-java. If not, see
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
1515
* <http://www.gnu.org/licenses/>.
1616
*/
1717
package uk.ac.standrews.cs.population_records.record_types;

src/main/java/uk/ac/standrews/cs/population_records/record_types/Marriage.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
/*
2-
* Copyright 2017 Systems Research Group, University of St Andrews:
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
33
* <https://github.com/stacs-srg>
44
*
5-
* This file is part of the module linkage-java.
5+
* This file is part of the module population-records.
66
*
7-
* linkage-java is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
88
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
99
* version.
1010
*
11-
* linkage-java is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
1212
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
1313
*
14-
* You should have received a copy of the GNU General Public License along with linkage-java. If not, see
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
1515
* <http://www.gnu.org/licenses/>.
1616
*/
1717
package uk.ac.standrews.cs.population_records.record_types;

src/main/java/uk/ac/standrews/cs/population_records/record_types/Utilities.java

+16
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
3+
* <https://github.com/stacs-srg>
4+
*
5+
* This file is part of the module population-records.
6+
*
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
8+
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
9+
* version.
10+
*
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
12+
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
15+
* <http://www.gnu.org/licenses/>.
16+
*/
117
package uk.ac.standrews.cs.population_records.record_types;
218

319
import uk.ac.standrews.cs.storr.impl.LXP;
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?xml version="1.0" encoding="ISO-8859-1"?>
2+
<additionalHeaders xmlns="http://exslt.org/common">
3+
<java_style>
4+
<!-- This custom style is used to override the default formatting for Java files,
5+
which uses Javadoc format, therefore causing confusion with the actual class-level
6+
Javadoc. This format puts a single asterix in the first line rather than two. -->
7+
<firstLine>/*</firstLine>
8+
<beforeEachLine> * </beforeEachLine>
9+
<endLine> */</endLine>
10+
<firstLineDetectionPattern>(\s|\t)*/\*.*$</firstLineDetectionPattern>
11+
<lastLineDetectionPattern>.*\*/(\s|\t)*$</lastLineDetectionPattern>
12+
<allowBlankLines>false</allowBlankLines>
13+
<isMultiline>true</isMultiline>
14+
<padLines>false</padLines>
15+
</java_style>
16+
</additionalHeaders>
+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
Copyright 2020 Systems Research Group, University of St Andrews:
2+
<https://github.com/stacs-srg>
3+
4+
This file is part of the module ${project.name}.
5+
6+
${project.name} is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
7+
License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
8+
version.
9+
10+
${project.name} is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
11+
warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
12+
13+
You should have received a copy of the GNU General Public License along with ${project.name}. If not, see
14+
<http://www.gnu.org/licenses/>.

src/test/java/uk/ac/standrews/cs/population_records/NormalisationTest.java

+16
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/*
2+
* Copyright 2020 Systems Research Group, University of St Andrews:
3+
* <https://github.com/stacs-srg>
4+
*
5+
* This file is part of the module population-records.
6+
*
7+
* population-records is free software: you can redistribute it and/or modify it under the terms of the GNU General Public
8+
* License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later
9+
* version.
10+
*
11+
* population-records is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
12+
* warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
13+
*
14+
* You should have received a copy of the GNU General Public License along with population-records. If not, see
15+
* <http://www.gnu.org/licenses/>.
16+
*/
117
package uk.ac.standrews.cs.population_records;
218

319
import org.junit.Test;

0 commit comments

Comments
 (0)