diff options
Diffstat (limited to 'project.py')
-rw-r--r-- | project.py | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -83,7 +83,7 @@ def _ProjectHooks(): | |||
83 | """ | 83 | """ |
84 | global _project_hook_list | 84 | global _project_hook_list |
85 | if _project_hook_list is None: | 85 | if _project_hook_list is None: |
86 | d = os.path.abspath(os.path.dirname(__file__)) | 86 | d = os.path.realpath(os.path.abspath(os.path.dirname(__file__))) |
87 | d = os.path.join(d , 'hooks') | 87 | d = os.path.join(d , 'hooks') |
88 | _project_hook_list = [os.path.join(d, x) for x in os.listdir(d)] | 88 | _project_hook_list = [os.path.join(d, x) for x in os.listdir(d)] |
89 | return _project_hook_list | 89 | return _project_hook_list |
@@ -2016,7 +2016,7 @@ class Project(object): | |||
2016 | self._InitHooks() | 2016 | self._InitHooks() |
2017 | 2017 | ||
2018 | def _InitHooks(self): | 2018 | def _InitHooks(self): |
2019 | hooks = self._gitdir_path('hooks') | 2019 | hooks = os.path.realpath(self._gitdir_path('hooks')) |
2020 | if not os.path.exists(hooks): | 2020 | if not os.path.exists(hooks): |
2021 | os.makedirs(hooks) | 2021 | os.makedirs(hooks) |
2022 | for stock_hook in _ProjectHooks(): | 2022 | for stock_hook in _ProjectHooks(): |