Automated Local Cabal Package Testing and Uploading https://github.com/lspitzner/iridium
|Latest on Hackage:||0.1.5.7|
This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.
iridium is a fancy wrapper around
cabal upload. It aims to automate
several typical steps when releasing a new package version to hackage.
Iridium does all testing locally, in contrast to e.g. github’s travis. This makes it easier to keep your published history free of commits that fail any tests (without squashing or separate branches).
Steps currently include:
Compilation and running tests using multiple compiler versions. (the different compilers must already be installed.)
Checking that the changelog mentions the latest version.
Checking that the upper bounds of dependencies are up-to-date by making use of stackage snapshots.
Uploading of both the package itself and the documentation.
The output on errors is certainly not optimal; for example the stackage upper bound checking will print a typical, hard-to-consume cabal error message. iridium’s focus is on notifying if something is wrong.
Install iridium, run iridium in the directory containing the cabal package. It won’t do anything without confirmation.
$ iridium Checking compilation with different compiler versions Checking with compiler ghc-7.8.4: clear. Checking upper bounds using stackage: clear. Checking documentation: clear. Checking basic compilation: clear. Checking that all dependencies have a lower bound: clear. Checking that all dependencies have an upper bound: clear. Checking package validity: clear. Testing the source distribution package: clear. Testing if the changelog mentions the latest version: clear. Comparing local version to hackage version: clear. [git] Testing for uncommitted changes: clear. Summary: Package: iridium Version: 0.1.5.1 Warning count: 0 Error count: 0 Not -Wall clean:  [git] Branch: master Actions: Tag the current commit with "0.1.5.1" Push current branch and tag to upstream repo Upload package Upload documentation > Continue [y]es [n]o? > y Performing upload.. Building source dist for iridium-0.1.2.0... Preprocessing library iridium-0.1.2.0... Preprocessing executable 'iridium' for iridium-0.1.2.0... Source tarball created: dist/iridium-0.1.2.0.tar.gz Hackage password: Uploading dist/iridium-0.1.2.0.tar.gz... Ok Upload successful. Performing doc upload.. [.. some haddock spam ..] Documentation tarball created: dist/iridium-0.1.2.0-docs.tar.gz Hackage password: Uploading documentation dist/iridium-0.1.2.0-docs.tar.gz... Ok Documentation upload successful. $
iridium.yaml file will be created on first invocation.
|upper-bounds-stackage||Check that upper bounds are up-to-date by using a stackage cabal.config. This is not the best way, because not all packages are on stackage, but it is better than nothing.|
|lower-bounds-exist||Check that all dependencies have a lower bound.|
|upper-bounds-exist||Check that all dependencies have an upper bound. (You do want to conform with the PVP, right?)|
|documentation||Check that haddocks can be created without problems (calling
|changelog||Check if the changelog mentions (contains) the latest version.|
|package-sdist||Check that all necessary stuff is contained in the source distribution by installing the packaged package.|
|compiler-versions||Compile and run tests for several compiler versions (other than the default compiler on $PATH).|
Revision history for iridium
0.1.5.7 – 2017-08-01
- Adapt for cabal-2.0 - Note that this is a breaking change; uploading with cabal-1.* will not work with this version.
0.1.5.6 – 2016-09-28
- Only internal changes (support ghc-8, fix support for ghc-7.8; adapt/switch to turtle-1.3.0)
0.1.5.5 – 2016-09-28
- Slight improvements around the handling of testing against multiple compiler versions
0.1.5.4 – 2016-05-21
- Fix git branch parsing issue
0.1.5.3 – 2016-04-22
cabal updateinvocation by default
- Add warning for missing remote version
0.1.5.2 – 2016-03-11
- Improve stackage upper-bound check error output
0.1.5.1 – 2016-03-11
- Fix iridium package pvp compliance (lower bounds)
- First hackage release
0.1.5.0 – 2016-03-11
Add package-sdist check
Prepare non-static default config
0.1.4.0 – 2016-02-22
Fix various bugs
Make various changes to the default iridium.yaml
Fix/Expand basic git functionality; it includes:
- Displaying current branch
- Tagging the current commit
- Pushing tag and branch to remote
0.1.4.0 – 2016-02-18
- Start integrating some git-specific functionality
0.1.2.0 – 2016-02-17
- First release, experimental.