amazonka-codecommit-1.6.0: Amazon CodeCommit SDK.

Copyright(c) 2013-2018 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.CodeCommit.PutFile

Contents

Description

Adds or updates a file in an AWS CodeCommit repository.

Synopsis

Creating a Request

putFile Source #

Creates a value of PutFile with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • pfEmail - An email address for the person adding or updating the file.
  • pfFileMode - The file mode permissions of the blob. Valid file mode permissions are listed below.
  • pfParentCommitId - The full commit ID of the head commit in the branch where you want to add or update the file. If the commit ID does not match the ID of the head commit at the time of the operation, an error will occur, and the file will not be added or updated.
  • pfName - The name of the person adding or updating the file. While optional, adding a name is strongly encouraged in order to provide a more useful commit history for your repository.
  • pfCommitMessage - A message about why this file was added or updated. While optional, adding a message is strongly encouraged in order to provide a more useful commit history for your repository.
  • pfRepositoryName - The name of the repository where you want to add or update the file.
  • pfBranchName - The name of the branch where you want to add or update the file.
  • pfFileContent - The content of the file, in binary object format. -- Note: This Lens automatically encodes and decodes Base64 data. The underlying isomorphism will encode to Base64 representation during serialisation, and decode from Base64 representation during deserialisation. This Lens accepts and returns only raw unencoded data.
  • pfFilePath - The name of the file you want to add or update, including the relative path to the file in the repository.

data PutFile Source #

See: putFile smart constructor.

Instances

Eq PutFile Source # 

Methods

(==) :: PutFile -> PutFile -> Bool #

(/=) :: PutFile -> PutFile -> Bool #

Data PutFile Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutFile -> c PutFile #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutFile #

toConstr :: PutFile -> Constr #

dataTypeOf :: PutFile -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutFile) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutFile) #

gmapT :: (forall b. Data b => b -> b) -> PutFile -> PutFile #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutFile -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutFile -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutFile -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutFile -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutFile -> m PutFile #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutFile -> m PutFile #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutFile -> m PutFile #

Read PutFile Source # 
Show PutFile Source # 
Generic PutFile Source # 

Associated Types

type Rep PutFile :: * -> * #

Methods

from :: PutFile -> Rep PutFile x #

to :: Rep PutFile x -> PutFile #

Hashable PutFile Source # 

Methods

hashWithSalt :: Int -> PutFile -> Int #

hash :: PutFile -> Int #

ToJSON PutFile Source # 
NFData PutFile Source # 

Methods

rnf :: PutFile -> () #

AWSRequest PutFile Source # 

Associated Types

type Rs PutFile :: * #

ToHeaders PutFile Source # 

Methods

toHeaders :: PutFile -> [Header] #

ToPath PutFile Source # 

Methods

toPath :: PutFile -> ByteString #

ToQuery PutFile Source # 
type Rep PutFile Source # 
type Rs PutFile Source # 

Request Lenses

pfEmail :: Lens' PutFile (Maybe Text) Source #

An email address for the person adding or updating the file.

pfFileMode :: Lens' PutFile (Maybe FileModeTypeEnum) Source #

The file mode permissions of the blob. Valid file mode permissions are listed below.

pfParentCommitId :: Lens' PutFile (Maybe Text) Source #

The full commit ID of the head commit in the branch where you want to add or update the file. If the commit ID does not match the ID of the head commit at the time of the operation, an error will occur, and the file will not be added or updated.

pfName :: Lens' PutFile (Maybe Text) Source #

The name of the person adding or updating the file. While optional, adding a name is strongly encouraged in order to provide a more useful commit history for your repository.

pfCommitMessage :: Lens' PutFile (Maybe Text) Source #

A message about why this file was added or updated. While optional, adding a message is strongly encouraged in order to provide a more useful commit history for your repository.

pfRepositoryName :: Lens' PutFile Text Source #

The name of the repository where you want to add or update the file.

pfBranchName :: Lens' PutFile Text Source #

The name of the branch where you want to add or update the file.

pfFileContent :: Lens' PutFile ByteString Source #

The content of the file, in binary object format. -- Note: This Lens automatically encodes and decodes Base64 data. The underlying isomorphism will encode to Base64 representation during serialisation, and decode from Base64 representation during deserialisation. This Lens accepts and returns only raw unencoded data.

pfFilePath :: Lens' PutFile Text Source #

The name of the file you want to add or update, including the relative path to the file in the repository.

Destructuring the Response

putFileResponse Source #

Creates a value of PutFileResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • pfrsResponseStatus - -- | The response status code.
  • pfrsCommitId - The full SHA of the commit that contains this file change.
  • pfrsBlobId - The ID of the blob, which is its SHA-1 pointer.
  • pfrsTreeId - Tree information for the commit that contains this file change.

data PutFileResponse Source #

See: putFileResponse smart constructor.

Instances

Eq PutFileResponse Source # 
Data PutFileResponse Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutFileResponse -> c PutFileResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutFileResponse #

toConstr :: PutFileResponse -> Constr #

dataTypeOf :: PutFileResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutFileResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutFileResponse) #

gmapT :: (forall b. Data b => b -> b) -> PutFileResponse -> PutFileResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutFileResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutFileResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutFileResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutFileResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutFileResponse -> m PutFileResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutFileResponse -> m PutFileResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutFileResponse -> m PutFileResponse #

Read PutFileResponse Source # 
Show PutFileResponse Source # 
Generic PutFileResponse Source # 
NFData PutFileResponse Source # 

Methods

rnf :: PutFileResponse -> () #

type Rep PutFileResponse Source # 
type Rep PutFileResponse = D1 * (MetaData "PutFileResponse" "Network.AWS.CodeCommit.PutFile" "amazonka-codecommit-1.6.0-Ck6cSFWU4LEJwYMtJc4ier" False) (C1 * (MetaCons "PutFileResponse'" PrefixI True) ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "_pfrsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Int)) (S1 * (MetaSel (Just Symbol "_pfrsCommitId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text))) ((:*:) * (S1 * (MetaSel (Just Symbol "_pfrsBlobId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text)) (S1 * (MetaSel (Just Symbol "_pfrsTreeId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text)))))

Response Lenses

pfrsResponseStatus :: Lens' PutFileResponse Int Source #

  • - | The response status code.

pfrsCommitId :: Lens' PutFileResponse Text Source #

The full SHA of the commit that contains this file change.

pfrsBlobId :: Lens' PutFileResponse Text Source #

The ID of the blob, which is its SHA-1 pointer.

pfrsTreeId :: Lens' PutFileResponse Text Source #

Tree information for the commit that contains this file change.