tweet-hs 0.5.3.11 → 0.5.3.12
raw patch · 3 files changed
+103/−76 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- src/Web/Tweet/Types.hs +38/−3
- stack.yaml +36/−65
- tweet-hs.cabal +29/−8
src/Web/Tweet/Types.hs view
@@ -1,6 +1,5 @@ {-# LANGUAGE DeriveGeneric #-} {-# LANGUAGE DeriveAnyClass #-}-{-# LANGUAGE TemplateHaskell #-} -- | Exports the `Tweet` type, a datatype for building tweets easily module Web.Tweet.Types where@@ -34,6 +33,42 @@ -- | Contains an 'OAuth' and a 'Credential'; encapsulates everything needed to sign a request. type Config = (OAuth, Credential) -makeLenses ''Tweet+-- | Lens for `Tweet` accessing the `status` field.+status :: Lens' Tweet String+status f tweet@Tweet { _status = str } = fmap (\str' -> tweet { _status = str'}) (f str) -makeLenses ''TweetEntity+-- | Lens for `Tweet` accessing the `handles` field.+handles :: Lens' Tweet [String]+handles f tweet@Tweet { _handles = hs } = fmap (\hs' -> tweet { _handles = hs'}) (f hs)++-- | Lens for `Tweet` accessing the `_replyID` field.+replyID :: Lens' Tweet (Maybe Int)+replyID f tweet@Tweet { _replyID = reply } = fmap (\reply' -> tweet { _replyID = reply'}) (f reply)++-- | Lens for `TweetEntity` accessing the `_text` field.+text :: Lens' TweetEntity String+text f tweet@TweetEntity { _text = txt } = fmap (\txt' -> tweet { _text = txt'}) (f txt)++-- | Lens for `TweetEntity` accessing the `_name` field.+name :: Lens' TweetEntity String+name f tweet@TweetEntity { _name = nam } = fmap (\nam' -> tweet { _name = nam'}) (f nam)++-- | Lens for `TweetEntity` accessing the `_screenName` field.+screenName :: Lens' TweetEntity String+screenName f tweet@TweetEntity { _screenName = scr } = fmap (\scr' -> tweet { _screenName = scr'}) (f scr)++-- | Lens for `TweetEntity` accessing the `_tweetId` field.+tweetId :: Lens' TweetEntity Int +tweetId f tweet@TweetEntity { _tweetId = tw } = fmap (\tw' -> tweet { _tweetId = tw'}) (f tw)++-- | Lens for `TweetEntity` accessing the `_quoted` field.+quoted :: Lens' TweetEntity (Maybe TweetEntity) +quoted f tweet@TweetEntity { _quoted = quot } = fmap (\quot' -> tweet { _quoted = quot'}) (f quot)++-- | Lens for `TweetEntity` accessing the `_retweets` field.+retweets :: Lens' TweetEntity Int +retweets f tweet@TweetEntity { _retweets = rts } = fmap (\rts' -> tweet { _retweets = rts'}) (f rts)++-- | Lens for `TweetEntity` accessing the `_favorites` field.+favorites :: Lens' TweetEntity Int +favorites f tweet@TweetEntity { _favorites = fav } = fmap (\fav' -> tweet { _favorites = fav'}) (f fav)
stack.yaml view
@@ -1,66 +1,37 @@-# This file was automatically generated by 'stack init'-#-# Some commonly used options have been documented as comments in this file.-# For advanced use and comprehensive documentation of the format, please see:-# http://docs.haskellstack.org/en/stable/yaml_configuration/--# Resolver to choose a 'specific' stackage snapshot or a compiler version.-# A snapshot resolver dictates the compiler version and the set of packages-# to be used for project dependencies. For example:-#-# resolver: lts-3.5-# resolver: nightly-2015-09-21-# resolver: ghc-7.10.2-# resolver: ghcjs-0.1.0_ghc-7.10.2-# resolver:-# name: custom-snapshot-# location: "./custom-snapshot.yaml"-resolver: lts-8.12--# User packages to be built.-# Various formats can be used as shown in the example below.-#-# packages:-# - some-directory-# - https://example.com/foo/bar/baz-0.0.2.tar.gz-# - location:-# git: https://github.com/commercialhaskell/stack.git-# commit: e7b331f14bcffb8367cd58fbfc8b40ec7642100a-# - location: https://github.com/commercialhaskell/stack/commit/e7b331f14bcffb8367cd58fbfc8b40ec7642100a-# extra-dep: true-# subdirs:-# - auto-update-# - wai-#-# A package marked 'extra-dep: true' will only be built if demanded by a-# non-dependency (i.e. a user package), and its test suites and benchmarks-# will not be run. This is useful for tweaking upstream packages.+resolver: lts-8.14 packages:-- '.'-# Dependency packages to be pulled from upstream that are not in the resolver-# (e.g., acme-missiles-0.3)-extra-deps: []--# Override default flag values for local packages and extra-deps-flags: {}--# Extra package databases containing global packages-extra-package-dbs: []--# Control whether we use the GHC we find on the path-# system-ghc: true-#-# Require a specific version of stack, using version ranges-# require-stack-version: -any # Default-# require-stack-version: ">=1.4"-#-# Override the architecture used by stack, especially useful on Windows-# arch: i386-# arch: x86_64-#-# Extra directories used by stack for building-# extra-include-dirs: [/path/to/dir]-# extra-lib-dirs: [/path/to/dir]-#-# Allow a newer minor version of GHC than the snapshot specifies-# compiler-check: newer-minor+ - .+ - extra-dep: true+ location:+ git: https://github.com/haskell/deepseq+ commit: 0b22c9825ef79c1ee41d2f19e7c997f5cdc93494+ - extra-dep: true+ location:+ git: https://github.com/ekmett/semigroupoids.git+ commit: c3297f970658ae874db098190327ec742044a2e6+ - extra-dep: true+ location:+ git: http://github.com/ekmett/lens.git+ commit: 7031e00f62a704a86c3149c75c1e2afc059af022+ - extra-dep: true+ location:+ git: https://github.com/dreixel/syb.git+ commit: f584ecd525179778063df2eb02dc6bbe406d7e75+flags:+ tweet-hs:+ llvm-fast: true+ parallel-gc: false+allow-newer: true+compiler: ghc-8.2.0.20170507+compiler-check: match-exact+setup-info:+ ghc:+ linux64:+ 8.2.0.20170507:+ url: https://downloads.haskell.org/~ghc/8.2.1-rc2/ghc-8.2.0.20170507-x86_64-deb8-linux.tar.xz+ macosx:+ 8.2.0.20170507:+ url: https://downloads.haskell.org/~ghc/8.2.1-rc2/ghc-8.2.0.20170507-x86_64-apple-darwin.tar.xz+ windows64:+ 8.2.0.20170507:+ url: https://downloads.haskell.org/~ghc/8.2.1-rc2/ghc-8.2.0.20170507-x86_64-unknown-mingw32.tar.xz
tweet-hs.cabal view
@@ -1,5 +1,5 @@ name: tweet-hs-version: 0.5.3.11+version: 0.5.3.12 synopsis: Command-line tool for twitter description: a Command Line Interface Tweeter homepage: https://github.com/vmchale/command-line-tweeter#readme@@ -24,6 +24,16 @@ Default: False } +Flag gold {+ Description: Use the gold linker+ Default: True+}++Flag parallel-gc {+ Description: Use parallel garbage collector+ Default: False+}+ library hs-source-dirs: src exposed-modules: Web.Tweet@@ -57,8 +67,10 @@ , aeson default-language: Haskell2010 default-extensions: LambdaCase+ if flag(gold) + ghc-options: -optl-fuse-ld=gold+ ld-options: -fuse-ld=gold ghc-options: -fwarn-unused-imports- -- -fwarn-unused-binds executable tweet if flag(library)@@ -68,9 +80,13 @@ hs-source-dirs: app main-is: Main.hs if flag(llvm-fast)- ghc-options: -threaded -rtsopts -with-rtsopts=-N -fllvm -optlo-O3 -O3- else- ghc-options: -threaded -rtsopts -with-rtsopts=-N+ ghc-options: -fllvm -optlo-O3 -O3+ if flag(gold) + ghc-options: -optl-fuse-ld=gold+ ld-options: -fuse-ld=gold+ if flag(parallel-gc)+ ghc-options: -rtsopts -with-rtsopts=-N+ ghc-options: -threaded build-depends: base , tweet-hs default-language: Haskell2010@@ -85,9 +101,11 @@ , megaparsec , bytestring if flag(llvm-fast)- ghc-options: -threaded -rtsopts -with-rtsopts=-N -fllvm -optlo-O3 -O3- else- ghc-options: -threaded -rtsopts -with-rtsopts=-N -O3+ ghc-options: -fllvm -optlo-O3 -O3+ if flag(gold) + ghc-options: -optl-fuse-ld=gold+ ld-options: -fuse-ld=gold+ ghc-options: -threaded -rtsopts -with-rtsopts=-N -O3 default-language: Haskell2010 test-suite tweeths-test@@ -100,6 +118,9 @@ , hspec-megaparsec , megaparsec , bytestring+ if flag(gold) + ghc-options: -optl-fuse-ld=gold+ ld-options: -fuse-ld=gold ghc-options: -threaded -rtsopts -with-rtsopts=-N default-language: Haskell2010