psi-header icon indicating copy to clipboard operation
psi-header copied to clipboard

Feature Request: Auto Add header if missing from a file

Open moyarich opened this issue 1 year ago • 1 comments

I propose a Feature Request :

When a user opens a file in a supported language, the extension should automatic add a copyright notice if it is currently missing from the file. Importantly, this enhancement should refrain from automatically saving the file to avoid unintentional modifications.

For reference, a similar functionality is present in the extensions

This would be a nice feature to have because it provides a quick and convenient way to locate existing files with missing copyright notice.

moyarich avatar Feb 01 '24 01:02 moyarich

I am sorry, I just realised that I completely missed this request.

This feature is already available in the extension. Take a look at the setting psi-header.changes-tracking.enforceHeader. When set to true, it will add the header during save if one does not already exist.

davidquinn avatar May 11 '24 17:05 davidquinn