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

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

Issue 10832161: Remove supalink (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 8 years, 4 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/win/supalink/README ('k') | tools/win/supalink/install_supalink.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 #!/usr/bin/env python
2 # Copyright (c) 2012 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 _winreg = None
11 if sys.platform == 'win32':
12 import _winreg
13 elif sys.platform == 'cygwin':
14 try:
15 import cygwinreg as _winreg
16 except ImportError:
17 pass # If not available, be safe and write 0.
18
19 if not _winreg:
20 sys.stdout.write('0')
21 return 0
22
23 try:
24 val = _winreg.QueryValue(_winreg.HKEY_CURRENT_USER,
25 'Software\\Chromium\\supalink_installed')
26 if os.path.exists(val):
27 # Apparently gyp thinks this means there was an error?
28 #sys.stderr.write('Supalink enabled.\n')
29 sys.stdout.write('1')
30 return 0
31 except WindowsError:
32 pass
33
34 sys.stdout.write('0')
35 return 0
36
37
38 if __name__ == '__main__':
39 sys.exit(main())
OLDNEW
« no previous file with comments | « tools/win/supalink/README ('k') | tools/win/supalink/install_supalink.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698