Skip to content

Commit

Permalink
release
Browse files Browse the repository at this point in the history
  • Loading branch information
Vanessa McHale committed Aug 10, 2018
1 parent 11f3162 commit 76af6fe
Show file tree
Hide file tree
Showing 10 changed files with 21 additions and 12 deletions.
2 changes: 2 additions & 0 deletions .hlint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
- error: {lhs: "const", rhs: "pure", name: "Use pure"}
- error: {lhs: "mapM", rhs: "traverse"}
- error: {lhs: "mapM_", rhs: "traverse_"}
- error: {lhs: "if p then x else pure ()", rhs: "when p x"}
- error: {lhs: "if p then pure () else x", rhs: "when (not p) x"}

- ignore: {name: Avoid lambda, within: [Language.ATS.Types.Lens]}
- ignore: {name: Use <$>, within: [Language.ATS.PrettyPrint]}
Expand Down
10 changes: 6 additions & 4 deletions ats-pkg/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# ats-pkg

## 3.2.1.1

* Don't default to 4 processors
## 3.2.1.2

## 3.2.1.0
Bug Fixes:

* Don't default to 4 processors
* Use `getAppUserDirectory` for better portability

Breaking Changes:

* Only build C sources when sensible to do so
2 changes: 1 addition & 1 deletion ats-pkg/ats-pkg.cabal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cabal-version: 2.0
name: ats-pkg
version: 3.2.1.2
version: 3.2.1.3
license: BSD3
license-file: LICENSE
copyright: Copyright: (c) 2018 Vanessa McHale
Expand Down
2 changes: 2 additions & 0 deletions ats-pkg/src/Language/ATS/Package.hs
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,15 @@ module Language.ATS.Package ( buildAll
, LibDep
, DepSelector
, PackageError (..)
, Debian (..)
-- * Lenses
, dirLens
) where

import Distribution.ATS.Version
import Language.ATS.Package.Build
import Language.ATS.Package.Compiler
import Language.ATS.Package.Debian
import Language.ATS.Package.Dependency
import Language.ATS.Package.Error
import Language.ATS.Package.PackageSet
Expand Down
4 changes: 2 additions & 2 deletions ats-pkg/src/Language/ATS/Package/Build.hs
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,15 @@ mkInstall tgt mStr =
zipWithM_ copyFile' (bins ++ libs' ++ incs) (binDest ++ libDest ++ inclDest)
pa <- pandoc
case man config of
Just mt -> if not pa then pure () else do
Just mt -> when pa $ do
let mt' = manTarget mt
manDest = home </> ".local" </> "share" </> "man" </> "man1" </> takeFileName mt'
need [mt']
copyFile' mt' manDest
Nothing -> pure ()
co <- compleat
case completions config of
Just com -> if not co then pure () else do
Just com -> when co $ do
let com' = unpack com
comDest = home </> ".compleat" </> takeFileName com'
need [com'] -- FIXME do this all in one step
Expand Down
1 change: 1 addition & 0 deletions cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ constraints:
executable-stripping: true

optimization: 2
documentation: true

program-options
happy-options: -gcsa
Expand Down
2 changes: 1 addition & 1 deletion language-ats/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Enhancements:

* Better Error messages
* Add support for boxed records
* Add support for proof expressions introducing witnesses (`[ m | [] ]`)
* Add support for proof expressions introducing witnesses (`[ m | () ]`)

Bug Fixes:

Expand Down
3 changes: 2 additions & 1 deletion shake-ats/shake-ats.cabal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cabal-version: 1.18
name: shake-ats
version: 1.9.0.2
version: 1.9.0.3
license: BSD3
license-file: LICENSE
copyright: Copyright: (c) 2018 Vanessa McHale
Expand All @@ -13,6 +13,7 @@ description:
category: Development, Build, ATS, Shake
build-type: Simple
extra-doc-files: README.md
CHANGELOG.md

source-repository head
type: darcs
Expand Down
4 changes: 2 additions & 2 deletions shake-ats/src/Development/Shake/ATS/Environment.hs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import Control.Monad.IO.Class
import qualified Data.Text.Lazy as TL
import Development.Shake.C
import Development.Shake.FilePath
import System.Environment (getEnv)
import System.Directory

-- | Given a C compiler, return the appropriate directory for its globally
-- installed artifacts. This is used to keep libraries built for different
Expand All @@ -18,7 +18,7 @@ ccToDir _ = ""

-- | The directory @~/.atspkg@
pkgHome :: MonadIO m => CCompiler -> m String
pkgHome cc' = liftIO $ (</> (".atspkg" </> ccToDir cc')) <$> getEnv "HOME"
pkgHome cc' = liftIO $ getAppUserDataDirectory ("atspkg" </> ccToDir cc')

fixDir :: FilePath -> String -> String
fixDir p =
Expand Down
3 changes: 2 additions & 1 deletion shake-ext/src/Development/Shake/Linters.hs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ module Development.Shake.Linters ( tomlcheck
, module Development.Shake.FileDetect
) where

import Control.Monad (when)
import Data.Char (isSpace)
import Data.Foldable (traverse_)
import Development.Shake
Expand All @@ -39,7 +40,7 @@ checkIdempotent :: String -> FilePath -> Action ()
checkIdempotent s p = do
contents <- liftIO $ readFile p
(Stdout out) <- cmd (s ++ " " ++ p)
if trim contents == trim out then pure () else error "formatter is not fully applied!"
when (trim contents /= trim out) (error "formatter is not fully applied!")

-- | Check that given files are formatted according to @stylish-haskell@
stylishHaskell :: [FilePath] -> Action ()
Expand Down

0 comments on commit 76af6fe

Please sign in to comment.