Welcome › Forums › General PowerShell Q&A › Verb and Noun
This topic contains 4 replies, has 4 voices, and was last updated by
How can I define which is verb and noun in my script? skeleton of my .psm1 would be as below.
PowerShell does that automatically, as long as your function name contains a hyphen. Everything before the hyphen is the verb, everything after the hyphen is the noun.
'Get' is a verb and 'Foo' is a noun.
thx team. understood.
Just as an addition, PowerShell best practice recommends using a naming convention for the verb part from an 'approved' list. It's quite an extensive list .
I've only found one situation where I was really struggling to choose the verb, and at the end of the day because my noun part wasn't particularly good.
You can get a list of these verbs via :
The topic ‘Verb and Noun’ is closed to new replies.