200-901 · Question #634
Refer to the exhibit. A developer notices that some tasks are repeated in the development workflow. To reduce the amount of work, the developer creates a Bash script to use during the development…
The correct answer is B. Push all changed files on Git with a message on a branch. The Bash script shown in the exhibit automates the following Git workflow: 1. Prompts for a commit message (read message). 2. Prompts for a branch name (read branch). 3. Stages all changed files (git add .). 4. Commits the changes with the provided message (git commit -m…
Question
Refer to the exhibit. A developer notices that some tasks are repeated in the development workflow. To reduce the amount of work, the developer creates a Bash script to use during the development process. The script uses messages to interact with the user and integrates with a version control system. Which workflow is automated by the script?
Exhibit
Options
- AUpdate the master branch with an untracked file.
- BPush all changed files on Git with a message on a branch.
- CUndo a commit.
- DPush on the current branch.
How the community answered
(45 responses)- A4% (2)
- B71% (32)
- C9% (4)
- D16% (7)
Explanation
The Bash script shown in the exhibit automates the following Git workflow: 1. Prompts for a commit message (read message). 2. Prompts for a branch name (read branch). 3. Stages all changed files (git add .). 4. Commits the changes with the provided message (git commit -m "${message}"). 5. Pushes the changes to the specified branch (git push -u origin ${branch}). This script is designed to automate the process of committing and pushing changes to a specific branch in a Git repository with minimal user input.
Topics
Community Discussion
No community discussion yet for this question.
