You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2022/04/01 05:55:46 UTC

[GitHub] [skywalking-eyes] halacs commented on pull request #98: New feature: replace already existing license header based on pattern

halacs commented on pull request #98:
URL: https://github.com/apache/skywalking-eyes/pull/98#issuecomment-1085454780


   hi @kezhenxu94,
   
   This PR is to make license update easier. Think of the case when a few words, such as year range (e.g. 2016-2022) needs to be updated (e.g. to 2016-2023). We need to detect there is the license already but it is outdated so needs to be removed first.
   
   In this case `config.License.Content` would be updated while the `config.License.Pattern` would make possible to remove the old one.
   
   Until `config.License.Content` is intact [header.satisfy(...)](https://github.com/apache/skywalking-eyes/blob/main/pkg/header/check.go#L146) ensure that license header won't be changed at all so no file change, neither duplication.
   
   However, if `config.License.Content` changed, original code added the license header even if it was already there (duplication). My PR implement is to avoid this case by using `config.License.Pattern`.
   
   By the way, `config.License.Pattern`  was already in the model but it was not used so far.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@skywalking.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org