packages feed

aws-elastic-transcoder 0.1.0.1 → 0.2.0.0

raw patch · 4 files changed

+172/−43 lines, 4 filesdep +aws-elastic-transcoderdep ~awsdep ~conduitdep ~http-conduitnew-component:exe:SubmitETSPVP ok

version bump matches the API change (PVP)

Dependencies added: aws-elastic-transcoder

Dependency ranges changed: aws, conduit, http-conduit, text

API changes (from Hackage documentation)

Files

Aws/ElasticTranscoder.hs view
@@ -5,3 +5,33 @@  import Aws.ElasticTranscoder.Commands import Aws.ElasticTranscoder.Core++-- $use+--+-- A brief example createJob program+--+-- @+--      {-# LANGUAGE OverloadedStrings  #-}+--      +--      import           Aws+--      import           Aws.ElasticTranscoder+--      import           Network.HTTP.Conduit+--      +--      myCreateJob :: IO ()+--      myCreateJob = +--       do cfg <- Aws.baseConfiguration+--          rsp <- withManager $ \mgr -> Aws.pureAws cfg my_ets_cfg mgr $ +--                      createJob "Wildlife.wmv" "Wildlife-t.f4v" my_preset my_pipeline+--          print rsp+--        +--      my_ets_cfg :: EtsConfiguration NormalQuery+--      my_ets_cfg = etsConfiguration HTTPS etsEndpointEu+--              +--      my_preset :: PresetId+--      my_preset = "1351620000001-000001"             -- System preset: Generic 720p+--              +--      my_pipeline :: PipelineId+--      my_pipeline = "<one-of-ypour-pipeline-ids>"+-- @++
Aws/ElasticTranscoder/Commands/CreateJob.hs view
@@ -18,23 +18,30 @@   -- | A brief example createJob program--- --- myCreateJob :: IO ()--- myCreateJob = ---  do cfg <- Aws.baseConfiguration---     rsp <- withManager $ \mgr -> Aws.pureAws cfg my_ets_cfg mgr $ ---                 createJob "Wildlife.wmv" "Wildlife-t.f4v" my_preset my_pipeline---     print rsp---- my_ets_cfg :: EtsConfiguration NormalQuery--- my_ets_cfg = etsConfiguration HTTPS etsEndpointEu---- my_preset :: PresetId--- my_preset = "1351620000000-000001"---- my_pipeline :: PipelineId--- my_pipeline = "1359460188157-258e48"-+--+-- @+--      {-# LANGUAGE OverloadedStrings  #-}+--      +--      import           Aws+--      import           Aws.ElasticTranscoder+--      import           Network.HTTP.Conduit+--      +--      myCreateJob :: IO ()+--      myCreateJob = +--       do cfg <- Aws.baseConfiguration+--          rsp <- withManager $ \mgr -> Aws.pureAws cfg my_ets_cfg mgr $ +--                      createJob "Wildlife.wmv" "Wildlife-t.f4v" my_preset my_pipeline+--          print rsp+--        +--      my_ets_cfg :: EtsConfiguration NormalQuery+--      my_ets_cfg = etsConfiguration HTTPS etsEndpointEu+--              +--      my_preset :: PresetId+--      my_preset = "1351620000001-000001"             -- System preset: Generic 720p+--              +--      my_pipeline :: PipelineId+--      my_pipeline = "<one-of-ypour-pipeline-ids>"+-- @   data CreateJob
+ Examples/SubmitETS.hs view
@@ -0,0 +1,70 @@+{-# LANGUAGE OverloadedStrings  #-}+++import           Aws+import           Aws.ElasticTranscoder+import           Network.HTTP.Conduit+import qualified Data.Text                  as T+import           Text.Printf+import           System.IO+import           System.Exit+import           System.Environment+++preset_id :: PresetId+preset_id = "1351620000001-000010"              -- System preset generic 720p++ets_cfg :: EtsConfiguration NormalQuery+ets_cfg = etsConfiguration HTTPS etsEndpointEu  -- you may have to adjust this+                                                -- to your region+++main :: IO ()+main = parse_args >>= create_job+++-- | usage: SubmitETS <pipeline-id> <master-s3-uri>++parse_args :: IO (PipelineId,S3Object)+parse_args =+ do as <- getArgs+    case as of+      [pid,s3o] -> return (PipelineId $ T.pack pid,T.pack s3o)+      _         ->+         do pn <- getProgName+            hPutStr stderr $ printf "usage : %s <pipeline-id> <s3-key>\n" pn+            exitWith $ ExitFailure 1++-- | create the job from the key locating the master and streaming outputs+--   within their respective buckets++create_job :: (PipelineId,S3Object) -> IO ()+create_job pid_s30 = + do cfg <- Aws.baseConfiguration+    rsp <- withManager $ \mgr -> Aws.pureAws cfg ets_cfg mgr $ mkCJ pid_s30+    print rsp++-- | make up the CreateJob record the key locating the master and streaming outputs+--   within their respective buckets++mkCJ :: (PipelineId,S3Object) -> CreateJob+mkCJ (pid,s3o) = +    CreateJob+        { cjInput =+            JSInput+                { jsiKey                = s3o+                , jsiFrameRate          = FRauto+                , jsiResolution         = Rauto+                , jsiAspectRatio        = ARauto+                , jsiInterlaced         = ABauto+                , jsiContainer          = Cauto+                }+        , cjOutput =+            JSOutput+                { jsoKey                = s3o+                , jsoThumbnailPattern   = s3o `T.append` "-{count}"+                , jsoRotate             = ROTauto+                , jsoPresetId           = preset_id+                }+        , cjPipelineId = pid+        }
aws-elastic-transcoder.cabal view
@@ -1,5 +1,5 @@ Name:                aws-elastic-transcoder-Version:             0.1.0.1+Version:             0.2.0.0 Synopsis:            Haskell suite for the Elastic Transcoder service Description:         This suite extends the aws suite for the Amazon Web Services (AWS) to interface the AWS Elastic Transcoder service for transcoding video. Homepage:            http://github.com/iconnect/aws-elastic-transcoder@@ -7,7 +7,7 @@ License-file:        LICENSE Author:              Chris Dornan Maintainer:          chris.dornan@irisconnect.com-Copyright:           (C) Chris Dornan+Copyright:           Chris Dornan Category:            Network, Web, AWS, Cloud, Distributed Computing Build-type:          Simple @@ -16,12 +16,16 @@ Source-repository this     type:           git     location:       https://github.com/iconnect/aws-elastic-transcoder.git-    tag:            0.1.0.1+    tag:            0.2.0.0  Source-repository head     type:           git     location:       https://github.com/iconnect/aws-elastic-transcoder.git +Flag Examples+    Description:    Build the examples.+    Default:        False+ Library     Exposed-modules:         Aws.ElasticTranscoder@@ -42,21 +46,21 @@         Aws.ElasticTranscoder.Json.Types      Build-depends:-        QuickCheck           >= 2.5.1               ,-        aeson                >= 0.6.1               ,-        aws                  >= 0.7.6.4             ,-        aws-sign4            >= 0.0.0.1             ,-        base                 == 4.*                 ,-        bytestring           >= 0.9                 ,-        conduit              >= 0.5                 ,-        containers           >= 0.4                 ,-        http-conduit         >= 1.6                 ,-        http-types           >= 0.7                 ,-        regex-compat         >= 0.95                ,-        safe                 >= 0.3.3               ,-        text                 >= 0.11                ,-        time                 >= 1.1.4               ,-        transformers         >= 0.2.2.0+            QuickCheck              >= 2.5.1                ,+            aeson                   >= 0.6.1                ,+            aws                     >= 0.8.0                ,+            aws-sign4               >= 0.0.0.1              ,+            base                    == 4.*                  ,+            bytestring              >= 0.9                  ,+            conduit                 >= 0.5                  ,+            containers              >= 0.4                  ,+            http-conduit            >= 1.6                  ,+            http-types              >= 0.7                  ,+            regex-compat            >= 0.95                 ,+            safe                    >= 0.3.3                ,+            text                    >= 0.11                 ,+            time                    >= 1.1.4                ,+            transformers            >= 0.2.2.0      GHC-Options: -Wall @@ -66,18 +70,36 @@     type:          detailed-0.9     test-module:   Aws.ElasticTranscoder.Json.Test     Build-depends:-        Cabal                >= 1.9.2               ,-        QuickCheck           >= 2.5.1               ,-        aeson                >= 0.6.1               ,-        base                 == 4.*                 ,-        containers           >= 0.4                 ,-        regex-compat         >= 0.95                ,-        safe                 >= 0.3.3               ,-        text                 >= 0.11+            Cabal                   >= 1.9.2                ,+            QuickCheck              >= 2.5.1                ,+            aeson                   >= 0.6.1                ,+            base                    == 4.*                  ,+            containers              >= 0.4                  ,+            regex-compat            >= 0.95                 ,+            safe                    >= 0.3.3                ,+            text                    >= 0.11      Other-modules:         Aws.ElasticTranscoder.Json.Types      GHC-Options: -Wall++    Default-Language: Haskell2010++Executable SubmitETS+    Main-is:        SubmitETS.hs+    Hs-source-dirs: Examples++    if !flag(Examples)+        Buildable: False+    else+        Buildable: True+        Build-depends:+            base                    == 4.*                  ,+            aws                                             ,+            aws-elastic-transcoder                          ,+            conduit                                         ,+            http-conduit                                    ,+            text      Default-Language: Haskell2010