-
Notifications
You must be signed in to change notification settings - Fork 34
(DOCS) Update CLI reference and conceptual docs for v3.0.0 #672
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
(DOCS) Update CLI reference and conceptual docs for v3.0.0 #672
Conversation
8322bb9
to
84a9cd8
Compare
69f79fe
to
18a2eee
Compare
--------------------------------------------------------------- | ||
DesiredStateConfiguration-Preview 9PCX3HX4HZ0Z Unknown msstore | ||
``` | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps a small remark for the users telling something like:
[!INFO]
You can use eithermsstore
orwinget
as the source. When usingwinget
, it leverages the.zip
file, whereasmsstore
uses the.msixbundle
.
18a2eee
to
690ae7e
Compare
690ae7e
to
de65bee
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will need more time to go through all the docs
type: Microsoft.Windows/Registry | ||
result: | ||
actualState: | ||
keyPath: HKCU\example\key |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Enclose in single quotes so that the backslash doesn't need to be escaped
keyPath: HKCU\example\key | |
keyPath: 'HKCU\example\key' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The backslash doesn't need escaping in YAML for unquoted strings:
@'
unquoted: foo\bar\baz
double_quoted: "foo\\bar\\baz"
single_quoted: 'foo\bar\baz'
'@ | ConvertFrom-Yaml | Format-List
Name : unquoted
Value : foo\bar\baz
Name : double_quoted
Value : foo\bar\baz
Name : single_quoted
Value : foo\bar\baz
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess it's just GitHub's syntax coloring then
- Provides metadata about the operation as a whole and for each resource instance. | ||
|
||
```sh | ||
dsc config test --file /example.config.dsc.yaml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dsc config test --file /example.config.dsc.yaml | |
dsc config test --file ./example.config.dsc.yaml |
Is this missing the period? Otherwise it's an absolute path
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see this as fixed?
### HyperText Markup Language (HTML) format | ||
|
||
HTML files can be viewed by web browsers such as **Microsoft Edge**. The following example shows | ||
how to save the output of a command to an HTML file. | ||
|
||
```powershell | ||
dsc resource list | ConvertFrom-Json | ConvertTo-HTML | Out-File .\myFile.html | ||
Invoke-Item .\myFile.html | ||
``` | ||
|
||
The `Invoke-Item` command opens the file in your default web browser. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
### HyperText Markup Language (HTML) format | |
HTML files can be viewed by web browsers such as **Microsoft Edge**. The following example shows | |
how to save the output of a command to an HTML file. | |
```powershell | |
dsc resource list | ConvertFrom-Json | ConvertTo-HTML | Out-File .\myFile.html | |
Invoke-Item .\myFile.html | |
``` | |
The `Invoke-Item` command opens the file in your default web browser. |
unfortunately we need to remove these until an issue is resolved in PWSH
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@theJasonHelmick - how does removing this affect the accessibility concerns?
Maybe we just note that this work in Windows PowerShell and link to the issue / remove the notice when that issue is resolved?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The html written (5.1 or 7) as output does not include language tags so screen readers have to assume system language. We can’t use this, as a result.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is such as massive PR, it will be easier to "nit pick" using small PRs after it is published. At a high level, everything looks good to me.
Prior to this change, the docs folder didn't include any conceptual documentation, only reference documents. This change copies existing concept docs into the folder, updates them for GA, and adds new conceptual documentation to make it easier for new users to learn about DSC and start using it.
This change updates the reference docs for: - `Microsoft/OSInfo` resource - `osinfo` CLI tool - `Microsoft.Windows/Registry` resource - `registry` CLI tool These are the only resources currently documented on the live docs site.
2073abd
to
4f7cbac
Compare
|
||
At a minimum, the manifest must define: | ||
|
||
- The version of the DSC resource manifest JSON schema it's compatible with. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should specify that the version is in semver format
resource. DSC performs the synthetic test by: | ||
|
||
1. Invoking the **Get** operation on the resource to retrieve the actual state of the instance. | ||
1. Synthetically testing each property for the desired state of an instance against the actual |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be noted that in the case of arrays, the ordering doesn't matter, but the number of elements and the elements themselves have to be the same. In the case of objects, the actual state can be a superset of the desired state.
|
||
## export | ||
|
||
A resource with the `export` capability supports enumerating every instance of the resource with |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's worth calling out that if no input is provided, expectation is all instances are returned, but if there is input, then that input should be used as a filter.
If you specify an invalid property name or an invalid value for a property, DSC raises an error | ||
describing how the data is invalid. | ||
|
||
Unless otherwise noted, for any given property: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we specify here that property names with leading underscore is reserved for canonical DSC properties that adhere to DSC defined syntax and semantics
PR Summary
This changeset updates and adds reference documentation for the
3.0.0
GA release of DSC.It includes:
Deferred to future PRs:
PR Context