Skip to content

Commit

Permalink
Deploy GitHub pages
Browse files Browse the repository at this point in the history
  • Loading branch information
liyishuai committed Oct 15, 2019
1 parent dfe8332 commit 0eece0d
Show file tree
Hide file tree
Showing 3 changed files with 127 additions and 33 deletions.
155 changes: 122 additions & 33 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,58 +1,147 @@
version: 2.1

defaults: &defaults
environment:
OPAMVERBOSE: 1
OPAMWITHTEST: true
OPAMYES: true
TERM: xterm
steps:
- checkout
- run:
name: Configure environment
command: echo . ~/.profile >> $BASH_ENV
- run:
name: Install dependencies
command: opam install --deps-only .
- run:
name: List installed packages
command: opam list
- run:
name: Build, test, and install package
command: opam install .
- run:
name: Uninstall package
command: opam uninstall .
- run:
name: Build and test locally
command: make
- run:
name: Cleanup local directory
command: |
make clean
ls -AGR

commands:
startup:
steps:
- checkout
- run:
name: Pull submodules
command: git submodule update --init
- run:
name: Configure environment
command: echo . ~/.profile >> $BASH_ENV
- run:
name: Install dependencies
command: opam install --deps-only .
- run:
name: List installed packages
command: opam list
build:
steps:
- run:
name: Build, test, and install package
command: opam install .
- run:
name: Uninstall package
command: opam uninstall .
- run:
name: Build and test locally
command: make
- run:
name: Cleanup local directory
command: |
make clean
ls -AGR
deploy:
steps:
- run:
name: Build Documentation
command: make html
- run:
name: Configure Git
command: |
git config --global core.autocrlf input
git config --global user.name "Yishuai Li"
git config --global user.email "[email protected]"
- run:
name: Deploy GitHub Pages
command: |
if [ -z "$CIRCLE_TAG" ]
then TAG=$CIRCLE_BRANCH
else TAG=$CIRCLE_TAG
fi
PAGES=coq-ext-lib/$TAG
if [ -z "$CIRCLE_PULL_REQUESTS" ] && [ $CIRCLE_PROJECT_USERNAME == coq-community ]
then git clone -b gh-pages --depth 1 [email protected]:coq-community/coq-ext-lib.git
rm -rf $PAGES/*
mkdir -p $PAGES
cp -LRf html/* $PAGES
cd coq-ext-lib
git add .
git commit -m "$TAG $CIRCLE_SHA1" || true
git push
fi
jobs:
coq.8.8:
coq 8_8:
<<: *defaults
steps:
- startup
- build
docker:
- image: coqorg/coq:8.8
coq.8.9:
coq 8_9:
<<: *defaults
steps:
- startup
- build
docker:
- image: coqorg/coq:8.9
coq.8.10:
coq 8_10:
<<: *defaults
steps:
- startup
- build
docker:
- image: coqorg/coq:8.10
coq.dev:
coq dev:
<<: *defaults
steps:
- startup
- build
docker:
- image: coqorg/coq:dev
doc:
<<: *defaults
steps:
- startup
- deploy
docker:
- image: ysli/coq

workflows:
version: 2
build:
jobs:
- coq.8.8
- coq.8.9
- coq.8.10
- coq.dev
- coq 8_8:
filters:
branches:
ignore: gh-pages
tags:
only: /^v.*/
- coq 8_9:
filters:
branches:
ignore: gh-pages
tags:
only: /^v.*/
- coq 8_10:
filters:
branches:
ignore: gh-pages
tags:
only: /^v.*/
- coq dev:
filters:
branches:
ignore: gh-pages
tags:
only: /^v.*/
- doc:
requires:
- coq 8_8
- coq 8_9
- coq 8_10
- coq dev
filters:
branches:
ignore: gh-pages
tags:
only: /^v.*/
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ make install
After installation, the included modules are available under
the `ExtLib` namespace.

## Documentation
- [Development version](https://coq-community.github.io/coq-ext-lib/master/toc.html)

Ideas
-----
Expand Down
3 changes: 3 additions & 0 deletions meta.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ supported_coq_versions:
namespace: ExtLib

documentation: |
## Documentation
- [Development version](https://coq-community.github.io/coq-ext-lib/master/toc.html)
Ideas
-----
- Embrace new features, e.g. universe polymorphism, primitive projections, etc.
Expand Down

0 comments on commit 0eece0d

Please sign in to comment.