-
Notifications
You must be signed in to change notification settings - Fork 129
Add formatting and type extension DSL #241
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
Add formatting and type extension DSL #241
Conversation
I don't see more value switching from XML to the DSL. This is just a copy. We have more power idea to use PowerShell classes (Jason's PSMore). |
@iSazonov Do you have any new information to share on the status of PSMore and an estimated completion date? The last update I saw was on PowerShell/PowerShell#7857 where Jason said there had been no progress since the last commit. The comment was over a year ago and the last commit he referred to was two years ago. If this is still the case, it’s a stale project with no one actively working on it. I understand the desire to overhaul the formatting system but PSMore is a longer-term project. This RFC is to address the community desire to use the existing .NET classes to create formatting definitions. PowerShell’s built-in formatting definitions are a great example, they used to use XML files but have transitioned over to using C# classes. The same motivation in that move is here. XML schema validation only gets you so far in ensuring that PowerShell will accept the ps1xml file. The error messages produced when importing a ps1xml file is difficult to troubleshoot at best and people just don’t have that patience so, most module authors just don’t ship ps1xml files at all. The specification is built using the existing |
@ThomasNieto ps1xml files are not things that users do on every day basis. In contrast, they use console formatting continuously. Thus, investments in a project like PSMore are more justified. |
i think if this was coupled with a way to dynamically add formatting without a ps1xml file, it would be much more powerful. A couple of APIs could be created (or made public) which would make this RFC far more interesting. see this gist for an example of embedded formatting (using reflection) |
@PowerShell/powershell-committee reviewed this and think an implementation of this to create ps1xml files would be suitable for the gallery. |
RFC for PowerShell/PowerShell#2644