Skip to content

Post-processing Functions

In general, post-processing functions are additional functions that can be enabled to perform some post-processing on rendered license headers.

Such functions can be enabled and configured in YAML configuration file, under the post-process key, where general form of configuration for every post-processing function looks like this:


    enabled: true       # whether the function is enabled or not
        KEY1: VALUE1    # some configuration specific to selected function

Available Post-processing Functions

Below is the list of currently implemented post-processing functions:

This functions allows you to update years or years range in rendered license headers. It uses following rules for updating years:

Original Value Updated Value
Copyright (c) 2019 Author Copyright (c) 2019-2020 Author
Copyright (c) 2020 Author Copyright (c) 2020 Author
Copyright (c) 2017-2019 Author Copyright (c) 2017-2020 Author
Copyright (c) 2017-2020 Author Copyright (c) 2017-2020 Author

You don't need to use this exact format of copyright statement (Copyright (c) YEAR Author), as this function uses regular expressions to find years in entire text of the license header. This example also assumes that the current year is 2020.

YAML Configuration


    enabled: true
     ## If used, updates copyright statements of selected authors only.
     selected-authors-only: ["John Smith"]

This post-processing function has single custom configuration key, selected-authors-only. When you ommit this key completely, years in all copyright statements will be updated. If you need to update statements only for selected author(s), explicitly state them in the list value of this option. For example if you use the value from above example, then following license header:

Copyright (c) 2019 Rose Tyler
Copyright (c) 2019 John Smith

will be updated to

Copyright (c) 2019 Rose Tyler
Copyright (c) 2019-2020 John Smith