The ignore package

[Tags:bsd3, library, program, test]

Library and tiny tool for working with ignore files of different version control systems


[Skip to Readme]

Properties

Versions 0.1.0.0, 0.1.1.0
Dependencies base (==4.*), directory (>=1.2.1.0), Glob (>=0.7), ignore, mtl (>=2.1.3.1), path (>=0.5.1), pcre-heavy (>=0.2), text (>=1.2.0.4) [details]
License BSD3
Copyright (c) 2015 Alexander Thiemann
Author Alexander Thiemann <mail@athiemann.net>
Maintainer Alexander Thiemann <mail@athiemann.net>
Category System
Home page http://github.com/agrafix/ignore
Source repository head: git clone https://github.com/agrafix/ignore
Uploaded Sun Aug 23 19:01:38 UTC 2015 by AlexanderThiemann
Distributions LTSHaskell:0.1.1.0, NixOS:0.1.1.0, Stackage:0.1.1.0, Tumbleweed:0.1.1.0
Downloads 575 total (9 in the last 30 days)
Votes
0 []
Status Docs available [build log]
Last success reported on 2015-08-23 [all 1 reports]

Modules

[Index]

Flags

NameDescriptionDefaultType
without-pcreDisable pcre support. If you enable this flag, version control ignore files that rely on pcre will not work correctlyDisabledManual

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info

Downloads

Maintainer's Corner

For package maintainers and hackage trustees

Readme for ignore

Readme for ignore-0.1.1.0

ignore

Build Status Hackage

Intro

Hackage: ignore Stackage: ignore

Handle ignore files of different VCSes

Cli Usage: ignore

$ ignore --help
The ignore tool
(c) 2015 Alexander Thiemann

Tiny tool to check if a file in a repo is ignored by a VCS

Usage: ignore [--help|-h] file1 file2 file3 ... fileN

Library Usage Example

module Main where

import Ignore

import Path
import System.Environment
import System.Directory

main :: IO ()
main =
    do dir <- getCurrentDirectory >>= parseAbsDir
       ignoreFiles <- findIgnoreFiles [VCSGit, VCSMercurial, VCSDarcs] dir
       checker <- buildChecker ignoreFiles
       case checker of
           Left err -> error err
           Right (FileIgnoredChecker isFileIgnored) ->
                  putStrLn $
                    "Main.hs is "
                    ++ (if isFileIgnored "Main.hs"
                        then "ignored" else "not ignored")

Install

  • Using cabal: cabal install ignore
  • Using Stack: stack install ignore
  • From Source (cabal): git clone https://github.com/agrafix/ignore.git && cd ignore && cabal install
  • From Source (stack): git clone https://github.com/agrafix/ignore.git && cd ignore && stack build

Misc

Supported GHC Versions

License

Released under the BSD3 license. (c) 2015 Alexander Thiemann