From 3e6b77b0409d05d5ed19c61e24246ed2a88b65e7 Mon Sep 17 00:00:00 2001 From: Sworddragon Date: Sat, 2 Apr 2011 04:47:19 +0200 Subject: Added/fixed directory changing --- scripts/copyright.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts/copyright.py') diff --git a/scripts/copyright.py b/scripts/copyright.py index 29e1bbfe..fade0b13 100755 --- a/scripts/copyright.py +++ b/scripts/copyright.py @@ -1,7 +1,7 @@ import os, re, sys -match = re.search("(.*?)/[^/]*?$", sys.argv[0]) +match = re.search('(.*)/', sys.argv[0]) if match != None: - os.chdir(os.getcwd() + "/" + match.group(1)) + os.chdir(match.group(1)) notice = [b"/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */\n", b"/* If you are missing that file, acquire a complete release at teeworlds.com. */\n"] exclude = ["../src%sengine%sexternal" % (os.sep, os.sep), "../src%sosxlaunch" % os.sep] -- cgit 1.4.1