Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
每当某种类型的文件 *.hbm.xml 被推送到服务器时,我希望我的post-receive钩子运行某个脚本。动机:每当 NHibernate 文件发生更改时,我都想修改我的数据库架构版本号。
post-receive
谢谢!
这就是我想出的:
for i in `git show --pretty="format:" --name-only HEAD | grep '.*\.hbm\.xml' `; do # call script here..... exit done