Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(672)

Side by Side Diff: tools/make_links.py

Issue 350483003: Build Tools Cleanup (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: more fixes as reviewed by ricow Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tools/list_pkg_directories.py ('k') | tools/make_version.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
3 # for details. All rights reserved. Use of this source code is governed by a 3 # for details. All rights reserved. Use of this source code is governed by a
4 # BSD-style license that can be found in the LICENSE file. 4 # BSD-style license that can be found in the LICENSE file.
5 5
6 6
7 '''Tool for creating symlinks from SOURCES to TARGET. 7 """Tool for creating symlinks from SOURCES to TARGET.
8 8
9 For each SOURCE in SOURCES create a link from SOURCE to TARGET. If a 9 For each SOURCE in SOURCES create a link from SOURCE to TARGET. If a
10 SOURCE ends with .../lib, the lib suffix is ignored when determining 10 SOURCE ends with .../lib, the lib suffix is ignored when determining
11 the name of the target link. 11 the name of the target link.
12 12
13 Before creating any links, the old entries of the TARGET directory will be 13 Before creating any links, the old entries of the TARGET directory will be
14 removed. 14 removed.
15 15
16 Usage: 16 Usage:
17 python tools/make_links.py OPTIONS TARGET SOURCES... 17 python tools/make_links.py OPTIONS TARGET SOURCES...
18 ''' 18 """
19 19
20 import optparse 20 import optparse
21 import os 21 import os
22 import shutil 22 import shutil
23 import subprocess 23 import subprocess
24 import sys 24 import sys
25 import utils 25 import utils
26 26
27 27
28 def get_options(): 28 def get_options():
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 source = os.path.relpath(source, start=target) 96 source = os.path.relpath(source, start=target)
97 exit_code = make_link(source, os.path.join(target, name), orig_source) 97 exit_code = make_link(source, os.path.join(target, name), orig_source)
98 if exit_code != 0: 98 if exit_code != 0:
99 return exit_code 99 return exit_code
100 create_timestamp_file(options) 100 create_timestamp_file(options)
101 return 0 101 return 0
102 102
103 103
104 if __name__ == '__main__': 104 if __name__ == '__main__':
105 sys.exit(main(sys.argv)) 105 sys.exit(main(sys.argv))
OLDNEW
« no previous file with comments | « tools/list_pkg_directories.py ('k') | tools/make_version.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698