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

Side by Side Diff: tools/win/supalink/check_installed.py

Issue 8059024: Mostly automatic incremental link enabling (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: make sure tmp file is unlink'd Created 9 years, 2 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
OLDNEW
(Empty)
1 #!/usr/bin/env python
2 # Copyright (c) 2011 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
5
6 import sys
7 import os
8
9 def main():
10 if sys.platform != 'win32':
11 sys.stdout.write('0')
12 return 0
13
14 import _winreg
15
16 try:
17 val = _winreg.QueryValue(_winreg.HKEY_CURRENT_USER,
18 'Software\\Chromium\\supalink_installed')
19 if os.path.exists(val):
20 # Apparently gyp thinks this means there was an error?
21 #sys.stderr.write('Supalink enabled.\n')
22 sys.stdout.write('1')
23 return 0
24 except WindowsError:
25 pass
26
27 sys.stdout.write('0')
28 return 0
29
30
31 if __name__ == '__main__':
32 sys.exit(main())
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698