-- Initial delta.cabal generated by cabal init. For further documentation, -- see http://haskell.org/cabal/users-guide/ -- The name of the package. name: delta -- The package version. See the Haskell package versioning policy (PVP) -- for standards guiding when and how versions should be incremented. -- http://www.haskell.org/haskellwiki/Package_versioning_policy -- PVP summary: +-+------- breaking API changes -- | | +----- non-breaking API additions -- | | | +--- code changes with no API change version: 0.2.1.2 -- A short (one-line) description of the package. synopsis: A library for detecting file changes -- A longer description of the package. description: Delta is a library for detecting file changes in any given directory. The package is written using the sodium FRP library but it also provides a callback based API. . File changes on OS X are based on the @FSEvents@ API that is also used by TimeMachine. On other operating systems the library currently uses recursive descents in directories. I will include @inotify@ for Linux. If someone would like to have a non-polling based API for windows or BSD, I would really like it if anyone would contribute. . The project also contains an executable, delta-run, which allows you to run arbitrary shell commands when a file in a directory (recursively) changes. . @ $> delta-run --help Usage: delta-run [-i|--interval INTERVAL] [-v|--verbose] FILE CMD Available options: -h,--help Show this help text -i,--interval INTERVAL Run at most every n seconds -v,--verbose Print extra output FILE The directory that is watched CMD The command to run @ . For example you could use @delta-run@ to rebuild your project everytime the source changes like this: @ delta-run ./src "cabal build" @ -- URL for the project homepage or repository. homepage: https://github.com/kryoxide/delta -- The license under which the package is released. license: LGPL-3 -- The file containing the license text. license-file: LICENSE -- The package author(s). author: Christof Schramm -- An email address to which users can send suggestions, bug reports, and -- patches. maintainer: christof.schramm@campus.lmu.de -- A copyright notice. -- copyright: category: Data build-type: Simple -- Extra files to be distributed with the package, such as examples or a -- README. -- extra-source-files: -- Constraint on the version of Cabal needed to build this package. cabal-version: >= 1.16 flag build_fs_events description: Build in FSEvents support (OS X) default: True source-repository head type: git location: https://github.com/kryoxide/delta.git library -- Modules exported by the library. exposed-modules: System.Delta.Base , System.Delta.Poll , System.Delta.Callback , System.Delta.Class , System.Delta.FRPUtils , System.Delta if os(darwin) && flag(build_fs_events) exposed-modules: System.Delta.FSEvents -- Modules included in this library but not exported. -- other-modules: -- LANGUAGE extensions used by modules in this package. -- other-extensions: -- Other library packages from which modules are imported. build-depends: base >=4.6 && <4.9 , containers >= 0.5 , directory >= 1.2 , filepath >= 1.3 , time >= 1.5 , sodium >= 0.11 if os(darwin) && flag(build_fs_events) build-depends: hfsevents >= 0.1.5 -- Directories containing source files. hs-source-dirs: src/main/delta/ -- Base language which the package is written in. default-language: Haskell2010 executable delta-cli build-depends: base >= 4.6 && < 4.9 , delta hs-source-dirs: src/main/delta-cli main-is: Main.hs default-language: Haskell2010 executable delta-run build-depends: base >= 4.6 && < 4.9 , delta , optparse-applicative >= 0.10 , directory >= 1.2 , process >= 1.2 , sodium >= 0.11 hs-source-dirs: src/main/delta-run main-is: Main.hs default-language: Haskell2010 ghc-options: -threaded -rtsopts -with-rtsopts=-N test-suite tests build-depends: base >= 4.6 && < 4.9 , delta , hspec >= 1.9 , filepath >= 1.3 , directory >= 1.2 hs-source-dirs: src/test main-is: Main.hs default-language: Haskell2010 type: exitcode-stdio-1.0