Browse Source

Merge pull request #90 from gfuchedzhy/hyde

---

Text files lose their original permissions during site generation which means that scripts in generated site have no executable bit. This commit fixes it.
main
Lakshmi Vyasarajan 13 years ago
parent
commit
67a35ab2c9
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      hyde/generator.py

+ 2
- 0
hyde/generator.py View File

@@ -13,6 +13,7 @@ from hyde.site import Node, Resource
from contextlib import contextmanager
from datetime import datetime

from shutil import copymode
from hyde.util import getLoggerWithNullHandler
logger = getLoggerWithNullHandler('hyde.engine')

@@ -334,6 +335,7 @@ class Generator(object):
resource.relative_deploy_path))
target.parent.make()
target.write(text)
copymode(resource.source_file.path, target.path)
else:
logger.debug("Copying binary file [%s]", resource)
self.events.begin_binary_resource(resource)


Loading…
Cancel
Save