Skip to content

Commit 9bd78a3

Browse files
Update CHANGELOG for v2.4.0 (#60)
* Update CHANGELOG for v2.4.0 * Also fix publish task real quick
1 parent 407ba6b commit 9bd78a3

File tree

3 files changed

+284
-64
lines changed

3 files changed

+284
-64
lines changed

CHANGELOG.md

Lines changed: 281 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,281 @@
1+
## [2.4.0] - 2025-12-22
2+
3+
## [`Invoke-Member`](https://github.com/SeeminglyScience/ClassExplorer/blob/master/docs/en-US/Invoke-Member.md) (aka `ivm`) (https://github.com/SeeminglyScience/ClassExplorer/pull/55)
4+
5+
Quality of life command that makes interactive invocation of reflection info easier.
6+
7+
### Tracks source instance
8+
9+
No need to save instances to an intermediate variable, `Find-Member` will attach a hidden ETS property to its output.
10+
11+
```powershell
12+
[WildcardPattern]'c*' | Find-Member -Force PatternConvertedToRegex | Invoke-Member
13+
# returns:
14+
# ^c
15+
```
16+
17+
The source object will remain tracked between chained `Find-Member` commands, but not subsequent invocations (for the engine nerds, the `PSObject` does not register itself to the member resurrection table).
18+
19+
### Handles normal conversions, `out` parameters, and pointers
20+
21+
```powershell
22+
using namespace System.Runtime.InteropServices
23+
24+
# very contrived example
25+
$message = 'testing'
26+
$chars = [Marshal]::AllocHGlobal($message.Length * 2)
27+
[Marshal]::Copy($message.ToCharArray(), 0, $chars, $message.Length)
28+
$encoder = [System.Text.Encoding]::UTF8.GetEncoder()
29+
$bytes = [Marshal]::AllocHGlobal(0x200)
30+
31+
# arbitrarily make it a string to show conversion
32+
$charLength = [string]$message.Length
33+
$encoder | Find-Member Convert -ParameterType { [char+] } | % DisplayString
34+
35+
# returns:
36+
# public override void Convert(char* chars, int charCount, byte* bytes, int byteCount, bool flush, out int charsUsed, out int bytesUsed, out bool completed);
37+
38+
$encoder |
39+
Find-Member Convert -ParameterType { [char+] } |
40+
Invoke-Member $chars $charLength $bytes 0x200 $true
41+
42+
# charsUsed bytesUsed completed
43+
# --------- --------- ---------
44+
# 7 7 True
45+
```
46+
47+
![demoing the same thing as the code block above](https://github.com/user-attachments/assets/46452002-b6fb-445c-b95a-7c50a7b16737)
48+
49+
## [`Get-AssemblyLoadContext`](https://github.com/SeeminglyScience/ClassExplorer/blob/master/docs/en-US/Get-AssemblyLoadContext.md) (aka `galc`) (https://github.com/SeeminglyScience/ClassExplorer/pull/55)
50+
51+
A way to interact with and explore ALCs via ClassExplorer.
52+
53+
```powershell
54+
Get-AssemblyLoadContext
55+
56+
# Definition ImplementingType Assemblies
57+
# ---------- ---------------- ----------
58+
# Default System.Runtime.Loader.DefaultAssemblyLoadCon… 152 assemblies (System.Private.CoreLib, pwsh, …
59+
# <Unnamed> PowerShellRun.CustomAssemblyLoadContext 0 assemblies
60+
# Yayaml Yayaml.LoadContext 2 assemblies (Yayaml.Module, YamlDotNet)
61+
62+
[ref] | Get-AssemblyLoadContext
63+
# Definition ImplementingType Assemblies
64+
# ---------- ---------------- ----------
65+
# Default System.Runtime.Loader.DefaultAssemblyLoadCon… 152 assemblies (System.Private.CoreLib, pwsh, …
66+
67+
Get-AssemblyLoadContext Yayaml | Find-Type | select -First 5
68+
69+
# Namespace: Yayaml.Module
70+
#
71+
# Access Modifiers Name
72+
# ------ --------- ----
73+
# public sealed class AddYamlFormatCommand : PSCmdlet
74+
# public sealed class ConvertFromYamlCommand : PSCmdlet
75+
# public sealed class ConvertToYamlCommand : PSCmdlet
76+
# public sealed class NewYamlSchemaCommand : PSCmdlet
77+
# public class YamlSchemaCompletionsAttribute : ArgumentCompletionsAttribute
78+
```
79+
80+
![again just demoing the same thing as above](https://github.com/user-attachments/assets/156ab118-94db-42e8-8ecd-b9ac936ed54d)
81+
82+
[2.4.0]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.3.3...v2.4.0
83+
84+
## [2.3.3] - 2022-05-03
85+
86+
* Add `-Decoration` to `Find-Type` and fix it being unreliable with non-BCL attributes (https://github.com/SeeminglyScience/ClassExplorer/pull/44)
87+
88+
[2.3.3]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.3.2...v2.3.3
89+
90+
## [2.3.2] - 2022-05-02
91+
92+
* Add property attributes in `Format-MemberSignature` (https://github.com/SeeminglyScience/ClassExplorer/pull/39)
93+
* Add argument completion for `-Decoration` (https://github.com/SeeminglyScience/ClassExplorer/pull/40)
94+
* Fix type for `ResolutionMap` in help (https://github.com/SeeminglyScience/ClassExplorer/pull/41)
95+
96+
[2.3.2]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.3.1...v2.3.2
97+
98+
## [2.3.1] - 2022-05-01
99+
100+
* Fix `number` keyword not resolving and add help for `hasdefault` keyword (https://github.com/SeeminglyScience/ClassExplorer/pull/38)
101+
102+
[2.3.1]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.3.0...v2.3.1
103+
104+
## [2.3.0] - 2022-05-01
105+
106+
* Add `-Extension` parameter for extension methods (https://github.com/SeeminglyScience/ClassExplorer/pull/35)
107+
* Add `index` signature keyword (https://github.com/SeeminglyScience/ClassExplorer/pull/36)
108+
109+
![image](https://user-images.githubusercontent.com/24977523/166163885-6eb9610b-7dae-4581-9a61-093cce591e16.png)
110+
111+
[2.3.0]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.2.0...v2.3.0
112+
113+
## [2.2.0] - 2022-04-30
114+
115+
### Add `-RecurseNestedType` parameter (https://github.com/SeeminglyScience/ClassExplorer/pull/31)
116+
117+
A lot of queries were a little harder with automatically recursing nested types. So, you could do something like:
118+
119+
```powershell
120+
Find-Type -Not -Base delegate | Find-Member -Not -Virtual | Find-Member Invoke
121+
```
122+
123+
And end up with a bunch of members from nested delegates. This also lets you filter nested types easier. Basically, we are just actually treating
124+
nested types like other members unless you specifically request otherwise.
125+
126+
### Other
127+
128+
* Filter sealed and abstract methods from virtual (https://github.com/SeeminglyScience/ClassExplorer/pull/29)
129+
* Fix filters applying incorrectly with not or pipe (https://github.com/SeeminglyScience/ClassExplorer/pull/30)
130+
* Add some extra aliases and update docs (https://github.com/SeeminglyScience/ClassExplorer/pull/32)
131+
132+
[2.2.0]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.1.0...v2.2.0
133+
134+
## [2.1.0] - 2022-04-30
135+
136+
* Some methods show as virtual when they are not (https://github.com/SeeminglyScience/ClassExplorer/pull/21)
137+
* Group `Find-Member` formatting by full name (https://github.com/SeeminglyScience/ClassExplorer/pull/22)
138+
* Process `params` in member signature format (https://github.com/SeeminglyScience/ClassExplorer/pull/23)
139+
* Exclude ValueType and Enum implementations (https://github.com/SeeminglyScience/ClassExplorer/pull/25)
140+
* Fix access check for `Find-Type` with `-Not` (https://github.com/SeeminglyScience/ClassExplorer/pull/26)
141+
* Add keywords `abstract` and `concrete` (https://github.com/SeeminglyScience/ClassExplorer/pull/27)
142+
* Update manifest for 2.1.0 (https://github.com/SeeminglyScience/ClassExplorer/pull/28)
143+
144+
[2.1.0]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.0.1...v2.1.0
145+
146+
## [2.0.1] - 2022-04-25
147+
148+
* Minor docs and exception message update.
149+
150+
[2.0.1]: https://github.com/SeeminglyScience/ClassExplorer/compare/v2.0.0...v2.0.1
151+
152+
## [2.0.0] - 2022-04-24
153+
154+
**BREAKING CHANGE:** The `Find-Namespace` cmdlet has been removed.
155+
156+
## Type Signature Query Language
157+
158+
This feature allows for very easily handling of generic types, something that was sorely lacking previously. There's a **significant** number of additional queries to play with, check out [about_Type_Signatures.help.md](https://github.com/SeeminglyScience/ClassExplorer/blob/master/docs/en-US/about_Type_Signatures.help.md) for more info.
159+
160+
---
161+
162+
```powershell
163+
Find-Member -ParameterType { [ReadOnlySpan[any]] }
164+
```
165+
166+
![Example-1](https://user-images.githubusercontent.com/24977523/164997378-bcce4176-2112-44cc-815c-f75df84b5c63.png)
167+
168+
169+
Finds members that take a `ReadOnlySpan<>` as a parameter regardless of generic argument.
170+
171+
---
172+
173+
```powershell
174+
Find-Member -ReturnType { [generic[anyof[Span`1, ReadOnlySpan`1], args[TM]]] } -ParameterType { [anyref] [any] }
175+
```
176+
177+
![Example-2](https://user-images.githubusercontent.com/24977523/164997255-026c441b-e9a7-4484-ae6a-4af462698b90.png)
178+
179+
180+
Finds members that take any form of `ref` (including `out` and `in`) and return either a `Span<>` or a `ReadOnlySpan<>` whose generic argument is a generic method type parameter.
181+
182+
## Formatting
183+
184+
Every object returned by included commands feature new formatting with syntax highlighting. Also includes formatting for `PSMethod` (e.g. overload definitions):
185+
186+
![Formatting-Example](https://user-images.githubusercontent.com/24977523/164998245-bd65de3c-82ec-4b89-9733-7cbb87723365.png)
187+
188+
189+
## New command `Format-MemberSignature`
190+
191+
Provides a "metadata reference" style view for reflection objects.
192+
193+
![Format-MemberSignature-Example](https://user-images.githubusercontent.com/24977523/164997656-200a42d0-35cf-4ff1-9811-41e2a272df0f.png)
194+
195+
## Smart Casing
196+
197+
Any parameter that takes a string now uses "smart casing". If the value is all lower case, the search will be case insensitive and switches to case sensitive only when a upper case character is present.
198+
199+
```powershell
200+
Find-Type *ast*
201+
```
202+
203+
![smart-casing-example-1](https://user-images.githubusercontent.com/24977523/164997810-c3aad95f-4dac-476a-b165-e81e9a17450b.png)
204+
205+
```powershell
206+
Find-Type *Ast*
207+
```
208+
209+
![smart-casing-example-2](https://user-images.githubusercontent.com/24977523/164997839-935aa966-7ed3-466d-b2ae-230eed41a173.png)
210+
211+
## Range Expressions
212+
213+
Some new parameters like `Find-Member`'s `-ParameterCount` take a new type of expression that represents a range.
214+
215+
```powershell
216+
Find-Member -ParameterCount 20..
217+
```
218+
219+
![range-expression-example](https://user-images.githubusercontent.com/24977523/164997953-aad40c25-86c0-4cd5-adf2-0ce7a29f2637.png)
220+
221+
Finds all methods with 20 or more parameters.
222+
223+
## And more
224+
225+
- A lot of new parameters and parameter aliases
226+
- Results are properly streamed rather than dumped all at once
227+
- Included cmdlet aliases
228+
- `-Not` works reliably
229+
- Slightly faster
230+
- Many fixes
231+
232+
[2.0.0]: https://github.com/SeeminglyScience/ClassExplorer/compare/v1.1.0...v2.0.0
233+
234+
## [1.1.0] - 2018-01-07
235+
236+
## Find-Namespace Cmdlet
237+
238+
Added the `Find-Namespace` cmdlet for searching the AppDomain for specific namespaces. This is
239+
paticularly useful when exploring a new assembly to get a quick idea what's available. The namespace
240+
objects returned from this cmdlet can be piped into `Find-Type` or `Find-Member`.
241+
242+
For examples and usage, see the [Find-Namespace help page](https://github.com/SeeminglyScience/ClassExplorer/blob/master/docs/en-US/Find-Namespace.md).
243+
244+
## More argument completion
245+
246+
Namespace parameters for `Find-Namespace` and `Find-Type` now have tab completion. The `Name` parameter
247+
for `Get-Assembly` will now also complete assembly names.
248+
249+
## Not parameter
250+
251+
The cmdlets `Find-Namespace`, `Find-Type`, and `Find-Member` now have a `Not` parameter to negate the
252+
search criteria. This makes chaining the commands to filter results a lot easier. Here's a basic example.
253+
254+
```powershell
255+
Find-Namespace Automation | Find-Member -Static | Find-Member -MemberType Field -Not
256+
```
257+
258+
## Fixes
259+
260+
- The `Find-*` cmdlets no longer return all matches in the AppDomain if passed null pipeline input
261+
262+
- Added support for explicitly specifying the `InputObject` parameter from pipeline position 0
263+
264+
- `Find-Type` no longer throws when the `Namespace` parameter is specified with the `RegularExpression`
265+
switch parameter
266+
267+
- Various build and test fixes
268+
269+
[1.1.0]: https://github.com/SeeminglyScience/ClassExplorer/compare/v1.0.1...v1.1.0
270+
271+
## [1.0.1] - 2017-08-28
272+
273+
- Fix positional binding of `FilterScript` for `Find-Member` and `Find-Type`.
274+
275+
[1.0.1]: https://github.com/SeeminglyScience/ClassExplorer/compare/v1.0.0...v1.0.1
276+
277+
## [1.0.0] - 2017-08-26
278+
279+
Initial Release
280+
281+
[1.0.0]: https://github.com/SeeminglyScience/ClassExplorer/commit/19311f0f50e3d05206c65d784aa1d1c2a756f0ce

ClassExplorer.build.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ task DoPublish {
275275
throw 'Could not find PSGallery API key!'
276276
}
277277

278-
Publish-Module -Name $Folders.Release -NuGetApiKey $apiKey -Force:$Force.IsPresent
278+
Publish-Module -Name $script:ReleasePath -NuGetApiKey $apiKey -Force:$Force.IsPresent
279279
}
280280

281281
task Build -Jobs GetProjectInfo, AssertDevDependencies, Clean, BuildDll, CopyToRelease, BuildDocs

module/ClassExplorer.psd1

Lines changed: 2 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
RootModule = 'ClassExplorer.psm1'
1313

1414
# Version number of this module.
15-
ModuleVersion = '2.3.3'
15+
ModuleVersion = '2.4.0'
1616

1717
# Supported PSEditions
1818
CompatiblePSEditions = 'Desktop', 'Core'
@@ -77,68 +77,7 @@ PrivateData = @{
7777
# IconUri = ''
7878

7979
# ReleaseNotes of this module
80-
ReleaseNotes = @'
81-
## 2.3.3
82-
83-
* Add `-Decoration` to `Find-Type`
84-
* Fix `-Decoration` parameter and `hasattr` keyword being unreliable with non-BCL
85-
attributes.
86-
87-
## 2.3.2
88-
89-
* Add property attributes in `Format-MemberSignature`
90-
* Add argument completion for `-Decoration`
91-
* Fix type for `ResolutionMap` in help
92-
93-
## 2.3.1
94-
95-
* Fix `number` signature keyword not resolving
96-
* Add help for `hasdefault` keyword
97-
98-
## 2.3.0
99-
100-
* Add `-Extension` parameter to `Find-Member`. This will find only extension methods
101-
* Add `index` signature keyword for restricting matches to a specific method parameter
102-
index. (e.g. `[allof[index0, string]]` will match if the first parameter is a `string`.
103-
104-
## 2.2.0
105-
106-
### Add `-RecurseNestedType` parameter
107-
108-
A lot of queries were a little harder with automatically recursing nested types.
109-
So you could do something like:
110-
111-
```powershell
112-
Find-Type -Not -Base delegate | Find-Member -Not -Virtual | Find-Member Invoke
113-
```
114-
115-
And end up with a bunch of members from nested delegates. This also lets you
116-
filter nested types easier. Basically we are just actually treating nested types
117-
like other members unless you specifically request otherwise.
118-
119-
### Other
120-
121-
* Filter sealed and abstract methods from virtual
122-
* Fix filters applying incorrectly with `-Not` or when piped
123-
* Add some extra parameter aliases
124-
125-
## 2.1.0
126-
127-
- Add signature keywords `abstract` and `concrete`
128-
- Find-Type no longer includes non-public classes when `-Not` is specified
129-
- Members from `System.Object` are now properly excluded from structs and enums when `-IncludeObject` is not specified
130-
- `params` now shows in member format
131-
- Member formatting is now grouped by full type name of reflected type.
132-
- New slot virtual members now display properly when they are also sealed
133-
134-
## 2.0.1
135-
- Fix error messages and help
136-
137-
## 2.0.0
138-
- Added type signatures, a custom query language built into type expressions. See https://seemingly.dev/about-type-signatures
139-
- A lot of fixes and tweaks
140-
- Removed Find-Namespace command
141-
'@
80+
ReleaseNotes = 'See https://github.com/SeeminglyScience/ClassExplorer/blob/master/CHANGELOG.md'
14281

14382
} # End of PSData hashtable
14483

0 commit comments

Comments
 (0)