Skip to content
This repository has been archived by the owner on Sep 11, 2018. It is now read-only.

touch not available on windows #5

Open
timmie opened this issue Oct 14, 2012 · 0 comments
Open

touch not available on windows #5

timmie opened this issue Oct 14, 2012 · 0 comments

Comments

@timmie
Copy link
Contributor

timmie commented Oct 14, 2012

On windows we would need a workaround:
for
https://github.com/tshauck/Gloo/blob/master/gloo/create_project.py#L42

http://bytes.com/topic/python/answers/159301-best-way-touch-file

http://pypi.python.org/pypi/path.py/2.2

another solution:

http://rogermcd.wordpress.com/2008/07/20/creating-a-file-with-python/

def MakeFile(file_name):

    """
        MakeFile(file_name): makes a file.
    """

    temp_path = '.' + file_name
    file = open(temp_path, 'w')
    file.write('')
    file.close()
    #print 'Execution completed.'

MakeFile('README.rst')
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant