Create or update cloud client configuration file.
(*, config_file, profile, ask_full, auto_token, project)
| 208 | @click.option('--project', 'project', default=None, |
| 209 | help='Leap project for which token is pulled. Defaults to active project.') |
| 210 | def create(*, config_file, profile, ask_full, auto_token, project): |
| 211 | """Create or update cloud client configuration file.""" |
| 212 | |
| 213 | try: |
| 214 | _config_create(config_file=config_file, profile=profile, |
| 215 | ask_full=ask_full, auto_token=auto_token, project=project) |
| 216 | except CLIError as error: |
| 217 | click.echo(f"Error: {error!s} (code: {error.code})") |
| 218 | sys.exit(error.code) |
| 219 | except Exception as error: |
| 220 | click.echo(f"Unhandled error: {error!s}") |
| 221 | sys.exit(127) |
| 222 | |
| 223 | |
| 224 | def _input_config_variables(config: ConfigParser, |
nothing calls this directly
no test coverage detected