瀏覽代碼

Merge commit '51ff66deaa91c6da9a321d95aa60198bdb404922'

tags/v0.2.3.0
Peter J. Jones 2 年之前
父節點
當前提交
f8895e88da
簽署人: Peter Jones <pjones@devalot.com> GPG Key ID: 9DAFAA8D01941E49

+ 4
- 0
vendor/themoviedb/CHANGES.md 查看文件

@@ -1,5 +1,9 @@
# Version History

## 1.1.3.0 (March 18, 2017)

- Widen dependencies for LTS-7.20

## 1.1.2.0 (June 9, 2016)

- Widen dependencies for LTS-5.15

+ 0
- 28
vendor/themoviedb/GNUmakefile 查看文件

@@ -1,28 +0,0 @@
################################################################################
export TMPDIR = $(HOME)/tmp

################################################################################
TMP_DUMMY = $(TMPDIR)/.dummy
STACK_OPTS = --stack-yaml=build/stack.yaml

################################################################################
.PHONY: all test clean install

################################################################################
all: $(TMP_DUMMY)
stack $(STACK_OPTS) setup
stack $(STACK_OPTS) build
hlint src test example

################################################################################
test:
stack $(STACK_OPTS) test

################################################################################
clean:
stack $(STACK_OPTS) clean

################################################################################
$(TMP_DUMMY):
mkdir -p $(dir $@)
touch $@

+ 0
- 20
vendor/themoviedb/build/nixpkgs.nix 查看文件

@@ -1,20 +0,0 @@
with (import <nixpkgs> {});

stdenv.mkDerivation {
name = "themoviedb";

buildInputs = [
# GHC:
haskell.packages.lts-5_15.ghc

# Non-Haskell Dependencies:
zlib # For the header files.
zlib.out # For the .so file.
];

# Work around a bug in GHC:
# https://ghc.haskell.org/trac/ghc/ticket/11042
shellHook = ''
export LD_LIBRARY_PATH=${zlib.out}/lib
'';
}

+ 4
- 5
vendor/themoviedb/src/Network/API/TheMovieDB/Internal/Date.hs 查看文件

@@ -1,4 +1,3 @@
{-# OPTIONS_GHC -Wwarn #-} -- Kludge to not error out on parseTime deprecation.
{-# LANGUAGE OverloadedStrings #-}

{-
@@ -26,7 +25,7 @@ import Data.Aeson
import Data.Aeson.Types (Parser, typeMismatch)
import Data.Text (Text)
import qualified Data.Text as T
import Data.Time (Day(..), parseTime)
import Data.Time (Day(..), parseTimeM)
import Data.Time.Locale.Compat (defaultTimeLocale)

--------------------------------------------------------------------------------
@@ -56,7 +55,7 @@ instance FromJSON Date where
parseJSON Null = return (Date Nothing)
parseJSON (String t)
| T.null t = return (Date Nothing)
| otherwise = case parseTime defaultTimeLocale "%Y-%m-%d" (T.unpack t) of
Just d -> return $ Date (Just d)
_ -> fail "could not parse TheMovieDB date field"
| otherwise = do d <- parseTimeM True defaultTimeLocale "%Y-%m-%d" (T.unpack t)
return $ Date (Just d)
parseJSON v = typeMismatch "Date" v

+ 1
- 1
vendor/themoviedb/src/Network/API/TheMovieDB/Internal/HTTP.hs 查看文件

@@ -39,7 +39,7 @@ apiBaseURL = "https://api.themoviedb.org/3/"
-- | Build a HTTP request that can be used to access the API.
mkAPIRequest :: Key -> Path -> QueryText -> IO HC.Request
mkAPIRequest key path params = do
req <- HC.parseUrl (apiBaseURL ++ path)
req <- HC.parseRequest (apiBaseURL ++ path)

return $ req { HC.queryString = query
, HC.requestHeaders = headers

+ 4
- 4
vendor/themoviedb/src/Network/API/TheMovieDB/Internal/TheMovieDB.hs 查看文件

@@ -1,4 +1,3 @@
{-# OPTIONS_GHC -Wwarn #-} -- Kludge to not error out on withManager deprecation.
{-# LANGUAGE GeneralizedNewtypeDeriving #-}

{-
@@ -30,7 +29,7 @@ import Control.Monad.Trans.Either
import Data.Aeson
import Network.API.TheMovieDB.Internal.HTTP
import Network.API.TheMovieDB.Internal.Types
import Network.HTTP.Client (Manager, withManager)
import Network.HTTP.Client (Manager, newManager)
import Network.HTTP.Client.TLS (tlsManagerSettings)
import Network.HTTP.Types

@@ -86,8 +85,9 @@ runTheMovieDB
:: Key -- ^ The API key to include in all requests.
-> TheMovieDB a -- ^ The API calls to make.
-> IO (Either Error a) -- ^ Response or error.
runTheMovieDB k t = -- TODO: replace withManager with newManager.
withManager tlsManagerSettings (\m -> runTheMovieDBWithManager m k t)
runTheMovieDB k t = do m <- newManager tlsManagerSettings
runTheMovieDBWithManager m k t
-- No need to closeManager anymore.

--------------------------------------------------------------------------------
-- | Execute requests for TheMovieDB with the given API key and produce

vendor/themoviedb/build/stack.yaml → vendor/themoviedb/stack.yaml 查看文件

@@ -1,7 +1,7 @@
resolver: lts-5.15
resolver: lts-7.20

packages:
- ../
- ./

flags:
themoviedb:

+ 15
- 15
vendor/themoviedb/themoviedb.cabal 查看文件

@@ -1,6 +1,6 @@
--------------------------------------------------------------------------------
name: themoviedb
version: 1.1.2.0
version: 1.1.3.0
synopsis: Haskell API bindings for http://themoviedb.org
homepage: http://github.com/pjones/themoviedb
bug-reports: http://github.com/pjones/themoviedb/issues
@@ -60,20 +60,20 @@ library
if flag(maintainer)
ghc-options: -Werror

build-depends: aeson >= 0.6 && < 0.10
, base >= 4.6 && < 5.0
, binary >= 0.7 && < 0.8
, bytestring >= 0.9 && < 0.11
, either >= 4.3 && < 4.5
, http-client >= 0.4 && < 0.5
, http-client-tls >= 0.2.2 && < 0.3
, http-types >= 0.8 && < 0.10
, mtl >= 2.1 && < 2.3
, text >= 0.11 && < 1.3
, text-binary >= 0.1 && < 0.3
, time >= 1.2 && < 1.6
, time-locale-compat >= 0.1 && < 0.2
, transformers >= 0.3 && < 0.5
build-depends: aeson >= 0.6 && < 0.12
, base >= 4.6 && < 5.0
, binary >= 0.7 && < 0.9
, bytestring >= 0.9 && < 0.11
, either >= 4.3 && < 4.5
, http-client >= 0.4.31 && < 0.5
, http-client-tls >= 0.2.2 && < 0.3
, http-types >= 0.8 && < 0.10
, mtl >= 2.1 && < 2.3
, text >= 0.11 && < 1.3
, text-binary >= 0.1 && < 0.3
, time >= 1.5 && < 1.9
, time-locale-compat >= 0.1 && < 0.2
, transformers >= 0.3 && < 0.6

--------------------------------------------------------------------------------
executable tmdb

Loading…
取消
儲存