agentOptionFlags lists the agent's enabled boolean options as stable, hyphenated display names. AddDate/AddEnvironmentInfo/RedactSecrets read the agent's effective (resolved) values; CodeModeTools is only knowable from the retained config because the runtime folds it into a single wrapper toolset.
(a *agent.Agent, cfg latest.AgentConfig, hasCfg bool)
| 844 | // agent's effective (resolved) values; CodeModeTools is only knowable from the |
| 845 | // retained config because the runtime folds it into a single wrapper toolset. |
| 846 | func agentOptionFlags(a *agent.Agent, cfg latest.AgentConfig, hasCfg bool) []string { |
| 847 | var opts []string |
| 848 | if a.AddDate() { |
| 849 | opts = append(opts, "add-date") |
| 850 | } |
| 851 | if a.AddEnvironmentInfo() { |
| 852 | opts = append(opts, "add-environment-info") |
| 853 | } |
| 854 | if a.RedactSecrets() { |
| 855 | opts = append(opts, "redact-secrets") |
| 856 | } |
| 857 | if hasCfg && cfg.CodeModeTools { |
| 858 | opts = append(opts, "code-mode-tools") |
| 859 | } |
| 860 | return opts |
| 861 | } |
| 862 | |
| 863 | // configSkillNames lists the cleanly-resolvable skill names from the agent |
| 864 | // config: inline skill names, the Include allow-list, and referenced skill |
no test coverage detected