Skip to content

Commit 79e354b

Browse files
committed
Merge branch 'release/1.1.0.0'
2 parents 9b15be7 + dcb84a4 commit 79e354b

47 files changed

Lines changed: 2968 additions & 2301 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.ghci

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
1-
:set -fwarn-unused-binds -fwarn-unused-imports
1+
:set -fwarn-unused-imports
2+
:unset -fwarn-unused-top-binds
3+
:unset -fwarn-unused-local-binds
24
:set -isrc

.ghcid

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
--command=stack ghci

.travis.yml

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,34 @@ before_install:
4040
curl -sS -ostack.zip -L --insecure https://get.haskellstack.org/stable/windows-x86_64.zip
4141
7z x windows-x86_64.zip stack.exe
4242
fi
43+
stack install hlint
4344
4445
install:
4546
# Build dependencies
4647
- stack --no-terminal --install-ghc test --only-dependencies
4748

4849
script:
49-
# Build the package, its tests, and its docs and run the tests
50-
# - stack --no-terminal test --haddock --no-haddock-deps
51-
- stack --no-terminal test # --haddock --no-haddock-deps
50+
- hlint .
51+
- stack --no-terminal test
52+
53+
jobs:
54+
include:
55+
- stage: Deploy Haddock
56+
os: linux
57+
script:
58+
- stack --no-terminal test --haddock --no-haddock-deps
59+
- mkdir docs
60+
- ls
61+
- stack path --local-doc-root
62+
- ls `stack path --local-doc-root`
63+
- mv `stack path --local-doc-root` docs/haddock
64+
deploy:
65+
provider: pages
66+
skip_cleanup: true
67+
github_token: $GITHUB_TOKEN
68+
on:
69+
all_branches: true
70+
local_dir: docs/haddock
5271

5372
notifications:
5473
email:

.vscode/settings.json

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
{
2+
"cSpell.enabledLanguageIds": [
3+
"asciidoc",
4+
"c",
5+
"cpp",
6+
"csharp",
7+
"css",
8+
"go",
9+
"handlebars",
10+
"html",
11+
"jade",
12+
"javascript",
13+
"javascriptreact",
14+
"json",
15+
"latex",
16+
"less",
17+
"markdown",
18+
"php",
19+
"pub",
20+
"python",
21+
"restructuredtext",
22+
"rust",
23+
"scss",
24+
"text",
25+
"typescript",
26+
"typescriptreact",
27+
"yml"
28+
]
29+
}

Dockerfile

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
FROM fpco/stack-build:lts-13.19 as builder
2+
RUN mkdir /opt/build
3+
COPY . /opt/build
4+
RUN cd /opt/build && stack install --system-ghc -j1
5+
6+
FROM ubuntu:16.04
7+
RUN mkdir -p /opt/myapp
8+
WORKDIR /opt/myapp
9+
ARG BINARY_PATH
10+
RUN mkdir -p /semester
11+
RUN apt-get update && apt-get install -y \
12+
ca-certificates \
13+
libgmp-dev
14+
# NOTICE THIS LINE
15+
COPY --from=builder /root/.local/bin/plexams .
16+
COPY --from=builder /root/.local/bin/plexams-helper .
17+
COPY --from=builder /root/.local/bin/plexams-server .
18+
WORKDIR /semester
19+
CMD ["/opt/myapp/plexams-server"]

Jenkinsfile

Lines changed: 25 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,34 @@
11
pipeline {
2-
agent any
3-
2+
agent none
43
stages {
54
stage('Build') {
5+
agent {
6+
docker {
7+
image 'obraun/fun-jenkins'
8+
args '-v /home/jenkins/.stack:/home/jenkins/.stack'
9+
}
10+
}
611
steps {
7-
sh 'echo stack --no-terminal --install-ghc test --only-dependencies'
12+
sh 'stack --no-terminal test --only-dependencies'
13+
sh 'stack --no-terminal test'
814
}
915
}
10-
stage('Test') {
11-
steps {
12-
sh 'echo stack --no-terminal test --haddock --no-haddock-deps'
16+
}
17+
post {
18+
changed {
19+
script {
20+
if (currentBuild.currentResult == 'FAILURE') { // Other values: SUCCESS, UNSTABLE
21+
// Send an email only if the build status has changed from green/unstable to red
22+
emailext subject: '$DEFAULT_SUBJECT',
23+
body: '$DEFAULT_CONTENT',
24+
recipientProviders: [
25+
[$class: 'CulpritsRecipientProvider'],
26+
[$class: 'DevelopersRecipientProvider'],
27+
[$class: 'RequesterRecipientProvider']
28+
],
29+
replyTo: '$DEFAULT_REPLYTO',
30+
to: '$DEFAULT_RECIPIENTS'
31+
}
1332
}
1433
}
1534
}

README.md

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,34 @@
11
[![Build Status](https://travis-ci.org/obcode/plexams.svg?branch=master)](https://travis-ci.org/obcode/plexams)
22
[![Build status](https://ci.appveyor.com/api/projects/status/eraclkgf9kctilm7?svg=true)](https://ci.appveyor.com/project/obcode/plexams)
33

4-
54
# plexams
65

7-
A Haskell tool for planning exams with a gui build on top of
8-
[Electron](https://electron.atom.io/).
6+
A Haskell tool for planning exams. You can find a GUI build on top of
7+
[Electron](https://electron.atom.io/) in the
8+
[obcode/elexams](https://github.com/obcode/elexams) repository.
99

10-
# Requirements
10+
# Quickstart
1111

12-
- [Haskell](https://www.haskell.org/downloads)
12+
TODO: example project with structure
1313

14-
- [Electron](https://electron.atom.io/).
14+
## Docker
1515

16-
$ npm install electron
16+
You can run the plexams-server as Docker container using the command
1717

18-
# Quickstart
18+
```
19+
docker run --rm -it -v ${path_to_config_dir}:/semester -p 8080:8080 obraun/plexams
20+
```
1921

2022
## Install
2123

24+
### Requirements
25+
26+
- [Haskell](https://www.haskell.org/downloads)
27+
28+
- [Electron](https://electron.atom.io/).
29+
30+
$ npm install electron
31+
2232
In the top directory do
2333

2434
$ stack install
@@ -113,13 +123,13 @@ Available commands:
113123
# Cabal Packages
114124

115125
`plexams-core`
116-
: the core library
126+
: the core library
117127

118128
`plexams-cli`
119-
: a command line interface
129+
: a command line interface
120130

121131
`plexams-generators`
122-
: automagically generate part of the plan
132+
: automagically generate part of the plan
123133

124134
`plexams-server`
125-
: http-server for elexams
135+
: http-server for elexams

0 commit comments

Comments
 (0)