bugged stringlengths 4 228k | fixed stringlengths 0 96.3M | __index_level_0__ int64 0 481k |
|---|---|---|
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,900 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,901 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,902 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,903 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,904 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,905 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,906 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,907 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,908 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,909 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,910 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,911 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,912 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,913 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,914 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,915 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,916 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,917 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,918 |
def revert(self, options, args, file_list): """Reverts local modifications. | def revert(self, options, args, file_list): """Reverts local modifications. | 457,919 |
def status(self, options, args, file_list): """Display status information.""" if not os.path.isdir(self.checkout_path): print('\n________ couldn\'t run status in %s:\nThe directory ' 'does not exist.' % self.checkout_path) else: merge_base = self._Run(['merge-base', 'HEAD', 'origin']) self._Run(['diff', '--name-status'... | def status(self, options, args, file_list): """Display status information.""" if not os.path.isdir(self.checkout_path): options.stdout.write( ('\n________ couldn\'t run status in %s:\nThe directory ' 'does not exist.\n') % self.checkout_path) else: merge_base = self._Run(['merge-base', 'HEAD', 'origin']) self._Run(['di... | 457,920 |
def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | def _Clone(self, revision, url, options): """Clone a git repository from the given URL. | 457,921 |
def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | 457,922 |
def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | 457,923 |
def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | 457,924 |
def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | 457,925 |
def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | def _Clone(self, revision, url, verbose=False): """Clone a git repository from the given URL. | 457,926 |
def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: opti... | 457,927 |
def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | 457,928 |
def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | 457,929 |
def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | 457,930 |
def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | 457,931 |
def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | 457,932 |
def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | def _AttemptRebase(self, upstream, files, verbose=False, newbase=None, branch=None, printed_path=False): """Attempt to rebase onto either upstream or, if specified, newbase.""" files.extend(self._Run(['diff', upstream, '--name-only']).split()) revision = upstream if newbase: revision = newbase if not printed_path: prin... | 457,933 |
def _CheckDetachedHead(self, rev_str): # HEAD is detached. Make sure it is safe to move away from (i.e., it is # reference by a commit). If not, error out -- most likely a rebase is # in progress, try to detect so we can give a better error. try: _, _ = scm.GIT.Capture( ['name-rev', '--no-undefined', 'HEAD'], self.chec... | def _CheckDetachedHead(self, rev_str, options): # HEAD is detached. Make sure it is safe to move away from (i.e., it is # reference by a commit). If not, error out -- most likely a rebase is # in progress, try to detect so we can give a better error. try: _, _ = scm.GIT.Capture( ['name-rev', '--no-undefined', 'HEAD'], ... | 457,934 |
def _CheckDetachedHead(self, rev_str): # HEAD is detached. Make sure it is safe to move away from (i.e., it is # reference by a commit). If not, error out -- most likely a rebase is # in progress, try to detect so we can give a better error. try: _, _ = scm.GIT.Capture( ['name-rev', '--no-undefined', 'HEAD'], self.chec... | def _CheckDetachedHead(self, rev_str): # HEAD is detached. Make sure it is safe to move away from (i.e., it is # reference by a commit). If not, error out -- most likely a rebase is # in progress, try to detect so we can give a better error. try: _, _ = scm.GIT.Capture( ['name-rev', '--no-undefined', 'HEAD'], self.chec... | 457,935 |
def pack(self, options, args, file_list): """Generates a patch file which can be applied to the root of the repository.""" path = os.path.join(self._root_dir, self.relpath) if not os.path.isdir(path): raise gclient_utils.Error('Directory %s is not present.' % path) command = ['svn', 'diff', '-x', '--ignore-eol-style'] ... | def pack(self, options, args, file_list): """Generates a patch file which can be applied to the root of the repository.""" path = os.path.join(self._root_dir, self.relpath) if not os.path.isdir(path): raise gclient_utils.Error('Directory %s is not present.' % path) command = ['svn', 'diff', '-x', '--ignore-eol-style'] ... | 457,936 |
def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | 457,937 |
def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | 457,938 |
def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | 457,939 |
def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs svn to update or transparently checkout the working copy. | 457,940 |
def revert(self, options, args, file_list): """Reverts local modifications. Subversion specific. | def revert(self, options, args, file_list): """Reverts local modifications. Subversion specific. | 457,941 |
def revert(self, options, args, file_list): """Reverts local modifications. Subversion specific. | def revert(self, options, args, file_list): """Reverts local modifications. Subversion specific. | 457,942 |
def status(self, options, args, file_list): """Display status information.""" path = os.path.join(self._root_dir, self.relpath) command = ['status'] + args if not os.path.isdir(path): # svn status won't work if the directory doesn't exist. print("\n________ couldn't run \'%s\' in \'%s\':\nThe directory " "does not exis... | def status(self, options, args, file_list): """Display status information.""" path = os.path.join(self._root_dir, self.relpath) command = ['status'] + args if not os.path.isdir(path): # svn status won't work if the directory doesn't exist. options.stdout.write( ('\n________ couldn\'t run \'%s\' in \'%s\':\nThe director... | 457,943 |
def pack(self, options, args, file_list): """Generates a patch file which can be applied to the root of the repository.""" path = os.path.join(self._root_dir, self.relpath) if not os.path.isdir(path): raise gclient_utils.Error('Directory %s is not present.' % path) command = ['diff'] command.extend(args) | def pack(self, options, args, file_list): """Generates a patch file which can be applied to the root of the repository.""" path = os.path.join(self._root_dir, self.relpath) if not os.path.isdir(path): raise gclient_utils.Error('Directory %s is not present.' % path) command = ['diff', '-x', '--ignore-eol-style'] command... | 457,944 |
def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | 457,945 |
def CMDstatus(parser, args): """Show modification status for every dependencies.""" parser.add_option("--deps", dest="deps_os", metavar="OS_LIST", help="sync deps for the specified (comma-separated) " "platform(s); 'all' will sync all platforms") (options, args) = parser.parse_args(args) client = GClient.LoadCurrentCon... | def CMDstatus(parser, args): """Show modification status for every dependencies.""" parser.add_option("--deps", dest="deps_os", metavar="OS_LIST", help="override deps for the specified (comma-separated) " "platform(s); 'all' will process all deps_os " "references") (options, args) = parser.parse_args(args) client = GCl... | 457,946 |
def CMDsync(parser, args): """Checkout/update all modules.""" parser.add_option("--force", action="store_true", help="force update even for unchanged modules") parser.add_option("--nohooks", action="store_true", help="don't run hooks after the update is complete") parser.add_option("-r", "--revision", action="append", ... | def CMDsync(parser, args): """Checkout/update all modules.""" parser.add_option("--force", action="store_true", help="force update even for unchanged modules") parser.add_option("--nohooks", action="store_true", help="don't run hooks after the update is complete") parser.add_option("-r", "--revision", action="append", ... | 457,947 |
def CMDrevert(parser, args): """Revert all modifications in every dependencies.""" parser.add_option("--deps", dest="deps_os", metavar="OS_LIST", help="sync deps for the specified (comma-separated) " "platform(s); 'all' will sync all platforms") parser.add_option("--nohooks", action="store_true", help="don't run hooks ... | def CMDrevert(parser, args): """Revert all modifications in every dependencies.""" parser.add_option("--deps", dest="deps_os", metavar="OS_LIST", help="override deps for the specified (comma-separated) " "platform(s); 'all' will process all deps_os " "references") parser.add_option("--nohooks", action="store_true", hel... | 457,948 |
def CMDrunhooks(parser, args): """Runs hooks for files that have been modified in the local working copy.""" parser.add_option("--deps", dest="deps_os", metavar="OS_LIST", help="sync deps for the specified (comma-separated) " "platform(s); 'all' will sync all platforms") parser.add_option("--force", action="store_true"... | def CMDrunhooks(parser, args): """Runs hooks for files that have been modified in the local working copy.""" parser.add_option("--deps", dest="deps_os", metavar="OS_LIST", help="override deps for the specified (comma-separated) " "platform(s); 'all' will process all deps_os " "references") parser.add_option("--force", ... | 457,949 |
def CMDrevinfo(parser, args): """Outputs details for every dependencies.""" parser.add_option("--snapshot", action="store_true", help="create a snapshot file of the current " "version of all repositories") (options, args) = parser.parse_args(args) client = GClient.LoadCurrentConfig(options) options.deps_os = None if no... | def CMDrevinfo(parser, args): """Outputs details for every dependencies.""" parser.add_option("--snapshot", action="store_true", help="create a snapshot file of the current " "version of all repositories") (options, args) = parser.parse_args(args) client = GClient.LoadCurrentConfig(options) if not client: raise gclient... | 457,950 |
def revert(self, options, args, file_list): """Reverts local modifications. Subversion specific. | def revert(self, options, args, file_list): """Reverts local modifications. Subversion specific. | 457,951 |
def PrintRevInfo(self): """Output revision info mapping for the client and its dependencies. This allows the capture of an overall "revision" for the source tree that can be used to reproduce the same tree in the future. The actual output contains enough information (source paths, svn server urls and revisions) that it... | def PrintRevInfo(self): """Output revision info mapping for the client and its dependencies. This allows the capture of an overall "revision" for the source tree that can be used to reproduce the same tree in the future. The actual output contains enough information (source paths, svn server urls and revisions) that it... | 457,952 |
def GetURLAndRev(name, original_url): url, revision = gclient_utils.SplitUrlRevision(original_url) if not revision: if revision_overrides.has_key(name): return (url, revision_overrides[name]) else: scm = gclient_scm.CreateSCM(solution["url"], self._root_dir, name) return (url, scm.revinfo(self._options, [], None)) else... | def GetURLAndRev(name, original_url): url, revision = gclient_utils.SplitUrlRevision(original_url) if not revision: if revision_overrides.has_key(name): return (url, revision_overrides[name]) else: scm = gclient_scm.CreateSCM(solution["url"], self._root_dir, name) return (url, scm.revinfo(self._options, [], None)) else... | 457,953 |
def GetURLAndRev(name, original_url): url, revision = gclient_utils.SplitUrlRevision(original_url) if not revision: if revision_overrides.has_key(name): return (url, revision_overrides[name]) else: scm = gclient_scm.CreateSCM(solution["url"], self._root_dir, name) return (url, scm.revinfo(self._options, [], None)) else... | def GetURLAndRev(name, original_url): url, revision = gclient_utils.SplitUrlRevision(original_url) if not revision: if revision_overrides.has_key(name): return (url, revision_overrides[name]) else: scm = gclient_scm.CreateSCM(solution["url"], self._root_dir, name) return (url, scm.revinfo(self._options, [], None)) else... | 457,954 |
def Main(argv): """Parse command line arguments and dispatch command.""" option_parser = optparse.OptionParser(usage=DEFAULT_USAGE_TEXT, version=__version__) option_parser.disable_interspersed_args() option_parser.add_option("", "--force", action="store_true", default=False, help=("(update/sync only) force update even... | def Main(argv): """Parse command line arguments and dispatch command.""" option_parser = optparse.OptionParser(usage=DEFAULT_USAGE_TEXT, version=__version__) option_parser.disable_interspersed_args() option_parser.add_option("", "--force", action="store_true", default=False, help=("(update/sync only) force update even... | 457,955 |
def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | def update(self, options, args, file_list): """Runs git to update or transparently checkout the working copy. | 457,956 |
def drover(options, args): revision = options.revert or options.merge # Initialize some variables used below. They can be overwritten by # the drover.properties file. BASE_URL = "svn://svn.chromium.org/chrome" TRUNK_URL = BASE_URL + "/trunk/src" BRANCH_URL = BASE_URL + "/branches/$branch/src" SKIP_CHECK_WORKING = True... | def drover(options, args): revision = options.revert or options.merge # Initialize some variables used below. They can be overwritten by # the drover.properties file. BASE_URL = "svn://svn.chromium.org/chrome" TRUNK_URL = BASE_URL + "/trunk/src" BRANCH_URL = BASE_URL + "/branches/$branch/src" SKIP_CHECK_WORKING = True... | 457,957 |
def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | 457,958 |
def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | 457,959 |
def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | 457,960 |
def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | 457,961 |
def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | def GetCachedFile(filename, max_age=60*60*24*3, use_root=False): """Retrieves a file from the repository and caches it in GetCacheDir() for max_age seconds. use_root: If False, look up the arborescence for the first match, otherwise go directory to the root repository. Note: The cache will be inconsistent if the same... | 457,962 |
def Register(): """Registers the callback at exit. Calling it multiple times is no-op.""" global _REGISTERED if _REGISTERED: return _REGISTERED = True atexit.register(CheckForException) | def Register(): """Registers the callback at exit. Calling it multiple times is no-op.""" global _REGISTERED if _REGISTERED: return _REGISTERED = True atexit.register(CheckForException) | 457,963 |
def main(argv): if not argv: argv = ['help'] command = Command(argv[0]) # Help can be run from anywhere. if command == CMDhelp: return command(argv[1:]) try: GetRepositoryRoot() except gclient_utils.Error: print >> sys.stderr, 'To use gcl, you need to be in a subversion checkout.' return 1 # Create the directories wh... | def main(argv): if not argv: argv = ['help'] command = Command(argv[0]) # Help can be run from anywhere. if command == CMDhelp: return command(argv[1:]) try: GetRepositoryRoot() except gclient_utils.Error: print >> sys.stderr, 'To use gcl, you need to be in a subversion checkout.' return 1 # Create the directories wh... | 457,964 |
def CaptureMatchingLines(line): match = compiled_pattern.search(line) if match: file_list.append(match.group(1)) if line.startswith('svn: '): failure.append(line) | def CaptureMatchingLines(line): match = compiled_pattern.search(line) if match: file_list.append(match.group(1)) if line.startswith('svn: '): failure.append(line) | 457,965 |
def CaptureMatchingLines(line): match = compiled_pattern.search(line) if match: file_list.append(match.group(1)) if line.startswith('svn: '): failure.append(line) | def CaptureMatchingLines(line): match = compiled_pattern.search(line) if match: file_list.append(match.group(1)) if line.startswith('svn: '): failure.append(line) | 457,966 |
def _Handle(self, output_stream, input_stream, may_prompt=True): """Writes this result to the output stream. | def _Handle(self, output_stream, input_stream, may_prompt=True): """Writes this result to the output stream. | 457,967 |
def __init__(self, commit=None, upstream_branch=None): self.commit = commit self.verbose = None self.default_presubmit = None self.may_prompt = None | def __init__(self, commit=None, upstream_branch=None): self.commit = commit self.verbose = None self.default_presubmit = None self.may_prompt = None | 457,968 |
def __init__(self, commit=None, upstream_branch=None): self.commit = commit self.verbose = None self.default_presubmit = None self.may_prompt = None | def __init__(self, commit=None, upstream_branch=None): self.commit = commit self.verbose = None self.default_presubmit = None self.may_prompt = None | 457,969 |
def CaptureMatchingLines(line): match = compiled_pattern.search(line) if match: file_list.append(match.group(1)) if line.startswith('svn: '): # We can't raise an exception. We can't alias a variable. Use a cheap # way. failure.append(True) | def CaptureMatchingLines(line): match = compiled_pattern.search(line) if match: file_list.append(match.group(1)) if line.startswith('svn: '): # We can't raise an exception. We can't alias a variable. Use a cheap # way. failure.append(True) | 457,970 |
def SendStack(stack, url='http://chromium-status.appspot.com/breakpad'): print 'Do you want to send a crash report [y/N]? ', if sys.stdin.read(1).lower() != 'y': return print 'Sending crash report ...' try: params = { 'args': sys.argv, 'stack': stack, 'user': getpass.getuser(), } request = urllib.urlopen(url, urllib.ur... | def SendStack(stack, url='http://chromium-status.appspot.com/breakpad'): print 'Sending crash report ...' try: params = { 'args': sys.argv, 'stack': stack, 'user': getpass.getuser(), } request = urllib.urlopen(url, urllib.urlencode(params)) print request.read() request.close() except IOError: print('There was a failure... | 457,971 |
def SubprocessCallAndFilter(command, in_directory, print_messages, print_stdout, fail_status=None, filter_fn=None): """Runs command, a list, in directory in_directory. If print_messages is true, a message indicating what is being done is printed to stdout. If print_messages is false, the message is printed only if we ... | def SubprocessCallAndFilter(command, in_directory, print_messages, print_stdout, fail_status=None, filter_fn=None): """Runs command, a list, in directory in_directory. If print_messages is true, a message indicating what is being done is printed to stdout. If print_messages is false, the message is printed only if we ... | 457,972 |
def CMDrecurse(parser, args): """Operates on all the entries. Runs a shell command on all entries. """ # Stop parsing at the first non-arg so that these go through to the command parser.disable_interspersed_args() parser.add_option('-s', '--scm', action='append', default=[], help='choose scm types to operate upon') op... | def CMDrecurse(parser, args): """Operates on all the entries. Runs a shell command on all entries. """ # Stop parsing at the first non-arg so that these go through to the command parser.disable_interspersed_args() parser.add_option('-s', '--scm', action='append', default=[], help='choose scm types to operate upon') op... | 457,973 |
def CloseIssue(self): """Closes the Rietveld issue for this changelist.""" data = [("description", self.description),] ctype, body = upload.EncodeMultipartFormData(data, []) self.SendToRietveld('/%d/close' % self.issue, body, ctype) | def CloseIssue(self): """Closes the Rietveld issue for this changelist.""" xsrf_token = self.SendToRietveld( '/xsrf_token', extra_headers={'X-Requesting-XSRF-Token': '1'}) data = [("description", self.description), ("xsrf_token", xsrf_token)] ctype, body = upload.EncodeMultipartFormData(data, []) self.SendToRietve... | 457,974 |
def CloseIssue(self): """Closes the Rietveld issue for this changelist.""" data = [("description", self.description),] ctype, body = upload.EncodeMultipartFormData(data, []) self.SendToRietveld('/%d/close' % self.issue, body, ctype) | def CloseIssue(self): """Closes the Rietveld issue for this changelist.""" data = [("description", self.description),] ctype, body = upload.EncodeMultipartFormData(data, []) self.SendToRietveld('/%d/close' % self.issue, body, ctype) | 457,975 |
def UpdateRietveldDescription(self): """Sets the description for an issue on Rietveld.""" data = [("description", self.description),] ctype, body = upload.EncodeMultipartFormData(data, []) self.SendToRietveld('/%d/description' % self.issue, body, ctype) | def UpdateRietveldDescription(self): """Sets the description for an issue on Rietveld.""" data = [("description", self.description),] ctype, body = upload.EncodeMultipartFormData(data, []) self.SendToRietveld('/%d/description' % self.issue, body, ctype) | 457,976 |
def SendToRietveld(self, request_path, payload=None, content_type="application/octet-stream", timeout=None): """Send a POST/GET to Rietveld. Returns the response body.""" if not self.rietveld: ErrorExit(CODEREVIEW_SETTINGS_FILE_NOT_FOUND) def GetUserCredentials(): """Prompts the user for a username and password.""" em... | def SendToRietveld(self, request_path, timeout=None, **kwargs): """Send a POST/GET to Rietveld. Returns the response body.""" if not self.rietveld: ErrorExit(CODEREVIEW_SETTINGS_FILE_NOT_FOUND) def GetUserCredentials(): """Prompts the user for a username and password.""" email = upload.GetEmail('Email (login for uploa... | 457,977 |
def GetUserCredentials(): """Prompts the user for a username and password.""" email = upload.GetEmail('Email (login for uploading to %s)' % self.rietveld) password = getpass.getpass('Password for %s: ' % email) return email, password | def GetUserCredentials(): """Prompts the user for a username and password.""" email = upload.GetEmail('Email (login for uploading to %s)' % self.rietveld) password = getpass.getpass('Password for %s: ' % email) return email, password | 457,978 |
def commit_svn(repo): """Commits the changes and returns the new revision number.""" to_add = [] to_remove = [] for status, filepath in scm.SVN.CaptureStatus(repo): if status[0] == '?': to_add.append(filepath) elif status[0] == '!': to_remove.append(filepath) if to_add: check_call(['svn', 'add', '--no-auto-props', '-q'... | def commit_svn(repo): """Commits the changes and returns the new revision number.""" to_add = [] to_remove = [] for status, filepath in scm.SVN.CaptureStatus(repo): if status[0] == '?': to_add.append(filepath) elif status[0] == '!': to_remove.append(filepath) if to_add: check_call(['svn', 'add', '--no-auto-props', '-q'... | 457,979 |
def __init__(self, commit=None, upstream_branch=None): self.commit = commit self.verbose = None self.default_presubmit = None self.may_prompt = None | def __init__(self, commit=None, upstream_branch=None): self.commit = commit self.verbose = None self.default_presubmit = None self.may_prompt = None | 457,980 |
def TryChange(argv, file_list, swallow_exception, prog=None): """ Args: argv: Arguments and options. file_list: Default value to pass to --file. swallow_exception: Whether we raise or swallow exceptions. """ # Parse argv parser = optparse.OptionParser(usage=USAGE, version=__version__, prog=prog) parser.add_option("-v",... | def TryChange(argv, file_list, swallow_exception, prog=None): """ Args: argv: Arguments and options. file_list: Default value to pass to --file. swallow_exception: Whether we raise or swallow exceptions. """ # Parse argv parser = optparse.OptionParser(usage=USAGE, version=__version__, prog=prog) parser.add_option("-v",... | 457,981 |
def WebKitRevision(options, opt, value, parser): if not hasattr(options, 'sub_rep'): options.sub_rep = [] if parser.rargs and not parser.rargs[0].startswith('-'): options.sub_rep.append('third_party/WebKit@%s' % parser.rargs.pop(0)) else: options.sub_rep.append('third_party/WebKit') | def WebKitRevision(options, opt, value, parser): if not hasattr(options, 'sub_rep'): options.sub_rep = [] if parser.rargs and not parser.rargs[0].startswith('-'): options.sub_rep.append('third_party/WebKit@%s' % parser.rargs.pop(0)) else: options.sub_rep.append('third_party/WebKit') | 457,982 |
def __init__(self, parent, name, url, safesync_url, custom_deps, custom_vars, deps_file): GClientKeywords.__init__(self) self.parent = parent self.name = name self.url = url self.parsed_url = None # These 2 are only set in .gclient and not in DEPS files. self.safesync_url = safesync_url self.custom_vars = custom_vars o... | def __init__(self, parent, name, url, safesync_url, custom_deps, custom_vars, deps_file): GClientKeywords.__init__(self) self.parent = parent self.name = name self.url = url self.parsed_url = None # These 2 are only set in .gclient and not in DEPS files. self.safesync_url = safesync_url self.custom_vars = custom_vars o... | 457,983 |
def LateOverride(self, url): """Resolves the parsed url from url. | def LateOverride(self, url): """Resolves the parsed url from url. | 457,984 |
def LateOverride(self, url): """Resolves the parsed url from url. | def LateOverride(self, url): """Resolves the parsed url from url. | 457,985 |
def __str__(self): out = [] for i in ('name', 'url', 'safesync_url', 'custom_deps', 'custom_vars', 'deps_hooks', '_file_list'): # 'deps_file' if self.__dict__[i]: out.append('%s: %s' % (i, self.__dict__[i])) | def __str__(self): out = [] for i in ('name', 'url', 'safesync_url', 'custom_deps', 'custom_vars', 'deps_hooks', '_file_list', 'processed', 'hooks_ran'): # 'deps_file' if self.__dict__[i]: out.append('%s: %s' % (i, self.__dict__[i])) | 457,986 |
def FetchUpstreamTuple(cwd): """Returns a tuple containg remote and remote ref, e.g. 'origin', 'refs/heads/master' """ remote = '.' branch = GIT.GetBranch(cwd) upstream_branch = None upstream_branch = GIT.Capture( ['config', 'branch.%s.merge' % branch], error_ok=True)[0].strip() if upstream_branch: remote = GIT.Capture... | def FetchUpstreamTuple(cwd): """Returns a tuple containg remote and remote ref, e.g. 'origin', 'refs/heads/master' """ remote = '.' branch = GIT.GetBranch(cwd) upstream_branch = None upstream_branch = GIT.Capture( ['config', 'branch.%s.merge' % branch], in_directory=cwd, error_ok=True)[0].strip() if upstream_branch: re... | 457,987 |
def FetchUpstreamTuple(cwd): """Returns a tuple containg remote and remote ref, e.g. 'origin', 'refs/heads/master' """ remote = '.' branch = GIT.GetBranch(cwd) upstream_branch = None upstream_branch = GIT.Capture( ['config', 'branch.%s.merge' % branch], error_ok=True)[0].strip() if upstream_branch: remote = GIT.Capture... | def FetchUpstreamTuple(cwd): """Returns a tuple containg remote and remote ref, e.g. 'origin', 'refs/heads/master' """ remote = '.' branch = GIT.GetBranch(cwd) upstream_branch = None upstream_branch = GIT.Capture( ['config', 'branch.%s.merge' % branch], in_directory=cwd, error_ok=True)[0].strip() if upstream_branch: re... | 457,988 |
def FetchUpstreamTuple(cwd): """Returns a tuple containg remote and remote ref, e.g. 'origin', 'refs/heads/master' """ remote = '.' branch = GIT.GetBranch(cwd) upstream_branch = None upstream_branch = GIT.Capture( ['config', 'branch.%s.merge' % branch], error_ok=True)[0].strip() if upstream_branch: remote = GIT.Capture... | def FetchUpstreamTuple(cwd): """Returns a tuple containg remote and remote ref, e.g. 'origin', 'refs/heads/master' """ remote = '.' branch = GIT.GetBranch(cwd) upstream_branch = None upstream_branch = GIT.Capture( ['config', 'branch.%s.merge' % branch], error_ok=True)[0].strip() if upstream_branch: remote = GIT.Capture... | 457,989 |
def __init__(self, test_case, verbose=False, revision=None): self.verbose = verbose self.revision = revision self.manually_grab_svn_rev = True self.deps_os = None self.force = False self.reset = False self.nohooks = False self.stdout = gclient_scm.sys.stdout | def __init__(self, verbose=False, revision=None): self.verbose = verbose self.revision = revision self.manually_grab_svn_rev = True self.deps_os = None self.force = False self.reset = False self.nohooks = False self.stdout = gclient_scm.sys.stdout | 457,990 |
def Options(self, *args, **kwargs): return self.OptionsObject(self, *args, **kwargs) | def Options(self, *args, **kwargs): return self.OptionsObject(self, *args, **kwargs) | 457,991 |
def __init__(self, test_case, verbose=False, revision=None): self.verbose = verbose self.revision = revision self.manually_grab_svn_rev = True self.deps_os = None self.force = False self.reset = False self.nohooks = False self.stdout = gclient_scm.sys.stdout | def __init__(self, verbose=False, revision=None): self.verbose = verbose self.revision = revision self.manually_grab_svn_rev = True self.deps_os = None self.force = False self.reset = False self.nohooks = False self.stdout = gclient_scm.sys.stdout | 457,992 |
def Options(self, *args, **kwargs): return self.OptionsObject(self, *args, **kwargs) | def Options(self, *args, **kwargs): return self.OptionsObject(self, *args, **kwargs) | 457,993 |
def _SendChangeHTTP(options): """Send a change to the try server using the HTTP protocol.""" if not options.host: raise NoTryServerAccess('Please use the --host option to specify the try ' 'server host to connect to.') if not options.port: raise NoTryServerAccess('Please use the --port option to specify the try ' 'serv... | def _SendChangeHTTP(options): """Send a change to the try server using the HTTP protocol.""" if not options.host: raise NoTryServerAccess('Please use the --host option to specify the try ' 'server host to connect to.') if not options.port: raise NoTryServerAccess('Please use the --port option to specify the try ' 'serv... | 457,994 |
def _SendChangeSVN(options): """Send a change to the try server by committing a diff file on a subversion server.""" if not options.svn_repo: raise NoTryServerAccess('Please use the --svn_repo option to specify the' ' try server svn repository to connect to.') values = _ParseSendChangeOptions(options) description = ''... | def _SendChangeSVN(options): """Send a change to the try server by committing a diff file on a subversion server.""" if not options.svn_repo: raise NoTryServerAccess('Please use the --svn_repo option to specify the' ' try server svn repository to connect to.') values = _ParseSendChangeOptions(options) description = ''... | 457,995 |
def getRevisionLog(url, revision): """Takes an svn url and gets the associated revision.""" command = 'svn log ' + url + " -r"+str(revision) svn_log = subprocess.Popen(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE).stdout.readlines() log = "" pos = 0 for line in svn_log: if (pos > 2): log += line.... | def getRevisionLog(url, revision): """Takes an svn url and gets the associated revision.""" command = 'svn log ' + url + " -r"+str(revision) svn_log = subprocess.Popen(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE).stdout.readlines() return ''.join([l.replace('\r','') for l in svn_log[3:-1]]) | 457,996 |
def main(options, args): revision = options.revert or options.merge # Initialize some variables used below. They can be overwritten by # the drover.properties file. BASE_URL = "svn://svn.chromium.org/chrome" TRUNK_URL = BASE_URL + "/trunk/src" BRANCH_URL = BASE_URL + "/branches/$branch/src" SKIP_CHECK_WORKING = True P... | def main(options, args): revision = options.revert or options.merge # Initialize some variables used below. They can be overwritten by # the drover.properties file. BASE_URL = "svn://svn.chromium.org/chrome" TRUNK_URL = BASE_URL + "/trunk/src" BRANCH_URL = BASE_URL + "/branches/$branch/src" SKIP_CHECK_WORKING = True P... | 457,997 |
def Main(argv): """Doesn't parse the arguments here, just find the right subcommand to execute.""" try: # Do it late so all commands are listed. CMDhelp.usage = ('\n\nCommands are:\n' + '\n'.join([ ' %-10s %s' % (fn[3:], Command(fn[3:]).__doc__.split('\n')[0].strip()) for fn in dir(sys.modules[__name__]) if fn.startsw... | def Main(argv): """Doesn't parse the arguments here, just find the right subcommand to execute.""" try: # Do it late so all commands are listed. CMDhelp.usage = ('\n\nCommands are:\n' + '\n'.join([ ' %-10s %s' % (fn[3:], Command(fn[3:]).__doc__.split('\n')[0].strip()) for fn in dir(sys.modules[__name__]) if fn.startsw... | 457,998 |
def main(argv=None): if argv is None: argv = sys.argv if len(argv) == 1: Help() return 0; try: # Create the directories where we store information about changelists if it # doesn't exist. if not os.path.exists(GetInfoDir()): os.mkdir(GetInfoDir()) if not os.path.exists(GetChangesDir()): os.mkdir(GetChangesDir()) # Fo... | def main(argv=None): if argv is None: argv = sys.argv if len(argv) == 1: Help() return 0; try: # Create the directories where we store information about changelists if it # doesn't exist. if not os.path.exists(GetInfoDir()): os.mkdir(GetInfoDir()) if not os.path.exists(GetChangesDir()): os.mkdir(GetChangesDir()) # Fo... | 457,999 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.