RFR: 8279315: Add Git support to update_copyright_year.sh script [v2]

Dmitry Kulikov duke at openjdk.java.net
Mon Jan 17 08:23:24 UTC 2022


On Thu, 13 Jan 2022 14:06:52 GMT, Erik Joelsson <erikj at openjdk.org> wrote:

> Looks good.
> 
> Did you consider automatically inferring the VCS by looking for `${this_script_dir}/../../{.git,.hg}`? To resolve `this_script_dir`, you can use the same snippet we have in e.g. top level configure:
> 
> ```
> # Get an absolute path to this script, since that determines the top-level directory.
> this_script_dir=`dirname $0`
> this_script_dir=`cd $this_script_dir > /dev/null && pwd`
> ```

Thank you for the review, and for the suggestion! I've implemented the VCS auto-detection logic now, could you please take another look?

-------------

PR: https://git.openjdk.java.net/jdk/pull/7027



More information about the build-dev mailing list