Question 420
A project lead describes the following situation: A terminal script needs to ask a coding question during CI but should never grant broad write permissions. What should the developer do first?
Explanation
Correct Answer
Automation should not bypass authorization because the agent is in a script. Acceptance evidence: The task produces diagnostic text without modifying the production environment.
Incorrect Answers
The noninteractive prompt flag allows scripted use of the CLI. That recommendation is relevant to a different task: A workflow needs one question answered directly from a script without an interactive session. In this case the main need is: A terminal script needs to ask a coding question during CI but should never grant broad write permissions.
CLI input history allows retrieving recent prompts where supported. That recommendation is relevant to a different task: A user wants to inspect session history before reissuing a previous Copilot query. In this case the main need is: A terminal script needs to ask a coding question during CI but should never grant broad write permissions.
Script consumers can request simpler CLI output. That recommendation is relevant to a different task: A build tool wants only Copilot's answer text rather than command-line usage decorations. In this case the main need is: A terminal script needs to ask a coding question during CI but should never grant broad write permissions.