Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions Github/Data.hs
Original file line number Diff line number Diff line change
@@ -1,21 +1,26 @@
{-# LANGUAGE DeriveDataTypeable, OverloadedStrings #-}
{-# LANGUAGE CPP, DeriveDataTypeable, OverloadedStrings #-}

-- | This module re-exports the @Github.Data.Definitions@ module, adding
-- instances of @FromJSON@ to it. If you wish to use the data without the
-- instances, use the @Github.Data.Definitions@ module instead.

module Github.Data (module Github.Data.Definitions) where

import Data.Time
import Control.Applicative
import Control.Monad
import qualified Data.Text as T
import Data.Aeson.Types
import System.Locale (defaultTimeLocale)
import qualified Data.Vector as V
import qualified Data.HashMap.Lazy as Map
import Data.Hashable (Hashable)

#if MIN_VERSION_base(4,8,0)
import Data.Time
#else
import Data.Time
import System.Locale (defaultTimeLocale)
#endif

import Github.Data.Definitions

instance FromJSON GithubDate where
Expand Down
9 changes: 7 additions & 2 deletions Github/Issues.hs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE CPP, OverloadedStrings #-}
-- | The issues API as described on <http://developer.github.com/v3/issues/>.
module Github.Issues (
issue
Expand All @@ -16,8 +16,13 @@ module Github.Issues (
import Github.Data
import Github.Private
import Data.List (intercalate)
import Data.Time.Format (formatTime)
#if MIN_VERSION_base(4, 8, 0)
import Data.Time (defaultTimeLocale)
#else
import System.Locale (defaultTimeLocale)
#endif

import Data.Time.Format (formatTime)
import Data.Time.Clock (UTCTime(..))

-- | A data structure for describing how to filter issues. This is used by
Expand Down
2 changes: 1 addition & 1 deletion Github/Private.hs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{-# LANGUAGE OverloadedStrings, StandaloneDeriving, DeriveDataTypeable #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE CPP, FlexibleContexts #-}
module Github.Private where

import Github.Data
Expand Down
2 changes: 1 addition & 1 deletion github.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Name: github
-- The package version. See the Haskell package versioning policy
-- (http://www.haskell.org/haskellwiki/Package_versioning_policy) for
-- standards guiding when and how versions should be incremented.
Version: 0.13.1
Version: 0.13.2

-- A short (one-line) description of the package.
Synopsis: Access to the Github API, v3.
Expand Down