| title | Copyright Header Guidelines | |||||
|---|---|---|---|---|---|---|
| description | Standards for copyright and license headers in source files to meet OpenSSF Best Practices badge criteria | |||||
| sidebar_position | 7 | |||||
| author | Microsoft | |||||
| ms.date | 2026-01-31 | |||||
| ms.topic | reference | |||||
| keywords |
|
|||||
| estimated_reading_time | 2 |
This document defines the copyright and license header format required for source files in the hve-core repository. Following these guidelines ensures compliance with OpenSSF Best Practices Gold badge criteria for copyright_per_file and license_per_file.
All source files in this repository must include a copyright and license header. We use the SPDX License Identifier standard to provide machine-readable license information.
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: MIT
Applies to: .ps1 files
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: MIT
Applies to: .py files
The header placement depends on any required directives in the file:
Place the header after any #Requires statements:
#Requires -Version 7.0
#Requires -Modules @{ ModuleName="Pester"; ModuleVersion="5.0" }
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: MIT
# Script content starts hereIf no #Requires statements exist, place the header at the first line:
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: MIT
param(
[string]$Path
)Place the header after any shebang line and before PEP 723 inline metadata or the module docstring:
#!/usr/bin/env python3
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: MITIf no shebang exists, place the header at the first line.
- Microsoft Open Source - Microsoft's open source program and governance
- SPDX License List - Standard license identifiers
- SPDX License Identifier Specification - How to use SPDX identifiers in source files
- OpenSSF Best Practices Badge Criteria - Gold level requirements
- PowerShell/PowerShell header example - Reference implementation
🤖 Crafted with precision by ✨Copilot following brilliant human instruction, then carefully refined by our team of discerning human reviewers.