Skelebot API
Version 2
- Common
- Objects
- Execution
- Docker – The Docker execution functions for building images and running containers
- Generators
- YAML – The YAML generator for saving and loading config from skelebot.yaml
- Dockerfile – The Dockerfile generator for constructing the project Dockerfile
- Dockerignore – The dockerignore generator for constructing the project .dockerignore
- Scaffolding
- Prompt – The function used to present prompts to the user for scaffolding purposes
Scaffolding Prompt Module
The prompt module provides a function to make CLI requests for information to the user during the scaffolding process.
Import
from skelebot.systems.scaffolding import prompt
promptUser(message, options=None, boolean=False)
return String
PARAMETER | TYPE | DESCRIPTION |
---|---|---|
message | String | The prompt message to be displayed via the command line to the user |
options | List | The list of possible options that the user can enter for their response to the prompt |
boolean | Boolean | Whether or not the prompt should only accept a boolean response (y/N) |
This function can be used during a component's scaffolding process in order to get data from the
user to populate the attributes of a component. By default, the function will allow for any String
of text to be entered as a response. The options parameter allows for the prompt to lock the user's
response to a list of choices. The boolean parameter, if set to True, will ensure that the user's
response is either True or False.