Commit 67967a53 authored by Paul McCarthy's avatar Paul McCarthy
Browse files

Make setup.py backwards compatible with ancient python.

parent b6870cf1
......@@ -71,7 +71,7 @@ class fsl_sdist(sdist):
def __patch_py_file(self, filename, licence):
licence = licence.split('\n')
licence = ['# {}'.format(l) for l in licence]
licence = ['# {0}'.format(l) for l in licence]
with open(filename, 'rt') as f:
lines = f.read().split('\n')
......@@ -82,7 +82,7 @@ class fsl_sdist(sdist):
# Insert the fsl hashbang and the licence
lines = ['#!/usr/bin/env fslpython'] + ['#'] + licence + lines
lines = ['{}\n'.format(l) for l in lines]
lines = ['{0}\n'.format(l) for l in lines]
with open(filename, 'wt') as f:
f.writelines(lines)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment