8.2.34 | Linux | www-data (uid:33)
👁 View: get.py
📁 //snap/google-cloud-cli/current/lib/surface/anthos/packages/get.py
# -*- coding: utf-8 -*- # # Copyright 2019 Google LLC. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. """Fetch Anthos package from a git repository.""" from googlecloudsdk.calliope import base from googlecloudsdk.command_lib.anthos import anthoscli_backend from googlecloudsdk.command_lib.anthos import flags class Get(base.BinaryBackedCommand): """Fetch Anthos package from a git repository.""" detailed_help = { 'EXAMPLES': """ To fetch package FOO from github into local package dir `my-foo`: $ {command} https://github.com/myaccount/foo.git --local-dir my-foo To fetch package myaccount/foo.git/other_package from github, with tag 'v123' into local package dir 'my-foo': $ {command} https://github.com/myaccount/foo.git/other_package@v123 --local-dir my-foo """, } @staticmethod def Args(parser): flags.GetRepoURIFlag().AddToParser(parser) flags.GetLocalDirFlag(positional=False).AddToParser(parser) flags.GetFilePatternFlag().AddToParser(parser) def Run(self, args): command_executor = anthoscli_backend.AnthosCliWrapper() response = command_executor(command='get', repo_uri=args.REPO_URI, local_dest=args.LOCAL_DIR, env=anthoscli_backend.GetEnvArgsForCommand(), show_exec_error=args.show_exec_error, file_pattern=args.PATTERN) return self._DefaultOperationResponseHandler(response)
← Back
💻 Terminal
📤 Upload
📂
Click or Drag & Drop
📁 //snap/google-cloud-cli/current/lib/surface/anthos/packages
NameSizePermModifiedActions
📁 __pycache__/-07752026-10-06 18:39🗑 Delete
__init__.py1005B06441980-01-01 08:00👁 View ✏️ Edit 📝 Rename 📦 Move 🗑 Del
describe.py1.6K06441980-01-01 08:00👁 View ✏️ Edit 📝 Rename 📦 Move 🗑 Del
get.py2K06441980-01-01 08:00👁 View ✏️ Edit 📝 Rename 📦 Move 🗑 Del
update.py3.3K06441980-01-01 08:00👁 View ✏️ Edit 📝 Rename 📦 Move 🗑 Del