86 Star 626 Fork 1.2K

Gitee 极速下载 / Spring-Framework_old1

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
此仓库是为了提升国内下载速度的镜像仓库,每日同步一次。 原始仓库: https://github.com/spring-projects/spring-framework
克隆/下载
update_copyright_headers.sh 961 Bytes
一键复制 编辑 原始数据 按行查看 历史
#!/bin/sh
#
# This shell script updates the copyright headers in source code files
# in the current branch that have been added or modified during the
# current year (at least as much as the `git diff` command supports the
# date range in terms of log history).
#
# This has only been tested on mac OS.
current_year=$(date +'%Y')
echo Updating copyright headers in Java, Kotlin, and Groovy source code for year $current_year
# Added/Modified this year and committed
for file in $(git --no-pager diff --name-only --diff-filter=AM @{$current_year-01-01}..@{$current_year-12-31} | egrep "^.+\.(java|kt|groovy)$" | uniq); do
sed -i '' -E "s/Copyright 2002-[0-9]{4}/Copyright 2002-$current_year/g" $file;
done
# Added/Modified and staged but not yet committed
for file in $(git --no-pager diff --name-only --diff-filter=AM --cached | egrep "^.+\.(java|kt|groovy)$" | uniq); do
sed -i '' -E "s/Copyright 2002-[0-9]{4}/Copyright 2002-$current_year/g" $file;
done
Java
1
https://gitee.com/mirrors/Spring-Framework_old1.git
git@gitee.com:mirrors/Spring-Framework_old1.git
mirrors
Spring-Framework_old1
Spring-Framework_old1
main

搜索帮助

53164aa7 5694891 3bd8fe86 5694891