Make source identity clear with one command. Language-aware, configurable, and template-driven.
Saturno FancyHeader inserts structured file headers using the active language comment syntax plus file, project, date, copyright, and author metadata. It gives source files a clean, repeatable identity without hand-written boilerplate.
Maintained by Saturno.Software.
- Language-Aware -- Uses the active VS Code language comment syntax automatically
- Metadata-Driven -- Inserts file name, project name, date, and author information
- Template-Based -- Supports inline template lines, external template files, and named template pickers
- Command Palette Friendly -- Create, edit, and apply templates without leaving the editor
- Cross-Platform -- Works on Windows, macOS, and Linux with platform-correct template paths
- Zero Config -- Works out of the box with sensible defaults
code --install-extension SaturnoSoftware.saturno-fancy-header
# or
code --install-extension saturno-fancy-header-x.y.z.vsix- Open a file in VS Code
- Open Command Palette (
Ctrl+Shift+P) - Run
Saturno: Add Header
Optional template commands:
Saturno: New Header TemplateSaturno: Edit Header Templates
Default output:
// ------------------------------------------------------------------------------
// File : example.ts
// Project : my-project
// Date : 2026-05-31
// Copyright : 2026 Saturno Software
// Author : Mateus <mateus@saturno.software>
// ------------------------------------------------------------------------------
Download the latest .vsix from Releases, then install it:
code --install-extension saturno-fancy-header-x.y.z.vsixgit clone https://github.com/SaturnoSoftware/Saturno.VSCode.FancyHeader
cd Saturno.VSCode.FancyHeader
git submodule update --init --recursive
npm install
npm run package
code --install-extension __DIST/*.vsix- VS Code ^1.88.0
All settings are available in the VS Code Settings UI under Saturno FancyHeader, or in settings.json.
Minimal template-file setup:
{
"saturno-fancy-header.templateFile": "${workspaceFolder}/_header-template.txt"
}If templateFile is set, FancyHeader reads the template body from that file and does not require templateLines to be configured as well.
Advanced overrides (optional):
{
"saturno-fancy-header.lineWidth": 80,
"saturno-fancy-header.fillChar": "-",
"saturno-fancy-header.templateFile": "${workspaceFolder}/_header-template.txt",
"saturno-fancy-header.authorName": "",
"saturno-fancy-header.authorEmail": "",
"saturno-fancy-header.copyrightOwner": "Saturno Software",
"saturno-fancy-header.templateLines": [
" File : FILENAME",
" Project : PROJECT",
" Date : DATE",
" Copyright : YEAR COPYRIGHT_OWNER",
" Author : USER_NAME <USER_EMAIL>"
]
}| Setting | Default | Description |
|---|---|---|
lineWidth |
80 |
Total width of generated header lines |
fillChar |
"-" |
Border fill character |
templateFile |
"" |
Optional external template file |
templates |
[] |
Optional named template files shown in a picker |
authorName |
"" |
Optional author name override |
authorEmail |
"" |
Optional author email override |
copyrightOwner |
author name | Optional copyright holder; falls back to resolved author name |
templateLines |
default list | Inline template body with placeholders |
Supported placeholders:
FILENAMEPROJECTDATEYEARCOPYRIGHT_OWNERUSER_NAMEUSER_EMAILLAST_MODIFIED
PROJECT resolves deterministically in this order: the nearest Git worktree root name, the VS Code workspace-folder display name, the workspace-folder name from its path, then the active file's parent directory name.
LAST_MODIFIED uses the date of the latest Git commit that changed the active file. When Git history is unavailable, it falls back to the file modification date.
Create _header-template.txt:
File : ${FILENAME}
Project : ${PROJECT}
Date : ${DATE}
Author : ${USER_NAME} <${USER_EMAIL}>
Then point templateFile to it.
FancyHeader also auto-discovers template files named _header-*.txt in the same template directory and in the default user template folder, so if you add a new file there it is picked up automatically in the template picker.
If you define templates, FancyHeader merges those named entries with the discovered files and opens a Quick Pick when more than one template is available.
| Command | Title | Description |
|---|---|---|
saturno-fancy-header.addHeader |
Saturno: Add Header |
Insert a header with the active template and language comment syntax |
saturno-fancy-header.newTemplate |
Saturno: New Header Template |
Create a new template file, register it, and open it |
saturno-fancy-header.editTemplates |
Saturno: Edit Header Templates |
Pick and open an existing template file |
saturno-fancy-header.about |
Saturno: About FancyHeader |
Show installed version and build information |
FancyHeader reads VS Code language configuration to determine the correct line comment syntax for the active document, then fills the selected template with:
- current file name
- workspace or project name
- current date, copyright year, and copyright owner
- author name and email from settings, Git config, or local user information
Template selection follows this order:
- named template chosen from
templates - external file from
templateFile - inline
templateLines
GPL-3.0 -- See LICENSE.txt for details.
Maintained by Saturno.Software.
Q: Does it work with different programming languages? A: Yes. FancyHeader uses the active VS Code language comment syntax, so it works anywhere VS Code exposes a line-comment style.
Q: Can I use my own header template file?
A: Yes. Set saturno-fancy-header.templateFile to a text file, or configure multiple named templates with saturno-fancy-header.templates.
Q: Where do author name and email come from? A: From the extension settings first, then Git config when available, then local user information as a fallback.
Q: What happens if I run Add Header twice? A: A complete generated header already at the document start is detected, so the second invocation does not change the file.
Made with <3 by Saturno.Software
