cabal-version: 2.2 name: streamly-examples version: 0.1.0 license: Apache-2.0 license-file: LICENSE author: Composewell Technologies maintainer: streamly@composewell.com homepage: https://streamly.composewell.com bug-reports: http://github.com/composewell/streamly-examples/issues copyright: Copyright (c) 2019 Composewell Technologies synopsis: Examples for Streamly description: Practical examples to demonstrate the features and performance of Streamly. Includes examples about file IO, text processing, networking, concurrent programming, reactive programming and more. . These examples also serve as a beginner's guide to express practical programs using the dataflow programming (streaming) model. Please visit the Streamly homepage> for more details and comprehensive documentation. category: Streamly, Streaming, Concurrency, Text, Filesystem, Network, Reactivity stability: provisional tested-with: GHC==9.0.1, GHC==8.10.5, GHC==8.8.4, GHC==8.6.5 build-type: Simple extra-source-files: Changelog.md Makefile NOTICE README.md examples/WordCount.c source-repository head type: git location: git://github.com/composewell/streamly-examples.git ------------------------------------------------------------------------------ -- Flags -- ------------------------------------------------------------------------------ flag fusion-plugin description: Use fusion plugin for for best performance manual: True default: False flag sdl2 description: Include graphics examples using SDL2 manual: True default: False flag interop description: Include examples of inter-operation with other libraries manual: True default: False ------------------------------------------------------------------------------ -- Common Stanzas -- ------------------------------------------------------------------------------ common exe-dependencies build-depends: streamly >= 0.8.0 && < 0.9 , base >= 4.9 && < 5 , directory >= 1.2 && < 1.4 , transformers >= 0.4 && < 0.6 , containers >= 0.5 && < 0.7 , random >= 1.0.0 && < 2 , exceptions >= 0.8 && < 0.11 , transformers-base >= 0.4 && < 0.5 , network >= 2.6 && < 4 , hashable >= 1.2 && < 1.4 , unordered-containers >= 0.2 && < 0.3 , vector >= 0.12 && < 0.13 , mtl >= 2.2 && < 3 common exe-options import: exe-dependencies default-language: Haskell2010 hs-source-dirs: examples ghc-options: -O2 -fdicts-strict -fspec-constr-recursive=16 -fmax-worker-args=16 -Wall -Wcompat -Wunrecognised-warning-flags -Widentities -Wincomplete-record-updates -Wincomplete-uni-patterns -Wredundant-constraints -Wnoncanonical-monad-instances if flag(fusion-plugin) && !impl(ghcjs) && !impl(ghc < 8.6) ghc-options: -fplugin Fusion.Plugin build-depends: fusion-plugin >= 0.2 && < 0.3 common exe-options-threaded import: exe-options ghc-options: -threaded -with-rtsopts=-N ------------------------------------------------------------------------------ -- Examples -- ------------------------------------------------------------------------------ executable Interop.Vector import: exe-options-threaded main-is: Interop/Vector.hs if !impl(ghcjs) && flag(interop) buildable: True else buildable: False executable Interop.Pipes import: exe-options-threaded main-is: Interop/Pipes.hs if !impl(ghcjs) && flag(interop) buildable: True build-depends: pipes >= 4.3.16 && < 4.4 else buildable: False executable Interop.Streaming import: exe-options-threaded main-is: Interop/Streaming.hs if !impl(ghcjs) && flag(interop) buildable: True build-depends: streaming >= 0.2.3.0 && < 0.3 else buildable: False executable Interop.Conduit import: exe-options-threaded main-is: Interop/Conduit.hs if !impl(ghcjs) && flag(interop) buildable: True build-depends: conduit >= 1.3.4.1 && < 1.3.5 else buildable: False executable Intro import: exe-options-threaded main-is: Intro.hs if !impl(ghcjs) buildable: True else buildable: False executable WordServer import: exe-options-threaded main-is: WordServer.hs if !impl(ghcjs) buildable: True else buildable: False executable MergeServer import: exe-options-threaded main-is: MergeServer.hs if !impl(ghcjs) buildable: True else buildable: False executable CmdServer import: exe-options-threaded main-is: CmdServer.hs if !impl(ghcjs) buildable: True else buildable: False executable CmdClient import: exe-options-threaded main-is: CmdClient.hs if !impl(ghcjs) buildable: True else buildable: False -- executable SearchQuery -- import: exe-options-threaded -- main-is: SearchQuery.hs -- if !impl(ghcjs) -- buildable: True -- else -- buildable: False executable ListDir import: exe-options-threaded main-is: ListDir.hs executable MergeSort import: exe-options-threaded main-is: MergeSort.hs executable AcidRain import: exe-options-threaded main-is: AcidRain.hs executable CirclingSquare import: exe-options-threaded main-is: CirclingSquare.hs if flag(sdl2) buildable: True build-Depends: text >= 1.2.3 && < 1.2.5 , sdl2 >= 2.5.0 && < 2.6 if os(darwin) frameworks: Cocoa else buildable: False executable ControlFlow import: exe-options main-is: ControlFlow.hs executable CoreUtilsHandle import: exe-options main-is: CoreUtilsHandle.hs executable CoreUtils import: exe-options main-is: CoreUtils.hs executable EchoServer import: exe-options-threaded main-is: EchoServer.hs if !impl(ghcjs) buildable: True else buildable: False executable FileSender import: exe-options-threaded main-is: FileSender.hs if !impl(ghcjs) buildable: True else buildable: False executable WordFrequency import: exe-options main-is: WordFrequency.hs if !impl(ghcjs) buildable: True else buildable: False executable WordCount import: exe-options main-is: WordCount.hs ghc-options: -main-is WordCount if !impl(ghcjs) buildable: True else buildable: False executable WordCountParallel import: exe-options-threaded main-is: WordCountParallel.hs other-modules: WordCount if !impl(ghcjs) buildable: True else buildable: False executable WordCountModular import: exe-options main-is: WordCountModular.hs if !impl(ghcjs) buildable: True else buildable: False executable WordCountParallelUTF8 import: exe-options-threaded main-is: WordCountParallelUTF8.hs if !impl(ghcjs) buildable: True else buildable: False executable CamelCase import: exe-options main-is: CamelCase.hs if !impl(ghcjs) buildable: True else buildable: False executable Rate import: exe-options-threaded main-is: Rate.hs if !impl(ghcjs) buildable: True else buildable: False executable Split import: exe-options main-is: Split.hs if !impl(ghcjs) buildable: True else buildable: False executable FileSystemEvent import: exe-options-threaded main-is: FileSystemEvent.hs if !impl(ghcjs) buildable: True else buildable: False