Skip to content
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

Use pscustomobject cast for sorted output of $GitPromptSettings #382

Merged
merged 1 commit into from
Jan 31, 2017
Merged

Use pscustomobject cast for sorted output of $GitPromptSettings #382

merged 1 commit into from
Jan 31, 2017

Conversation

lzybkr
Copy link
Collaborator

@lzybkr lzybkr commented Jan 30, 2017

To get output sorted like the original source for $GitPromptSettings,
we can use a cast instead of New-Object.

This does change the type of the object in V2 from PSObject to
hashtable, but it doesn't appear to cause any problems because
property syntax works either way.

To get output sorted like the original source for `$GitPromptSettings`,
we can use a cast instead of `New-Object`.

This does change the type of the object in V2 from `PSObject` to
`hashtable`, but it doesn't appear to cause any problems because
property syntax works either way.
@rkeithhill
Copy link
Collaborator

Verified. V2 still works (although the properties don't display in definition order). OTOH V5 (and probably V3/4) do display the properties in the order they were defined.

@rkeithhill
Copy link
Collaborator

Sufficiently fixes #344 for 0.7.0.

@rkeithhill rkeithhill merged commit 3b5a853 into dahlbyk:master Jan 31, 2017
@lzybkr lzybkr deleted the sort-settings branch January 31, 2017 05:02
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.

2 participants