Reference documentation and code samples for the Cloud Functions V2 API class Google::Cloud::Functions::V2::Source.
The location of the function source code.
Inherits
Object
Extended By
Google::Protobuf::MessageExts::ClassMethods
Includes
Google::Protobuf::MessageExts
Methods
#git_uri
defgit_uri()->::String
Returns
(::String) — If provided, get the source from GitHub repository. This option is valid
only for GCF 1st Gen function.
Example: https://github.com/
#git_uri=
defgit_uri=(value)->::String
Parameter
value (::String) — If provided, get the source from GitHub repository. This option is valid
only for GCF 1st Gen function.
Example: https://github.com/
Returns
(::String) — If provided, get the source from GitHub repository. This option is valid
only for GCF 1st Gen function.
Example: https://github.com/
Note: The following fields are mutually exclusive: repo_source, storage_source, git_uri. If a field in that set is populated, all other fields in the set will automatically be cleared.
Note: The following fields are mutually exclusive: repo_source, storage_source, git_uri. If a field in that set is populated, all other fields in the set will automatically be cleared.
Note: The following fields are mutually exclusive: repo_source, storage_source, git_uri. If a field in that set is populated, all other fields in the set will automatically be cleared.
Note: The following fields are mutually exclusive: storage_source, repo_source, git_uri. If a field in that set is populated, all other fields in the set will automatically be cleared.
Note: The following fields are mutually exclusive: storage_source, repo_source, git_uri. If a field in that set is populated, all other fields in the set will automatically be cleared.
Note: The following fields are mutually exclusive: storage_source, repo_source, git_uri. If a field in that set is populated, all other fields in the set will automatically be cleared.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-09 UTC."],[],[],null,["# Cloud Functions V2 API - Class Google::Cloud::Functions::V2::Source (v1.1.0)\n\nVersion latestkeyboard_arrow_down\n\n- [1.1.0 (latest)](/ruby/docs/reference/google-cloud-functions-v2/latest/Google-Cloud-Functions-V2-Source)\n- [1.0.2](/ruby/docs/reference/google-cloud-functions-v2/1.0.2/Google-Cloud-Functions-V2-Source)\n- [0.10.0](/ruby/docs/reference/google-cloud-functions-v2/0.10.0/Google-Cloud-Functions-V2-Source)\n- [0.9.0](/ruby/docs/reference/google-cloud-functions-v2/0.9.0/Google-Cloud-Functions-V2-Source)\n- [0.8.1](/ruby/docs/reference/google-cloud-functions-v2/0.8.1/Google-Cloud-Functions-V2-Source)\n- [0.7.0](/ruby/docs/reference/google-cloud-functions-v2/0.7.0/Google-Cloud-Functions-V2-Source)\n- [0.6.2](/ruby/docs/reference/google-cloud-functions-v2/0.6.2/Google-Cloud-Functions-V2-Source)\n- [0.5.0](/ruby/docs/reference/google-cloud-functions-v2/0.5.0/Google-Cloud-Functions-V2-Source)\n- [0.4.1](/ruby/docs/reference/google-cloud-functions-v2/0.4.1/Google-Cloud-Functions-V2-Source)\n- [0.3.0](/ruby/docs/reference/google-cloud-functions-v2/0.3.0/Google-Cloud-Functions-V2-Source)\n- [0.2.0](/ruby/docs/reference/google-cloud-functions-v2/0.2.0/Google-Cloud-Functions-V2-Source)\n- [0.1.0](/ruby/docs/reference/google-cloud-functions-v2/0.1.0/Google-Cloud-Functions-V2-Source) \nReference documentation and code samples for the Cloud Functions V2 API class Google::Cloud::Functions::V2::Source.\n\nThe location of the function source code. \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #git_uri\n\n def git_uri() -\u003e ::String\n\n**Returns**\n\n- (::String) --- If provided, get the source from GitHub repository. This option is valid only for GCF 1st Gen function. Example: https://github.com/\n\n### #git_uri=\n\n def git_uri=(value) -\u003e ::String\n\n**Parameter**\n\n- **value** (::String) --- If provided, get the source from GitHub repository. This option is valid only for GCF 1st Gen function. Example: https://github.com/ \n**Returns**\n\n- (::String) --- If provided, get the source from GitHub repository. This option is valid only for GCF 1st Gen function. Example: https://github.com/\n\n### #repo_source\n\n def repo_source() -\u003e ::Google::Cloud::Functions::V2::RepoSource\n\n**Returns**\n\n- ([::Google::Cloud::Functions::V2::RepoSource](./Google-Cloud-Functions-V2-RepoSource)) --- If provided, get the source from this location in a Cloud Source Repository.\n\n\n Note: The following fields are mutually exclusive: `repo_source`, `storage_source`, `git_uri`. If a field in that set is populated, all other fields in the set will automatically be cleared.\n\n### #repo_source=\n\n def repo_source=(value) -\u003e ::Google::Cloud::Functions::V2::RepoSource\n\n**Parameter**\n\n- **value** ([::Google::Cloud::Functions::V2::RepoSource](./Google-Cloud-Functions-V2-RepoSource)) --- If provided, get the source from this location in a Cloud Source Repository.\n\n\nNote: The following fields are mutually exclusive: `repo_source`, `storage_source`, `git_uri`. If a field in that set is populated, all other fields in the set will automatically be cleared. \n**Returns**\n\n- ([::Google::Cloud::Functions::V2::RepoSource](./Google-Cloud-Functions-V2-RepoSource)) --- If provided, get the source from this location in a Cloud Source Repository.\n\n\n Note: The following fields are mutually exclusive: `repo_source`, `storage_source`, `git_uri`. If a field in that set is populated, all other fields in the set will automatically be cleared.\n\n### #storage_source\n\n def storage_source() -\u003e ::Google::Cloud::Functions::V2::StorageSource\n\n**Returns**\n\n- ([::Google::Cloud::Functions::V2::StorageSource](./Google-Cloud-Functions-V2-StorageSource)) --- If provided, get the source from this location in Google Cloud Storage.\n\n\n Note: The following fields are mutually exclusive: `storage_source`, `repo_source`, `git_uri`. If a field in that set is populated, all other fields in the set will automatically be cleared.\n\n### #storage_source=\n\n def storage_source=(value) -\u003e ::Google::Cloud::Functions::V2::StorageSource\n\n**Parameter**\n\n- **value** ([::Google::Cloud::Functions::V2::StorageSource](./Google-Cloud-Functions-V2-StorageSource)) --- If provided, get the source from this location in Google Cloud Storage.\n\n\nNote: The following fields are mutually exclusive: `storage_source`, `repo_source`, `git_uri`. If a field in that set is populated, all other fields in the set will automatically be cleared. \n**Returns**\n\n- ([::Google::Cloud::Functions::V2::StorageSource](./Google-Cloud-Functions-V2-StorageSource)) --- If provided, get the source from this location in Google Cloud Storage.\n\n\n Note: The following fields are mutually exclusive: `storage_source`, `repo_source`, `git_uri`. If a field in that set is populated, all other fields in the set will automatically be cleared."]]