about summary refs log tree commit diff
path: root/scripts/copyright.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/copyright.py')
-rwxr-xr-xscripts/copyright.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/scripts/copyright.py b/scripts/copyright.py
index fade0b13..269ac7a3 100755
--- a/scripts/copyright.py
+++ b/scripts/copyright.py
@@ -2,9 +2,10 @@ import os, re, sys
 match = re.search('(.*)/', sys.argv[0])
 if match != None:
 	os.chdir(match.group(1))
+os.chdir('../')
 
 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]
+exclude = ["src%sengine%sexternal" % (os.sep, os.sep), "src%sosxlaunch" % os.sep]
 updated_files = 0
 
 def fix_copyright_notice(filename):
@@ -42,7 +43,7 @@ def fix_copyright_notice(filename):
 	updated_files += 1
 
 skip = False
-for root, dirs, files in os.walk("../src"):
+for root, dirs, files in os.walk("src"):
 	for excluding in exclude:
 		if root[:len(excluding)] == excluding:
 			skip = True