Skip to content

DSCv3 admin settings resource - #5458

Merged
JohnMcPMS merged 5 commits into
microsoft:masterfrom
JohnMcPMS:dscv3-admin-settings
May 16, 2025
Merged

DSCv3 admin settings resource#5458
JohnMcPMS merged 5 commits into
microsoft:masterfrom
JohnMcPMS:dscv3-admin-settings

Conversation

@JohnMcPMS

@JohnMcPMS JohnMcPMS commented May 14, 2025

Copy link
Copy Markdown
Member

Change

Adds an admin settings resource to mirror the existing v2.

Also adds winget settings reset --all to reset all admin settings to their default values (respecting group policy of course).

Validation

Added E2E tests for invoking the resource.

Microsoft Reviewers: Open in CodeFlow

@JohnMcPMS
JohnMcPMS requested a review from a team as a code owner May 14, 2025 23:09

namespace AppInstaller::CLI
{
// A resource for managing source configuration.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// A resource for managing source configuration.
// A resource for managing admin settings.

throw CommandException(Resource::String::InvalidArgumentSpecifierError(ArgumentCommon::ForType(Execution::Args::Type::SettingName).Name));
}

return;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if (ContainsAll && ContansSettingsName)
{
throw ArgumentConflict()?
}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Except that it also needs to return if not throwing.

@yao-msft yao-msft left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also add to Predefined Export list with elevation true?

<value>Manage administrator settings</value>
</data>
<data name="DscAdminSettingsResourceLongDescription" xml:space="preserve">
<value>Allows management of administrator settings the DSC v3 command line interface protocol. See the help link for details.</value>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<value>Allows management of administrator settings the DSC v3 command line interface protocol. See the help link for details.</value>
<value>Allows management of administrator settings through the DSC v3 command line interface protocol. See the help link for details.</value>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants