Skip to content

Commit fc627a1

Browse files
SteveL-MSFTTravisEz13
authored andcommitted
add guidance on adding copyright and license header to new source files (#6140)
1 parent 29d50b0 commit fc627a1

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

.github/CONTRIBUTING.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,25 @@ Additional references:
149149
While not required, we appreciate any contributors who add this label and create the issue themselves.
150150
Even better, all contributors are free to contribute the documentation themselves.
151151
(See [Contributing to documentation related to PowerShell](#contributing-to-documentation-related-to-powershell) for more info.)
152+
* If your change adds a new source file, ensure the appropriate copyright and license headers is on top.
153+
It is standard practice to have both a copyright and license notice for each source file.
154+
* For `.h`, `.cpp`, and `.cs` files use:
155+
156+
// Copyright (c) Microsoft Corporation. All rights reserved.
157+
// Licensed under the MIT License.
158+
159+
* For `.ps1` and `.psm1` files use:
160+
161+
# Copyright (c) Microsoft Corporation. All rights reserved.
162+
# Licensed under the MIT License.
163+
164+
* If your change adds a new module manifest (.psd1 file), ensure that:
165+
166+
```powershell
167+
Author = "PowerShell"
168+
Company = "Microsoft Corporation"
169+
Copyright = "Copyright (c) Microsoft Corporation. All rights reserved."
170+
```
152171

153172
### Pull Request - Work in Progress
154173

0 commit comments

Comments
 (0)