diff options
author | Joey Hess <joey@kitenet.net> | 2010-12-08 14:48:10 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2010-12-08 14:48:10 -0400 |
commit | f8851aad66974691f1fef9d118eceb7ec909c8f4 (patch) | |
tree | b217dfb9a78263f9f087956495c6b697a70b3c81 | |
parent | 2099407d8aa1b1e94f29de0d9094ccfa6e05e471 (diff) |
use Text.Regex.PCRE.Light.Char8 rather than Text.Regexp
Text.Regexp does not think that รก matches . -- seems to be a unicode
problem.
-rw-r--r-- | Command.hs | 6 | ||||
-rw-r--r-- | debian/control | 2 | ||||
-rw-r--r-- | doc/install.mdwn | 1 |
3 files changed, 5 insertions, 4 deletions
diff --git a/Command.hs b/Command.hs index 8edea7622..4ba6ea4b3 100644 --- a/Command.hs +++ b/Command.hs @@ -12,7 +12,7 @@ import System.Directory import System.Posix.Files import Control.Monad (filterM) import System.Path.WildMatch -import Text.Regex +import Text.Regex.PCRE.Light.Char8 import Types import qualified Backend @@ -189,12 +189,12 @@ filterFiles l = do if null exclude then return l' else do - let regexp = mkRegex $ "^" ++ wildToRegex exclude + let regexp = compile ("^" ++ wildToRegex exclude) [] return $ filter (notExcluded regexp) l' where notState f = stateLoc /= take stateLocLen f stateLocLen = length stateLoc - notExcluded r f = case matchRegex r f of + notExcluded r f = case match r f [] of Nothing -> True Just _ -> False diff --git a/debian/control b/debian/control index 88dcab9a3..d90041f77 100644 --- a/debian/control +++ b/debian/control @@ -1,7 +1,7 @@ Source: git-annex Section: utils Priority: optional -Build-Depends: debhelper (>= 7.0.50), ghc6, libghc6-missingh-dev, libghc6-testpack-dev, ikiwiki, uuid, rsync +Build-Depends: debhelper (>= 7.0.50), ghc6, libghc6-missingh-dev, libghc6-pcre-light-dev, libghc6-testpack-dev, ikiwiki, uuid, rsync Maintainer: Joey Hess <joeyh@debian.org> Standards-Version: 3.9.1 Vcs-Git: git://git.kitenet.net/git-annex diff --git a/doc/install.mdwn b/doc/install.mdwn index 7da45c85b..1cff4462e 100644 --- a/doc/install.mdwn +++ b/doc/install.mdwn @@ -3,6 +3,7 @@ To build and use git-annex, you will need: * `git`: <http://git-scm.com/> * The Haskell Platform: <http://haskell.org/platform/> * MissingH: <http://github.com/jgoerzen/missingh/wiki> +* pcre-light: <http://hackage.haskell.org/package/pcre-light> * `uuid`: <http://www.ossp.org/pkg/lib/uuid/> * `xargs`: <http://savannah.gnu.org/projects/findutils/> * `rsync`: <http://rsync.samba.org/> (optional but recommended) |