repo
stringlengths
7
54
path
stringlengths
4
223
func_name
stringlengths
1
134
original_string
stringlengths
75
104k
language
stringclasses
1 value
code
stringlengths
75
104k
code_tokens
listlengths
20
28.4k
docstring
stringlengths
1
46.3k
docstring_tokens
listlengths
1
1.66k
sha
stringlengths
40
40
url
stringlengths
87
315
partition
stringclasses
1 value
summary
stringlengths
4
350
obf_code
stringlengths
7.85k
764k
kivy/python-for-android
pythonforandroid/recipes/gevent/__init__.py
GeventRecipe.get_recipe_env
def get_recipe_env(self, arch=None, with_flags_in_cc=True): """ - Moves all -I<inc> -D<macro> from CFLAGS to CPPFLAGS environment. - Moves all -l<lib> from LDFLAGS to LIBS environment. - Fixes linker name (use cross compiler) and flags (appends LIBS) """ env = super(Geve...
python
def get_recipe_env(self, arch=None, with_flags_in_cc=True): """ - Moves all -I<inc> -D<macro> from CFLAGS to CPPFLAGS environment. - Moves all -l<lib> from LDFLAGS to LIBS environment. - Fixes linker name (use cross compiler) and flags (appends LIBS) """ env = super(Geve...
[ "def", "get_recipe_env", "(", "self", ",", "arch", "=", "None", ",", "with_flags_in_cc", "=", "True", ")", ":", "env", "=", "super", "(", "GeventRecipe", ",", "self", ")", ".", "get_recipe_env", "(", "arch", ",", "with_flags_in_cc", ")", "# CFLAGS may only b...
- Moves all -I<inc> -D<macro> from CFLAGS to CPPFLAGS environment. - Moves all -l<lib> from LDFLAGS to LIBS environment. - Fixes linker name (use cross compiler) and flags (appends LIBS)
[ "-", "Moves", "all", "-", "I<inc", ">", "-", "D<macro", ">", "from", "CFLAGS", "to", "CPPFLAGS", "environment", ".", "-", "Moves", "all", "-", "l<lib", ">", "from", "LDFLAGS", "to", "LIBS", "environment", ".", "-", "Fixes", "linker", "name", "(", "use"...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/gevent/__init__.py#L12-L29
train
Returns the environment dictionary for the gevent recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py
extract_from_ast
def extract_from_ast(node, gettext_functions=GETTEXT_FUNCTIONS, babel_style=True): """Extract localizable strings from the given template node. Per default this function returns matches in babel style that means non string parameters as well as keyword arguments are returned as `None`....
python
def extract_from_ast(node, gettext_functions=GETTEXT_FUNCTIONS, babel_style=True): """Extract localizable strings from the given template node. Per default this function returns matches in babel style that means non string parameters as well as keyword arguments are returned as `None`....
[ "def", "extract_from_ast", "(", "node", ",", "gettext_functions", "=", "GETTEXT_FUNCTIONS", ",", "babel_style", "=", "True", ")", ":", "for", "node", "in", "node", ".", "find_all", "(", "nodes", ".", "Call", ")", ":", "if", "not", "isinstance", "(", "node"...
Extract localizable strings from the given template node. Per default this function returns matches in babel style that means non string parameters as well as keyword arguments are returned as `None`. This allows Babel to figure out what you really meant if you are using gettext functions that allow k...
[ "Extract", "localizable", "strings", "from", "the", "given", "template", "node", ".", "Per", "default", "this", "function", "returns", "matches", "in", "babel", "style", "that", "means", "non", "string", "parameters", "as", "well", "as", "keyword", "arguments", ...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py#L381-L446
train
Extract localizable strings from the given template node.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py
babel_extract
def babel_extract(fileobj, keywords, comment_tags, options): """Babel extraction method for Jinja templates. .. versionchanged:: 2.3 Basic support for translation comments was added. If `comment_tags` is now set to a list of keywords for extraction, the extractor will try to find the best...
python
def babel_extract(fileobj, keywords, comment_tags, options): """Babel extraction method for Jinja templates. .. versionchanged:: 2.3 Basic support for translation comments was added. If `comment_tags` is now set to a list of keywords for extraction, the extractor will try to find the best...
[ "def", "babel_extract", "(", "fileobj", ",", "keywords", ",", "comment_tags", ",", "options", ")", ":", "extensions", "=", "set", "(", ")", "for", "extension", "in", "options", ".", "get", "(", "'extensions'", ",", "''", ")", ".", "split", "(", "','", ...
Babel extraction method for Jinja templates. .. versionchanged:: 2.3 Basic support for translation comments was added. If `comment_tags` is now set to a list of keywords for extraction, the extractor will try to find the best preceeding comment that begins with one of the keywords. Fo...
[ "Babel", "extraction", "method", "for", "Jinja", "templates", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py#L486-L545
train
This method is used to extract a set of translation functions from a file - like object.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py
InternationalizationExtension.parse
def parse(self, parser): """Parse a translatable tag.""" lineno = next(parser.stream).lineno # find all the variables referenced. Additionally a variable can be # defined in the body of the trans block too, but this is checked at # a later state. plural_expr = None ...
python
def parse(self, parser): """Parse a translatable tag.""" lineno = next(parser.stream).lineno # find all the variables referenced. Additionally a variable can be # defined in the body of the trans block too, but this is checked at # a later state. plural_expr = None ...
[ "def", "parse", "(", "self", ",", "parser", ")", ":", "lineno", "=", "next", "(", "parser", ".", "stream", ")", ".", "lineno", "# find all the variables referenced. Additionally a variable can be", "# defined in the body of the trans block too, but this is checked at", "# a ...
Parse a translatable tag.
[ "Parse", "a", "translatable", "tag", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py#L175-L262
train
Parse a translatable tag.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py
InternationalizationExtension._make_node
def _make_node(self, singular, plural, variables, plural_expr): """Generates a useful node from the data provided.""" # singular only: if plural_expr is None: gettext = nodes.Name('gettext', 'load') node = nodes.Call(gettext, [nodes.Const(singular)], ...
python
def _make_node(self, singular, plural, variables, plural_expr): """Generates a useful node from the data provided.""" # singular only: if plural_expr is None: gettext = nodes.Name('gettext', 'load') node = nodes.Call(gettext, [nodes.Const(singular)], ...
[ "def", "_make_node", "(", "self", ",", "singular", ",", "plural", ",", "variables", ",", "plural_expr", ")", ":", "# singular only:", "if", "plural_expr", "is", "None", ":", "gettext", "=", "nodes", ".", "Name", "(", "'gettext'", ",", "'load'", ")", "node"...
Generates a useful node from the data provided.
[ "Generates", "a", "useful", "node", "from", "the", "data", "provided", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/ext.py#L296-L320
train
Generates a useful node from the data provided.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
load_extensions
def load_extensions(environment, extensions): """Load the extensions from the list and bind it to the environment. Returns a dict of instanciated environments. """ result = {} for extension in extensions: if isinstance(extension, basestring): extension = import_string(extension) ...
python
def load_extensions(environment, extensions): """Load the extensions from the list and bind it to the environment. Returns a dict of instanciated environments. """ result = {} for extension in extensions: if isinstance(extension, basestring): extension = import_string(extension) ...
[ "def", "load_extensions", "(", "environment", ",", "extensions", ")", ":", "result", "=", "{", "}", "for", "extension", "in", "extensions", ":", "if", "isinstance", "(", "extension", ",", "basestring", ")", ":", "extension", "=", "import_string", "(", "exten...
Load the extensions from the list and bind it to the environment. Returns a dict of instanciated environments.
[ "Load", "the", "extensions", "from", "the", "list", "and", "bind", "it", "to", "the", "environment", ".", "Returns", "a", "dict", "of", "instanciated", "environments", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L68-L77
train
Load the extensions from the list and bind it to the environment.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Environment.extend
def extend(self, **attributes): """Add the items to the instance of the environment if they do not exist yet. This is used by :ref:`extensions <writing-extensions>` to register callbacks and configuration values without breaking inheritance. """ for key, value in attributes.iter...
python
def extend(self, **attributes): """Add the items to the instance of the environment if they do not exist yet. This is used by :ref:`extensions <writing-extensions>` to register callbacks and configuration values without breaking inheritance. """ for key, value in attributes.iter...
[ "def", "extend", "(", "self", ",", "*", "*", "attributes", ")", ":", "for", "key", ",", "value", "in", "attributes", ".", "iteritems", "(", ")", ":", "if", "not", "hasattr", "(", "self", ",", "key", ")", ":", "setattr", "(", "self", ",", "key", "...
Add the items to the instance of the environment if they do not exist yet. This is used by :ref:`extensions <writing-extensions>` to register callbacks and configuration values without breaking inheritance.
[ "Add", "the", "items", "to", "the", "instance", "of", "the", "environment", "if", "they", "do", "not", "exist", "yet", ".", "This", "is", "used", "by", ":", "ref", ":", "extensions", "<writing", "-", "extensions", ">", "to", "register", "callbacks", "and...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L282-L289
train
Add the items to the instance of the environment if they do not exist yet.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Environment._parse
def _parse(self, source, name, filename): """Internal parsing function used by `parse` and `compile`.""" return Parser(self, source, name, _encode_filename(filename)).parse()
python
def _parse(self, source, name, filename): """Internal parsing function used by `parse` and `compile`.""" return Parser(self, source, name, _encode_filename(filename)).parse()
[ "def", "_parse", "(", "self", ",", "source", ",", "name", ",", "filename", ")", ":", "return", "Parser", "(", "self", ",", "source", ",", "name", ",", "_encode_filename", "(", "filename", ")", ")", ".", "parse", "(", ")" ]
Internal parsing function used by `parse` and `compile`.
[ "Internal", "parsing", "function", "used", "by", "parse", "and", "compile", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L388-L390
train
Internal parsing function used by parse and compile.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Environment.preprocess
def preprocess(self, source, name=None, filename=None): """Preprocesses the source with all extensions. This is automatically called for all parsing and compiling methods but *not* for :meth:`lex` because there you usually only want the actual source tokenized. """ return reduce...
python
def preprocess(self, source, name=None, filename=None): """Preprocesses the source with all extensions. This is automatically called for all parsing and compiling methods but *not* for :meth:`lex` because there you usually only want the actual source tokenized. """ return reduce...
[ "def", "preprocess", "(", "self", ",", "source", ",", "name", "=", "None", ",", "filename", "=", "None", ")", ":", "return", "reduce", "(", "lambda", "s", ",", "e", ":", "e", ".", "preprocess", "(", "s", ",", "name", ",", "filename", ")", ",", "s...
Preprocesses the source with all extensions. This is automatically called for all parsing and compiling methods but *not* for :meth:`lex` because there you usually only want the actual source tokenized.
[ "Preprocesses", "the", "source", "with", "all", "extensions", ".", "This", "is", "automatically", "called", "for", "all", "parsing", "and", "compiling", "methods", "but", "*", "not", "*", "for", ":", "meth", ":", "lex", "because", "there", "you", "usually", ...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L409-L415
train
Preprocesses the source with all extensions.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Environment.compile
def compile(self, source, name=None, filename=None, raw=False, defer_init=False): """Compile a node or template source code. The `name` parameter is the load name of the template after it was joined using :meth:`join_path` if necessary, not the filename on the file system. ...
python
def compile(self, source, name=None, filename=None, raw=False, defer_init=False): """Compile a node or template source code. The `name` parameter is the load name of the template after it was joined using :meth:`join_path` if necessary, not the filename on the file system. ...
[ "def", "compile", "(", "self", ",", "source", ",", "name", "=", "None", ",", "filename", "=", "None", ",", "raw", "=", "False", ",", "defer_init", "=", "False", ")", ":", "source_hint", "=", "None", "try", ":", "if", "isinstance", "(", "source", ",",...
Compile a node or template source code. The `name` parameter is the load name of the template after it was joined using :meth:`join_path` if necessary, not the filename on the file system. the `filename` parameter is the estimated filename of the template on the file system. If the tem...
[ "Compile", "a", "node", "or", "template", "source", "code", ".", "The", "name", "parameter", "is", "the", "load", "name", "of", "the", "template", "after", "it", "was", "joined", "using", ":", "meth", ":", "join_path", "if", "necessary", "not", "the", "f...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L430-L469
train
Compile a node or template source code.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Template.render
def render(self, *args, **kwargs): """This method accepts the same arguments as the `dict` constructor: A dict, a dict subclass or some keyword arguments. If no arguments are given the context will be empty. These two calls do the same:: template.render(knights='that say nih') ...
python
def render(self, *args, **kwargs): """This method accepts the same arguments as the `dict` constructor: A dict, a dict subclass or some keyword arguments. If no arguments are given the context will be empty. These two calls do the same:: template.render(knights='that say nih') ...
[ "def", "render", "(", "self", ",", "*", "args", ",", "*", "*", "kwargs", ")", ":", "vars", "=", "dict", "(", "*", "args", ",", "*", "*", "kwargs", ")", "try", ":", "return", "concat", "(", "self", ".", "root_render_func", "(", "self", ".", "new_c...
This method accepts the same arguments as the `dict` constructor: A dict, a dict subclass or some keyword arguments. If no arguments are given the context will be empty. These two calls do the same:: template.render(knights='that say nih') template.render({'knights': 'that say...
[ "This", "method", "accepts", "the", "same", "arguments", "as", "the", "dict", "constructor", ":", "A", "dict", "a", "dict", "subclass", "or", "some", "keyword", "arguments", ".", "If", "no", "arguments", "are", "given", "the", "context", "will", "be", "emp...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L853-L868
train
This method renders the template with the given arguments.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Template.generate
def generate(self, *args, **kwargs): """For very large templates it can be useful to not render the whole template at once but evaluate each statement after another and yield piece for piece. This method basically does exactly that and returns a generator that yields one item after anot...
python
def generate(self, *args, **kwargs): """For very large templates it can be useful to not render the whole template at once but evaluate each statement after another and yield piece for piece. This method basically does exactly that and returns a generator that yields one item after anot...
[ "def", "generate", "(", "self", ",", "*", "args", ",", "*", "*", "kwargs", ")", ":", "vars", "=", "dict", "(", "*", "args", ",", "*", "*", "kwargs", ")", "try", ":", "for", "event", "in", "self", ".", "root_render_func", "(", "self", ".", "new_co...
For very large templates it can be useful to not render the whole template at once but evaluate each statement after another and yield piece for piece. This method basically does exactly that and returns a generator that yields one item after another as unicode strings. It accepts the ...
[ "For", "very", "large", "templates", "it", "can", "be", "useful", "to", "not", "render", "the", "whole", "template", "at", "once", "but", "evaluate", "each", "statement", "after", "another", "and", "yield", "piece", "for", "piece", ".", "This", "method", "...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L876-L892
train
Generate a generator that yields one item after another.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Template.module
def module(self): """The template as module. This is used for imports in the template runtime but is also useful if one wants to access exported template variables from the Python layer: >>> t = Template('{% macro foo() %}42{% endmacro %}23') >>> unicode(t.module) u'23'...
python
def module(self): """The template as module. This is used for imports in the template runtime but is also useful if one wants to access exported template variables from the Python layer: >>> t = Template('{% macro foo() %}42{% endmacro %}23') >>> unicode(t.module) u'23'...
[ "def", "module", "(", "self", ")", ":", "if", "self", ".", "_module", "is", "not", "None", ":", "return", "self", ".", "_module", "self", ".", "_module", "=", "rv", "=", "self", ".", "make_module", "(", ")", "return", "rv" ]
The template as module. This is used for imports in the template runtime but is also useful if one wants to access exported template variables from the Python layer: >>> t = Template('{% macro foo() %}42{% endmacro %}23') >>> unicode(t.module) u'23' >>> t.module.foo() ...
[ "The", "template", "as", "module", ".", "This", "is", "used", "for", "imports", "in", "the", "template", "runtime", "but", "is", "also", "useful", "if", "one", "wants", "to", "access", "exported", "template", "variables", "from", "the", "Python", "layer", ...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L915-L929
train
The module that contains the available template variables.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
Template.debug_info
def debug_info(self): """The debug info mapping.""" return [tuple(map(int, x.split('='))) for x in self._debug_info.split('&')]
python
def debug_info(self): """The debug info mapping.""" return [tuple(map(int, x.split('='))) for x in self._debug_info.split('&')]
[ "def", "debug_info", "(", "self", ")", ":", "return", "[", "tuple", "(", "map", "(", "int", ",", "x", ".", "split", "(", "'='", ")", ")", ")", "for", "x", "in", "self", ".", "_debug_info", ".", "split", "(", "'&'", ")", "]" ]
The debug info mapping.
[ "The", "debug", "info", "mapping", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L948-L951
train
The debug info mapping.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
TemplateStream.dump
def dump(self, fp, encoding=None, errors='strict'): """Dump the complete stream into a file or file-like object. Per default unicode strings are written, if you want to encode before writing specifiy an `encoding`. Example usage:: Template('Hello {{ name }}!').stream(name='...
python
def dump(self, fp, encoding=None, errors='strict'): """Dump the complete stream into a file or file-like object. Per default unicode strings are written, if you want to encode before writing specifiy an `encoding`. Example usage:: Template('Hello {{ name }}!').stream(name='...
[ "def", "dump", "(", "self", ",", "fp", ",", "encoding", "=", "None", ",", "errors", "=", "'strict'", ")", ":", "close", "=", "False", "if", "isinstance", "(", "fp", ",", "basestring", ")", ":", "fp", "=", "file", "(", "fp", ",", "'w'", ")", "clos...
Dump the complete stream into a file or file-like object. Per default unicode strings are written, if you want to encode before writing specifiy an `encoding`. Example usage:: Template('Hello {{ name }}!').stream(name='foo').dump('hello.html')
[ "Dump", "the", "complete", "stream", "into", "a", "file", "or", "file", "-", "like", "object", ".", "Per", "default", "unicode", "strings", "are", "written", "if", "you", "want", "to", "encode", "before", "writing", "specifiy", "an", "encoding", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L1027-L1052
train
Dump the complete stream into a file - like object.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
TemplateStream.disable_buffering
def disable_buffering(self): """Disable the output buffering.""" self._next = self._gen.next self.buffered = False
python
def disable_buffering(self): """Disable the output buffering.""" self._next = self._gen.next self.buffered = False
[ "def", "disable_buffering", "(", "self", ")", ":", "self", ".", "_next", "=", "self", ".", "_gen", ".", "next", "self", ".", "buffered", "=", "False" ]
Disable the output buffering.
[ "Disable", "the", "output", "buffering", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L1054-L1057
train
Disable the output buffering.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py
TemplateStream.enable_buffering
def enable_buffering(self, size=5): """Enable buffering. Buffer `size` items before yielding them.""" if size <= 1: raise ValueError('buffer size too small') def generator(next): buf = [] c_size = 0 push = buf.append while 1: ...
python
def enable_buffering(self, size=5): """Enable buffering. Buffer `size` items before yielding them.""" if size <= 1: raise ValueError('buffer size too small') def generator(next): buf = [] c_size = 0 push = buf.append while 1: ...
[ "def", "enable_buffering", "(", "self", ",", "size", "=", "5", ")", ":", "if", "size", "<=", "1", ":", "raise", "ValueError", "(", "'buffer size too small'", ")", "def", "generator", "(", "next", ")", ":", "buf", "=", "[", "]", "c_size", "=", "0", "p...
Enable buffering. Buffer `size` items before yielding them.
[ "Enable", "buffering", ".", "Buffer", "size", "items", "before", "yielding", "them", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/environment.py#L1059-L1084
train
Enable buffering.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
require_prebuilt_dist
def require_prebuilt_dist(func): """Decorator for ToolchainCL methods. If present, the method will automatically make sure a dist has been built before continuing or, if no dists are present or can be obtained, will raise an error. """ @wraps(func) def wrapper_func(self, args): ctx ...
python
def require_prebuilt_dist(func): """Decorator for ToolchainCL methods. If present, the method will automatically make sure a dist has been built before continuing or, if no dists are present or can be obtained, will raise an error. """ @wraps(func) def wrapper_func(self, args): ctx ...
[ "def", "require_prebuilt_dist", "(", "func", ")", ":", "@", "wraps", "(", "func", ")", "def", "wrapper_func", "(", "self", ",", "args", ")", ":", "ctx", "=", "self", ".", "ctx", "ctx", ".", "set_archs", "(", "self", ".", "_archs", ")", "ctx", ".", ...
Decorator for ToolchainCL methods. If present, the method will automatically make sure a dist has been built before continuing or, if no dists are present or can be obtained, will raise an error.
[ "Decorator", "for", "ToolchainCL", "methods", ".", "If", "present", "the", "method", "will", "automatically", "make", "sure", "a", "dist", "has", "been", "built", "before", "continuing", "or", "if", "no", "dists", "are", "present", "or", "can", "be", "obtain...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L131-L154
train
Decorator for ToolchainCL methods.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
dist_from_args
def dist_from_args(ctx, args): """Parses out any distribution-related arguments, and uses them to obtain a Distribution class instance for the build. """ return Distribution.get_distribution( ctx, name=args.dist_name, recipes=split_argument_list(args.requirements), ndk_ap...
python
def dist_from_args(ctx, args): """Parses out any distribution-related arguments, and uses them to obtain a Distribution class instance for the build. """ return Distribution.get_distribution( ctx, name=args.dist_name, recipes=split_argument_list(args.requirements), ndk_ap...
[ "def", "dist_from_args", "(", "ctx", ",", "args", ")", ":", "return", "Distribution", ".", "get_distribution", "(", "ctx", ",", "name", "=", "args", ".", "dist_name", ",", "recipes", "=", "split_argument_list", "(", "args", ".", "requirements", ")", ",", "...
Parses out any distribution-related arguments, and uses them to obtain a Distribution class instance for the build.
[ "Parses", "out", "any", "distribution", "-", "related", "arguments", "and", "uses", "them", "to", "obtain", "a", "Distribution", "class", "instance", "for", "the", "build", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L157-L168
train
Parses out any distribution - related arguments and uses them to obtain a Distribution class instance for the build.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
build_dist_from_args
def build_dist_from_args(ctx, dist, args): """Parses out any bootstrap related arguments, and uses them to build a dist.""" bs = Bootstrap.get_bootstrap(args.bootstrap, ctx) blacklist = getattr(args, "blacklist_requirements", "").split(",") if len(blacklist) == 1 and blacklist[0] == "": blac...
python
def build_dist_from_args(ctx, dist, args): """Parses out any bootstrap related arguments, and uses them to build a dist.""" bs = Bootstrap.get_bootstrap(args.bootstrap, ctx) blacklist = getattr(args, "blacklist_requirements", "").split(",") if len(blacklist) == 1 and blacklist[0] == "": blac...
[ "def", "build_dist_from_args", "(", "ctx", ",", "dist", ",", "args", ")", ":", "bs", "=", "Bootstrap", ".", "get_bootstrap", "(", "args", ".", "bootstrap", ",", "ctx", ")", "blacklist", "=", "getattr", "(", "args", ",", "\"blacklist_requirements\"", ",", "...
Parses out any bootstrap related arguments, and uses them to build a dist.
[ "Parses", "out", "any", "bootstrap", "related", "arguments", "and", "uses", "them", "to", "build", "a", "dist", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L171-L210
train
Parses out any bootstrap related arguments and uses them to build a dist.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.warn_on_deprecated_args
def warn_on_deprecated_args(self, args): """ Print warning messages for any deprecated arguments that were passed. """ # Output warning if setup.py is present and neither --ignore-setup-py # nor --use-setup-py was specified. if getattr(args, "private", None) is not None ...
python
def warn_on_deprecated_args(self, args): """ Print warning messages for any deprecated arguments that were passed. """ # Output warning if setup.py is present and neither --ignore-setup-py # nor --use-setup-py was specified. if getattr(args, "private", None) is not None ...
[ "def", "warn_on_deprecated_args", "(", "self", ",", "args", ")", ":", "# Output warning if setup.py is present and neither --ignore-setup-py", "# nor --use-setup-py was specified.", "if", "getattr", "(", "args", ",", "\"private\"", ",", "None", ")", "is", "not", "None", "...
Print warning messages for any deprecated arguments that were passed.
[ "Print", "warning", "messages", "for", "any", "deprecated", "arguments", "that", "were", "passed", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L669-L699
train
Print warning messages for any deprecated arguments that were passed.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.bootstraps
def bootstraps(self, _args): """List all the bootstraps available to build with.""" for bs in Bootstrap.list_bootstraps(): bs = Bootstrap.get_bootstrap(bs, self.ctx) print('{Fore.BLUE}{Style.BRIGHT}{bs.name}{Style.RESET_ALL}' .format(bs=bs, Fore=Out_Fore, Style=...
python
def bootstraps(self, _args): """List all the bootstraps available to build with.""" for bs in Bootstrap.list_bootstraps(): bs = Bootstrap.get_bootstrap(bs, self.ctx) print('{Fore.BLUE}{Style.BRIGHT}{bs.name}{Style.RESET_ALL}' .format(bs=bs, Fore=Out_Fore, Style=...
[ "def", "bootstraps", "(", "self", ",", "_args", ")", ":", "for", "bs", "in", "Bootstrap", ".", "list_bootstraps", "(", ")", ":", "bs", "=", "Bootstrap", ".", "get_bootstrap", "(", "bs", ",", "self", ".", "ctx", ")", "print", "(", "'{Fore.BLUE}{Style.BRIG...
List all the bootstraps available to build with.
[ "List", "all", "the", "bootstraps", "available", "to", "build", "with", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L767-L774
train
List all the bootstraps available to build with.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.clean_all
def clean_all(self, args): """Delete all build components; the package cache, package builds, bootstrap builds and distributions.""" self.clean_dists(args) self.clean_builds(args) self.clean_download_cache(args)
python
def clean_all(self, args): """Delete all build components; the package cache, package builds, bootstrap builds and distributions.""" self.clean_dists(args) self.clean_builds(args) self.clean_download_cache(args)
[ "def", "clean_all", "(", "self", ",", "args", ")", ":", "self", ".", "clean_dists", "(", "args", ")", "self", ".", "clean_builds", "(", "args", ")", "self", ".", "clean_download_cache", "(", "args", ")" ]
Delete all build components; the package cache, package builds, bootstrap builds and distributions.
[ "Delete", "all", "build", "components", ";", "the", "package", "cache", "package", "builds", "bootstrap", "builds", "and", "distributions", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L794-L799
train
Delete all build components ; the package cache package builds bootstrap builds and distributions.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.clean_dists
def clean_dists(self, _args): """Delete all compiled distributions in the internal distribution directory.""" ctx = self.ctx if exists(ctx.dist_dir): shutil.rmtree(ctx.dist_dir)
python
def clean_dists(self, _args): """Delete all compiled distributions in the internal distribution directory.""" ctx = self.ctx if exists(ctx.dist_dir): shutil.rmtree(ctx.dist_dir)
[ "def", "clean_dists", "(", "self", ",", "_args", ")", ":", "ctx", "=", "self", ".", "ctx", "if", "exists", "(", "ctx", ".", "dist_dir", ")", ":", "shutil", ".", "rmtree", "(", "ctx", ".", "dist_dir", ")" ]
Delete all compiled distributions in the internal distribution directory.
[ "Delete", "all", "compiled", "distributions", "in", "the", "internal", "distribution", "directory", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L801-L806
train
Delete all compiled distributions in the internal distribution directory.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.clean_bootstrap_builds
def clean_bootstrap_builds(self, _args): """Delete all the bootstrap builds.""" if exists(join(self.ctx.build_dir, 'bootstrap_builds')): shutil.rmtree(join(self.ctx.build_dir, 'bootstrap_builds'))
python
def clean_bootstrap_builds(self, _args): """Delete all the bootstrap builds.""" if exists(join(self.ctx.build_dir, 'bootstrap_builds')): shutil.rmtree(join(self.ctx.build_dir, 'bootstrap_builds'))
[ "def", "clean_bootstrap_builds", "(", "self", ",", "_args", ")", ":", "if", "exists", "(", "join", "(", "self", ".", "ctx", ".", "build_dir", ",", "'bootstrap_builds'", ")", ")", ":", "shutil", ".", "rmtree", "(", "join", "(", "self", ".", "ctx", ".", ...
Delete all the bootstrap builds.
[ "Delete", "all", "the", "bootstrap", "builds", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L808-L811
train
Delete all the bootstrap builds.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.clean_builds
def clean_builds(self, _args): """Delete all build caches for each recipe, python-install, java code and compiled libs collection. This does *not* delete the package download cache or the final distributions. You can also use clean_recipe_build to delete the build of a specific...
python
def clean_builds(self, _args): """Delete all build caches for each recipe, python-install, java code and compiled libs collection. This does *not* delete the package download cache or the final distributions. You can also use clean_recipe_build to delete the build of a specific...
[ "def", "clean_builds", "(", "self", ",", "_args", ")", ":", "ctx", "=", "self", ".", "ctx", "if", "exists", "(", "ctx", ".", "build_dir", ")", ":", "shutil", ".", "rmtree", "(", "ctx", ".", "build_dir", ")", "if", "exists", "(", "ctx", ".", "python...
Delete all build caches for each recipe, python-install, java code and compiled libs collection. This does *not* delete the package download cache or the final distributions. You can also use clean_recipe_build to delete the build of a specific recipe.
[ "Delete", "all", "build", "caches", "for", "each", "recipe", "python", "-", "install", "java", "code", "and", "compiled", "libs", "collection", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L818-L833
train
Delete all build caches for each recipe python - install java code and compiled libs collection.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.clean_recipe_build
def clean_recipe_build(self, args): """Deletes the build files of the given recipe. This is intended for debug purposes. You may experience strange behaviour or problems with some recipes if their build has made unexpected state changes. If this happens, run clean_builds, or att...
python
def clean_recipe_build(self, args): """Deletes the build files of the given recipe. This is intended for debug purposes. You may experience strange behaviour or problems with some recipes if their build has made unexpected state changes. If this happens, run clean_builds, or att...
[ "def", "clean_recipe_build", "(", "self", ",", "args", ")", ":", "recipe", "=", "Recipe", ".", "get_recipe", "(", "args", ".", "recipe", ",", "self", ".", "ctx", ")", "info", "(", "'Cleaning build for {} recipe.'", ".", "format", "(", "recipe", ".", "name"...
Deletes the build files of the given recipe. This is intended for debug purposes. You may experience strange behaviour or problems with some recipes if their build has made unexpected state changes. If this happens, run clean_builds, or attempt to clean other recipes until things ...
[ "Deletes", "the", "build", "files", "of", "the", "given", "recipe", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L835-L848
train
Deletes the build files of the given recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.clean_download_cache
def clean_download_cache(self, args): """ Deletes a download cache for recipes passed as arguments. If no argument is passed, it'll delete *all* downloaded caches. :: p4a clean_download_cache kivy,pyjnius This does *not* delete the build caches or final distributions. """ ...
python
def clean_download_cache(self, args): """ Deletes a download cache for recipes passed as arguments. If no argument is passed, it'll delete *all* downloaded caches. :: p4a clean_download_cache kivy,pyjnius This does *not* delete the build caches or final distributions. """ ...
[ "def", "clean_download_cache", "(", "self", ",", "args", ")", ":", "ctx", "=", "self", ".", "ctx", "if", "hasattr", "(", "args", ",", "'recipes'", ")", "and", "args", ".", "recipes", ":", "for", "package", "in", "args", ".", "recipes", ":", "remove_pat...
Deletes a download cache for recipes passed as arguments. If no argument is passed, it'll delete *all* downloaded caches. :: p4a clean_download_cache kivy,pyjnius This does *not* delete the build caches or final distributions.
[ "Deletes", "a", "download", "cache", "for", "recipes", "passed", "as", "arguments", ".", "If", "no", "argument", "is", "passed", "it", "ll", "delete", "*", "all", "*", "downloaded", "caches", ".", "::" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L850-L873
train
Cleans up the download cache for recipes passed as arguments.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.export_dist
def export_dist(self, args): """Copies a created dist to an output dir. This makes it easy to navigate to the dist to investigate it or call build.py, though you do not in general need to do this and can use the apk command instead. """ ctx = self.ctx dist = dist...
python
def export_dist(self, args): """Copies a created dist to an output dir. This makes it easy to navigate to the dist to investigate it or call build.py, though you do not in general need to do this and can use the apk command instead. """ ctx = self.ctx dist = dist...
[ "def", "export_dist", "(", "self", ",", "args", ")", ":", "ctx", "=", "self", ".", "ctx", "dist", "=", "dist_from_args", "(", "ctx", ",", "args", ")", "if", "dist", ".", "needs_build", ":", "raise", "BuildInterruptingException", "(", "'You asked to export a ...
Copies a created dist to an output dir. This makes it easy to navigate to the dist to investigate it or call build.py, though you do not in general need to do this and can use the apk command instead.
[ "Copies", "a", "created", "dist", "to", "an", "output", "dir", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L876-L893
train
Copies a created dist to an output dir.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.apk
def apk(self, args): """Create an APK using the given distribution.""" ctx = self.ctx dist = self._dist # Manually fixing these arguments at the string stage is # unsatisfactory and should probably be changed somehow, but # we can't leave it until later as the build.py ...
python
def apk(self, args): """Create an APK using the given distribution.""" ctx = self.ctx dist = self._dist # Manually fixing these arguments at the string stage is # unsatisfactory and should probably be changed somehow, but # we can't leave it until later as the build.py ...
[ "def", "apk", "(", "self", ",", "args", ")", ":", "ctx", "=", "self", ".", "ctx", "dist", "=", "self", ".", "_dist", "# Manually fixing these arguments at the string stage is", "# unsatisfactory and should probably be changed somehow, but", "# we can't leave it until later as...
Create an APK using the given distribution.
[ "Create", "an", "APK", "using", "the", "given", "distribution", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L902-L1055
train
Create an APK using the given distribution.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.archs
def archs(self, _args): """List the target architectures available to be built for.""" print('{Style.BRIGHT}Available target architectures are:' '{Style.RESET_ALL}'.format(Style=Out_Style)) for arch in self.ctx.archs: print(' {}'.format(arch.arch))
python
def archs(self, _args): """List the target architectures available to be built for.""" print('{Style.BRIGHT}Available target architectures are:' '{Style.RESET_ALL}'.format(Style=Out_Style)) for arch in self.ctx.archs: print(' {}'.format(arch.arch))
[ "def", "archs", "(", "self", ",", "_args", ")", ":", "print", "(", "'{Style.BRIGHT}Available target architectures are:'", "'{Style.RESET_ALL}'", ".", "format", "(", "Style", "=", "Out_Style", ")", ")", "for", "arch", "in", "self", ".", "ctx", ".", "archs", ":"...
List the target architectures available to be built for.
[ "List", "the", "target", "architectures", "available", "to", "be", "built", "for", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L1064-L1069
train
List the target architectures available to be built for.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.distributions
def distributions(self, _args): """Lists all distributions currently available (i.e. that have already been built).""" ctx = self.ctx dists = Distribution.get_distributions(ctx) if dists: print('{Style.BRIGHT}Distributions currently installed are:' ...
python
def distributions(self, _args): """Lists all distributions currently available (i.e. that have already been built).""" ctx = self.ctx dists = Distribution.get_distributions(ctx) if dists: print('{Style.BRIGHT}Distributions currently installed are:' ...
[ "def", "distributions", "(", "self", ",", "_args", ")", ":", "ctx", "=", "self", ".", "ctx", "dists", "=", "Distribution", ".", "get_distributions", "(", "ctx", ")", "if", "dists", ":", "print", "(", "'{Style.BRIGHT}Distributions currently installed are:'", "'{S...
Lists all distributions currently available (i.e. that have already been built).
[ "Lists", "all", "distributions", "currently", "available", "(", "i", ".", "e", ".", "that", "have", "already", "been", "built", ")", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L1075-L1087
train
Lists all distributions currently installed.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.sdk_tools
def sdk_tools(self, args): """Runs the android binary from the detected SDK directory, passing all arguments straight to it. This binary is used to install e.g. platform-tools for different API level targets. This is intended as a convenience function if android is not in your $P...
python
def sdk_tools(self, args): """Runs the android binary from the detected SDK directory, passing all arguments straight to it. This binary is used to install e.g. platform-tools for different API level targets. This is intended as a convenience function if android is not in your $P...
[ "def", "sdk_tools", "(", "self", ",", "args", ")", ":", "ctx", "=", "self", ".", "ctx", "ctx", ".", "prepare_build_environment", "(", "user_sdk_dir", "=", "self", ".", "sdk_dir", ",", "user_ndk_dir", "=", "self", ".", "ndk_dir", ",", "user_android_api", "=...
Runs the android binary from the detected SDK directory, passing all arguments straight to it. This binary is used to install e.g. platform-tools for different API level targets. This is intended as a convenience function if android is not in your $PATH.
[ "Runs", "the", "android", "binary", "from", "the", "detected", "SDK", "directory", "passing", "all", "arguments", "straight", "to", "it", ".", "This", "binary", "is", "used", "to", "install", "e", ".", "g", ".", "platform", "-", "tools", "for", "different"...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L1097-L1114
train
Runs the android tools from the detected SDK directory passing all arguments straight to it.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL._adb
def _adb(self, commands): """Call the adb executable from the SDK, passing the given commands as arguments.""" ctx = self.ctx ctx.prepare_build_environment(user_sdk_dir=self.sdk_dir, user_ndk_dir=self.ndk_dir, us...
python
def _adb(self, commands): """Call the adb executable from the SDK, passing the given commands as arguments.""" ctx = self.ctx ctx.prepare_build_environment(user_sdk_dir=self.sdk_dir, user_ndk_dir=self.ndk_dir, us...
[ "def", "_adb", "(", "self", ",", "commands", ")", ":", "ctx", "=", "self", ".", "ctx", "ctx", ".", "prepare_build_environment", "(", "user_sdk_dir", "=", "self", ".", "sdk_dir", ",", "user_ndk_dir", "=", "self", ".", "ndk_dir", ",", "user_android_api", "="...
Call the adb executable from the SDK, passing the given commands as arguments.
[ "Call", "the", "adb", "executable", "from", "the", "SDK", "passing", "the", "given", "commands", "as", "arguments", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L1128-L1144
train
Call the adb executable from the SDK passing the given commands as arguments.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/toolchain.py
ToolchainCL.build_status
def build_status(self, _args): """Print the status of the specified build. """ print('{Style.BRIGHT}Bootstraps whose core components are probably ' 'already built:{Style.RESET_ALL}'.format(Style=Out_Style)) bootstrap_dir = join(self.ctx.build_dir, 'bootstrap_builds') if ex...
python
def build_status(self, _args): """Print the status of the specified build. """ print('{Style.BRIGHT}Bootstraps whose core components are probably ' 'already built:{Style.RESET_ALL}'.format(Style=Out_Style)) bootstrap_dir = join(self.ctx.build_dir, 'bootstrap_builds') if ex...
[ "def", "build_status", "(", "self", ",", "_args", ")", ":", "print", "(", "'{Style.BRIGHT}Bootstraps whose core components are probably '", "'already built:{Style.RESET_ALL}'", ".", "format", "(", "Style", "=", "Out_Style", ")", ")", "bootstrap_dir", "=", "join", "(", ...
Print the status of the specified build.
[ "Print", "the", "status", "of", "the", "specified", "build", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/toolchain.py#L1146-L1172
train
Print the status of the specified build.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipes/ifaddrs/__init__.py
IFAddrRecipe.prebuild_arch
def prebuild_arch(self, arch): """Make the build and target directories""" path = self.get_build_dir(arch.arch) if not exists(path): info("creating {}".format(path)) shprint(sh.mkdir, '-p', path)
python
def prebuild_arch(self, arch): """Make the build and target directories""" path = self.get_build_dir(arch.arch) if not exists(path): info("creating {}".format(path)) shprint(sh.mkdir, '-p', path)
[ "def", "prebuild_arch", "(", "self", ",", "arch", ")", ":", "path", "=", "self", ".", "get_build_dir", "(", "arch", ".", "arch", ")", "if", "not", "exists", "(", "path", ")", ":", "info", "(", "\"creating {}\"", ".", "format", "(", "path", ")", ")", ...
Make the build and target directories
[ "Make", "the", "build", "and", "target", "directories" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/ifaddrs/__init__.py#L19-L24
train
Make the build and target directories for the current arch.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipes/ifaddrs/__init__.py
IFAddrRecipe.build_arch
def build_arch(self, arch): """simple shared compile""" env = self.get_recipe_env(arch, with_flags_in_cc=False) for path in ( self.get_build_dir(arch.arch), join(self.ctx.python_recipe.get_build_dir(arch.arch), 'Lib'), join(self.ctx.python_recipe.g...
python
def build_arch(self, arch): """simple shared compile""" env = self.get_recipe_env(arch, with_flags_in_cc=False) for path in ( self.get_build_dir(arch.arch), join(self.ctx.python_recipe.get_build_dir(arch.arch), 'Lib'), join(self.ctx.python_recipe.g...
[ "def", "build_arch", "(", "self", ",", "arch", ")", ":", "env", "=", "self", ".", "get_recipe_env", "(", "arch", ",", "with_flags_in_cc", "=", "False", ")", "for", "path", "in", "(", "self", ".", "get_build_dir", "(", "arch", ".", "arch", ")", ",", "...
simple shared compile
[ "simple", "shared", "compile" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/ifaddrs/__init__.py#L26-L51
train
simple shared compile
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/runtime.py
Context.resolve
def resolve(self, key): """Looks up a variable like `__getitem__` or `get` but returns an :class:`Undefined` object with the name of the name looked up. """ if key in self.vars: return self.vars[key] if key in self.parent: return self.parent[key] r...
python
def resolve(self, key): """Looks up a variable like `__getitem__` or `get` but returns an :class:`Undefined` object with the name of the name looked up. """ if key in self.vars: return self.vars[key] if key in self.parent: return self.parent[key] r...
[ "def", "resolve", "(", "self", ",", "key", ")", ":", "if", "key", "in", "self", ".", "vars", ":", "return", "self", ".", "vars", "[", "key", "]", "if", "key", "in", "self", ".", "parent", ":", "return", "self", ".", "parent", "[", "key", "]", "...
Looks up a variable like `__getitem__` or `get` but returns an :class:`Undefined` object with the name of the name looked up.
[ "Looks", "up", "a", "variable", "like", "__getitem__", "or", "get", "but", "returns", "an", ":", "class", ":", "Undefined", "object", "with", "the", "name", "of", "the", "name", "looked", "up", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/runtime.py#L148-L156
train
Looks up a variable like __getitem__ or get but returns an analyse. Analyse the environment variable with the name of the key.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/runtime.py
Context.call
def call(__self, __obj, *args, **kwargs): """Call the callable with the arguments and keyword arguments provided but inject the active context or environment as first argument if the callable is a :func:`contextfunction` or :func:`environmentfunction`. """ if __debug__: ...
python
def call(__self, __obj, *args, **kwargs): """Call the callable with the arguments and keyword arguments provided but inject the active context or environment as first argument if the callable is a :func:`contextfunction` or :func:`environmentfunction`. """ if __debug__: ...
[ "def", "call", "(", "__self", ",", "__obj", ",", "*", "args", ",", "*", "*", "kwargs", ")", ":", "if", "__debug__", ":", "__traceback_hide__", "=", "True", "if", "isinstance", "(", "__obj", ",", "_context_function_types", ")", ":", "if", "getattr", "(", ...
Call the callable with the arguments and keyword arguments provided but inject the active context or environment as first argument if the callable is a :func:`contextfunction` or :func:`environmentfunction`.
[ "Call", "the", "callable", "with", "the", "arguments", "and", "keyword", "arguments", "provided", "but", "inject", "the", "active", "context", "or", "environment", "as", "first", "argument", "if", "the", "callable", "is", "a", ":", "func", ":", "contextfunctio...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/runtime.py#L169-L184
train
Call the callable with the arguments and keyword arguments provided but inject the active context or environment as first argument if the callable is a contextfunction or environmentfunction.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/runtime.py
Undefined._fail_with_undefined_error
def _fail_with_undefined_error(self, *args, **kwargs): """Regular callback function for undefined objects that raises an `UndefinedError` on call. """ if self._undefined_hint is None: if self._undefined_obj is missing: hint = '%r is undefined' % self._undefine...
python
def _fail_with_undefined_error(self, *args, **kwargs): """Regular callback function for undefined objects that raises an `UndefinedError` on call. """ if self._undefined_hint is None: if self._undefined_obj is missing: hint = '%r is undefined' % self._undefine...
[ "def", "_fail_with_undefined_error", "(", "self", ",", "*", "args", ",", "*", "*", "kwargs", ")", ":", "if", "self", ".", "_undefined_hint", "is", "None", ":", "if", "self", ".", "_undefined_obj", "is", "missing", ":", "hint", "=", "'%r is undefined'", "%"...
Regular callback function for undefined objects that raises an `UndefinedError` on call.
[ "Regular", "callback", "function", "for", "undefined", "objects", "that", "raises", "an", "UndefinedError", "on", "call", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/runtime.py#L433-L452
train
Regular callback function for undefined objects that raises an UndefinedError on call.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/graph.py
fix_deplist
def fix_deplist(deps): """ Turn a dependency list into lowercase, and make sure all entries that are just a string become a tuple of strings """ deps = [ ((dep.lower(),) if not isinstance(dep, (list, tuple)) else tuple([dep_entry.lower() for dep_entry i...
python
def fix_deplist(deps): """ Turn a dependency list into lowercase, and make sure all entries that are just a string become a tuple of strings """ deps = [ ((dep.lower(),) if not isinstance(dep, (list, tuple)) else tuple([dep_entry.lower() for dep_entry i...
[ "def", "fix_deplist", "(", "deps", ")", ":", "deps", "=", "[", "(", "(", "dep", ".", "lower", "(", ")", ",", ")", "if", "not", "isinstance", "(", "dep", ",", "(", "list", ",", "tuple", ")", ")", "else", "tuple", "(", "[", "dep_entry", ".", "low...
Turn a dependency list into lowercase, and make sure all entries that are just a string become a tuple of strings
[ "Turn", "a", "dependency", "list", "into", "lowercase", "and", "make", "sure", "all", "entries", "that", "are", "just", "a", "string", "become", "a", "tuple", "of", "strings" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/graph.py#L10-L22
train
Turn a dependency list into lowercase and make sure all entries that are just a string become a tuple of strings
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/graph.py
get_dependency_tuple_list_for_recipe
def get_dependency_tuple_list_for_recipe(recipe, blacklist=None): """ Get the dependencies of a recipe with filtered out blacklist, and turned into tuples with fix_deplist() """ if blacklist is None: blacklist = set() assert(type(blacklist) == set) if recipe.depends is None: ...
python
def get_dependency_tuple_list_for_recipe(recipe, blacklist=None): """ Get the dependencies of a recipe with filtered out blacklist, and turned into tuples with fix_deplist() """ if blacklist is None: blacklist = set() assert(type(blacklist) == set) if recipe.depends is None: ...
[ "def", "get_dependency_tuple_list_for_recipe", "(", "recipe", ",", "blacklist", "=", "None", ")", ":", "if", "blacklist", "is", "None", ":", "blacklist", "=", "set", "(", ")", "assert", "(", "type", "(", "blacklist", ")", "==", "set", ")", "if", "recipe", ...
Get the dependencies of a recipe with filtered out blacklist, and turned into tuples with fix_deplist()
[ "Get", "the", "dependencies", "of", "a", "recipe", "with", "filtered", "out", "blacklist", "and", "turned", "into", "tuples", "with", "fix_deplist", "()" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/graph.py#L42-L61
train
Returns the list of tuples that are used to work with a given recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/graph.py
recursively_collect_orders
def recursively_collect_orders( name, ctx, all_inputs, orders=None, blacklist=None ): '''For each possible recipe ordering, try to add the new recipe name to that order. Recursively do the same thing with all the dependencies of each recipe. ''' name = name.lower() if orders is ...
python
def recursively_collect_orders( name, ctx, all_inputs, orders=None, blacklist=None ): '''For each possible recipe ordering, try to add the new recipe name to that order. Recursively do the same thing with all the dependencies of each recipe. ''' name = name.lower() if orders is ...
[ "def", "recursively_collect_orders", "(", "name", ",", "ctx", ",", "all_inputs", ",", "orders", "=", "None", ",", "blacklist", "=", "None", ")", ":", "name", "=", "name", ".", "lower", "(", ")", "if", "orders", "is", "None", ":", "orders", "=", "[", ...
For each possible recipe ordering, try to add the new recipe name to that order. Recursively do the same thing with all the dependencies of each recipe.
[ "For", "each", "possible", "recipe", "ordering", "try", "to", "add", "the", "new", "recipe", "name", "to", "that", "order", ".", "Recursively", "do", "the", "same", "thing", "with", "all", "the", "dependencies", "of", "each", "recipe", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/graph.py#L64-L124
train
Recursively collect all the possible recipe names and dependencies of a single recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/graph.py
find_order
def find_order(graph): ''' Do a topological sort on the dependency graph dict. ''' while graph: # Find all items without a parent leftmost = [l for l, s in graph.items() if not s] if not leftmost: raise ValueError('Dependency cycle detected! %s' % graph) # If ...
python
def find_order(graph): ''' Do a topological sort on the dependency graph dict. ''' while graph: # Find all items without a parent leftmost = [l for l, s in graph.items() if not s] if not leftmost: raise ValueError('Dependency cycle detected! %s' % graph) # If ...
[ "def", "find_order", "(", "graph", ")", ":", "while", "graph", ":", "# Find all items without a parent", "leftmost", "=", "[", "l", "for", "l", ",", "s", "in", "graph", ".", "items", "(", ")", "if", "not", "s", "]", "if", "not", "leftmost", ":", "raise...
Do a topological sort on the dependency graph dict.
[ "Do", "a", "topological", "sort", "on", "the", "dependency", "graph", "dict", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/graph.py#L127-L143
train
Find the topological order of the items in the dependency graph.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/graph.py
obvious_conflict_checker
def obvious_conflict_checker(ctx, name_tuples, blacklist=None): """ This is a pre-flight check function that will completely ignore recipe order or choosing an actual value in any of the multiple choice tuples/dependencies, and just do a very basic obvious conflict check. """ deps_we...
python
def obvious_conflict_checker(ctx, name_tuples, blacklist=None): """ This is a pre-flight check function that will completely ignore recipe order or choosing an actual value in any of the multiple choice tuples/dependencies, and just do a very basic obvious conflict check. """ deps_we...
[ "def", "obvious_conflict_checker", "(", "ctx", ",", "name_tuples", ",", "blacklist", "=", "None", ")", ":", "deps_were_added_by", "=", "dict", "(", ")", "deps", "=", "set", "(", ")", "if", "blacklist", "is", "None", ":", "blacklist", "=", "set", "(", ")"...
This is a pre-flight check function that will completely ignore recipe order or choosing an actual value in any of the multiple choice tuples/dependencies, and just do a very basic obvious conflict check.
[ "This", "is", "a", "pre", "-", "flight", "check", "function", "that", "will", "completely", "ignore", "recipe", "order", "or", "choosing", "an", "actual", "value", "in", "any", "of", "the", "multiple", "choice", "tuples", "/", "dependencies", "and", "just", ...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/graph.py#L146-L240
train
This function is a pre - flight check function that will just ignore the recipe order and just check if any of the dependencies that conflict with the current one.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipes/openssl/__init__.py
OpenSSLRecipe.include_flags
def include_flags(self, arch): '''Returns a string with the include folders''' openssl_includes = join(self.get_build_dir(arch.arch), 'include') return (' -I' + openssl_includes + ' -I' + join(openssl_includes, 'internal') + ' -I' + join(openssl_includes, 'openssl...
python
def include_flags(self, arch): '''Returns a string with the include folders''' openssl_includes = join(self.get_build_dir(arch.arch), 'include') return (' -I' + openssl_includes + ' -I' + join(openssl_includes, 'internal') + ' -I' + join(openssl_includes, 'openssl...
[ "def", "include_flags", "(", "self", ",", "arch", ")", ":", "openssl_includes", "=", "join", "(", "self", ".", "get_build_dir", "(", "arch", ".", "arch", ")", ",", "'include'", ")", "return", "(", "' -I'", "+", "openssl_includes", "+", "' -I'", "+", "joi...
Returns a string with the include folders
[ "Returns", "a", "string", "with", "the", "include", "folders" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/openssl/__init__.py#L88-L93
train
Returns a string with the include folders
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/python.py
GuestPythonRecipe.set_libs_flags
def set_libs_flags(self, env, arch): '''Takes care to properly link libraries with python depending on our requirements and the attribute :attr:`opt_depends`. ''' def add_flags(include_flags, link_dirs, link_libs): env['CPPFLAGS'] = env.get('CPPFLAGS', '') + include_flags ...
python
def set_libs_flags(self, env, arch): '''Takes care to properly link libraries with python depending on our requirements and the attribute :attr:`opt_depends`. ''' def add_flags(include_flags, link_dirs, link_libs): env['CPPFLAGS'] = env.get('CPPFLAGS', '') + include_flags ...
[ "def", "set_libs_flags", "(", "self", ",", "env", ",", "arch", ")", ":", "def", "add_flags", "(", "include_flags", ",", "link_dirs", ",", "link_libs", ")", ":", "env", "[", "'CPPFLAGS'", "]", "=", "env", ".", "get", "(", "'CPPFLAGS'", ",", "''", ")", ...
Takes care to properly link libraries with python depending on our requirements and the attribute :attr:`opt_depends`.
[ "Takes", "care", "to", "properly", "link", "libraries", "with", "python", "depending", "on", "our", "requirements", "and", "the", "attribute", ":", "attr", ":", "opt_depends", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/python.py#L183-L214
train
Takes care to properly link libraries with python depending on our requirements and the attribute opt_depends.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/python.py
GuestPythonRecipe.compile_python_files
def compile_python_files(self, dir): ''' Compile the python files (recursively) for the python files inside a given folder. .. note:: python2 compiles the files into extension .pyo, but in python3, and as of Python 3.5, the .pyo filename extension is no longer us...
python
def compile_python_files(self, dir): ''' Compile the python files (recursively) for the python files inside a given folder. .. note:: python2 compiles the files into extension .pyo, but in python3, and as of Python 3.5, the .pyo filename extension is no longer us...
[ "def", "compile_python_files", "(", "self", ",", "dir", ")", ":", "args", "=", "[", "self", ".", "ctx", ".", "hostpython", "]", "if", "self", ".", "ctx", ".", "python_recipe", ".", "name", "==", "'python3'", ":", "args", "+=", "[", "'-OO'", ",", "'-m...
Compile the python files (recursively) for the python files inside a given folder. .. note:: python2 compiles the files into extension .pyo, but in python3, and as of Python 3.5, the .pyo filename extension is no longer used...uses .pyc (https://www.python.org/dev/peps/pep-0488)
[ "Compile", "the", "python", "files", "(", "recursively", ")", "for", "the", "python", "files", "inside", "a", "given", "folder", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/python.py#L276-L290
train
Compile the python files inside a given folder.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/python.py
GuestPythonRecipe.create_python_bundle
def create_python_bundle(self, dirn, arch): """ Create a packaged python bundle in the target directory, by copying all the modules and standard library to the right place. """ # Todo: find a better way to find the build libs folder modules_build_dir = join( ...
python
def create_python_bundle(self, dirn, arch): """ Create a packaged python bundle in the target directory, by copying all the modules and standard library to the right place. """ # Todo: find a better way to find the build libs folder modules_build_dir = join( ...
[ "def", "create_python_bundle", "(", "self", ",", "dirn", ",", "arch", ")", ":", "# Todo: find a better way to find the build libs folder", "modules_build_dir", "=", "join", "(", "self", ".", "get_build_dir", "(", "arch", ".", "arch", ")", ",", "'android-build'", ","...
Create a packaged python bundle in the target directory, by copying all the modules and standard library to the right place.
[ "Create", "a", "packaged", "python", "bundle", "in", "the", "target", "directory", "by", "copying", "all", "the", "modules", "and", "standard", "library", "to", "the", "right", "place", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/python.py#L292-L361
train
Create a packaged python bundle in the target directory by copying all the modules and standard library into the right python bundle.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipes/scrypt/__init__.py
ScryptRecipe.get_recipe_env
def get_recipe_env(self, arch, with_flags_in_cc=True): """ Adds openssl recipe to include and library path. """ env = super(ScryptRecipe, self).get_recipe_env(arch, with_flags_in_cc) openssl_recipe = self.get_recipe('openssl', self.ctx) env['CFLAGS'] += openssl_recipe.inc...
python
def get_recipe_env(self, arch, with_flags_in_cc=True): """ Adds openssl recipe to include and library path. """ env = super(ScryptRecipe, self).get_recipe_env(arch, with_flags_in_cc) openssl_recipe = self.get_recipe('openssl', self.ctx) env['CFLAGS'] += openssl_recipe.inc...
[ "def", "get_recipe_env", "(", "self", ",", "arch", ",", "with_flags_in_cc", "=", "True", ")", ":", "env", "=", "super", "(", "ScryptRecipe", ",", "self", ")", ".", "get_recipe_env", "(", "arch", ",", "with_flags_in_cc", ")", "openssl_recipe", "=", "self", ...
Adds openssl recipe to include and library path.
[ "Adds", "openssl", "recipe", "to", "include", "and", "library", "path", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/scrypt/__init__.py#L12-L23
train
Adds openssl recipe to include and library path.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/util.py
walk_valid_filens
def walk_valid_filens(base_dir, invalid_dir_names, invalid_file_patterns): """Recursively walks all the files and directories in ``dirn``, ignoring directories that match any pattern in ``invalid_dirns`` and files that patch any pattern in ``invalid_filens``. ``invalid_dirns`` and ``invalid_filens`` sh...
python
def walk_valid_filens(base_dir, invalid_dir_names, invalid_file_patterns): """Recursively walks all the files and directories in ``dirn``, ignoring directories that match any pattern in ``invalid_dirns`` and files that patch any pattern in ``invalid_filens``. ``invalid_dirns`` and ``invalid_filens`` sh...
[ "def", "walk_valid_filens", "(", "base_dir", ",", "invalid_dir_names", ",", "invalid_file_patterns", ")", ":", "for", "dirn", ",", "subdirs", ",", "filens", "in", "walk", "(", "base_dir", ")", ":", "# Remove invalid subdirs so that they will not be walked", "for", "i"...
Recursively walks all the files and directories in ``dirn``, ignoring directories that match any pattern in ``invalid_dirns`` and files that patch any pattern in ``invalid_filens``. ``invalid_dirns`` and ``invalid_filens`` should both be lists of strings to match. ``invalid_dir_patterns`` expects a lis...
[ "Recursively", "walks", "all", "the", "files", "and", "directories", "in", "dirn", "ignoring", "directories", "that", "match", "any", "pattern", "in", "invalid_dirns", "and", "files", "that", "patch", "any", "pattern", "in", "invalid_filens", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/util.py#L149-L176
train
Recursively walks all the files and directories in dirn ignoring any pattern in invalid_dir_names and invalid_file_patterns.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/util.py
handle_build_exception
def handle_build_exception(exception): """ Handles a raised BuildInterruptingException by printing its error message and associated instructions, if any, then exiting. """ error('Build failed: {}'.format(exception.message)) if exception.instructions is not None: info('Instructions: {}'.f...
python
def handle_build_exception(exception): """ Handles a raised BuildInterruptingException by printing its error message and associated instructions, if any, then exiting. """ error('Build failed: {}'.format(exception.message)) if exception.instructions is not None: info('Instructions: {}'.f...
[ "def", "handle_build_exception", "(", "exception", ")", ":", "error", "(", "'Build failed: {}'", ".", "format", "(", "exception", ".", "message", ")", ")", "if", "exception", ".", "instructions", "is", "not", "None", ":", "info", "(", "'Instructions: {}'", "."...
Handles a raised BuildInterruptingException by printing its error message and associated instructions, if any, then exiting.
[ "Handles", "a", "raised", "BuildInterruptingException", "by", "printing", "its", "error", "message", "and", "associated", "instructions", "if", "any", "then", "exiting", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/util.py#L186-L194
train
Handles a BuildInterruptingException by printing its error message and associated instructions.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/common/build/build.py
render
def render(template, dest, **kwargs): '''Using jinja2, render `template` to the filename `dest`, supplying the keyword arguments as template parameters. ''' dest_dir = dirname(dest) if dest_dir and not exists(dest_dir): makedirs(dest_dir) template = environment.get_template(template) ...
python
def render(template, dest, **kwargs): '''Using jinja2, render `template` to the filename `dest`, supplying the keyword arguments as template parameters. ''' dest_dir = dirname(dest) if dest_dir and not exists(dest_dir): makedirs(dest_dir) template = environment.get_template(template) ...
[ "def", "render", "(", "template", ",", "dest", ",", "*", "*", "kwargs", ")", ":", "dest_dir", "=", "dirname", "(", "dest", ")", "if", "dest_dir", "and", "not", "exists", "(", "dest_dir", ")", ":", "makedirs", "(", "dest_dir", ")", "template", "=", "e...
Using jinja2, render `template` to the filename `dest`, supplying the keyword arguments as template parameters.
[ "Using", "jinja2", "render", "template", "to", "the", "filename", "dest", "supplying", "the" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/common/build/build.py#L107-L122
train
Using jinja2 render template to the filename dest supplying the keyword arguments as template parameters.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/common/build/build.py
make_python_zip
def make_python_zip(): ''' Search for all the python related files, and construct the pythonXX.zip According to # http://randomsplat.com/id5-cross-compiling-python-for-embedded-linux.html site-packages, config and lib-dynload will be not included. ''' if not exists('private'): print...
python
def make_python_zip(): ''' Search for all the python related files, and construct the pythonXX.zip According to # http://randomsplat.com/id5-cross-compiling-python-for-embedded-linux.html site-packages, config and lib-dynload will be not included. ''' if not exists('private'): print...
[ "def", "make_python_zip", "(", ")", ":", "if", "not", "exists", "(", "'private'", ")", ":", "print", "(", "'No compiled python is present to zip, skipping.'", ")", "return", "global", "python_files", "d", "=", "realpath", "(", "join", "(", "'private'", ",", "'li...
Search for all the python related files, and construct the pythonXX.zip According to # http://randomsplat.com/id5-cross-compiling-python-for-embedded-linux.html site-packages, config and lib-dynload will be not included.
[ "Search", "for", "all", "the", "python", "related", "files", "and", "construct", "the", "pythonXX", ".", "zip", "According", "to", "#", "http", ":", "//", "randomsplat", ".", "com", "/", "id5", "-", "cross", "-", "compiling", "-", "python", "-", "for", ...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/common/build/build.py#L159-L198
train
Create a zip file containing all the python related files.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/common/build/build.py
make_tar
def make_tar(tfn, source_dirs, ignore_path=[], optimize_python=True): ''' Make a zip file `fn` from the contents of source_dis. ''' # selector function def select(fn): rfn = realpath(fn) for p in ignore_path: if p.endswith('/'): p = p[:-1] if ...
python
def make_tar(tfn, source_dirs, ignore_path=[], optimize_python=True): ''' Make a zip file `fn` from the contents of source_dis. ''' # selector function def select(fn): rfn = realpath(fn) for p in ignore_path: if p.endswith('/'): p = p[:-1] if ...
[ "def", "make_tar", "(", "tfn", ",", "source_dirs", ",", "ignore_path", "=", "[", "]", ",", "optimize_python", "=", "True", ")", ":", "# selector function", "def", "select", "(", "fn", ")", ":", "rfn", "=", "realpath", "(", "fn", ")", "for", "p", "in", ...
Make a zip file `fn` from the contents of source_dis.
[ "Make", "a", "zip", "file", "fn", "from", "the", "contents", "of", "source_dis", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/common/build/build.py#L201-L247
train
Make a tar. gz file from the contents of source_dis.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/common/build/build.py
compile_dir
def compile_dir(dfn, optimize_python=True): ''' Compile *.py in directory `dfn` to *.pyo ''' if PYTHON is None: return if int(PYTHON_VERSION[0]) >= 3: args = [PYTHON, '-m', 'compileall', '-b', '-f', dfn] else: args = [PYTHON, '-m', 'compileall', '-f', dfn] if optimi...
python
def compile_dir(dfn, optimize_python=True): ''' Compile *.py in directory `dfn` to *.pyo ''' if PYTHON is None: return if int(PYTHON_VERSION[0]) >= 3: args = [PYTHON, '-m', 'compileall', '-b', '-f', dfn] else: args = [PYTHON, '-m', 'compileall', '-f', dfn] if optimi...
[ "def", "compile_dir", "(", "dfn", ",", "optimize_python", "=", "True", ")", ":", "if", "PYTHON", "is", "None", ":", "return", "if", "int", "(", "PYTHON_VERSION", "[", "0", "]", ")", ">=", "3", ":", "args", "=", "[", "PYTHON", ",", "'-m'", ",", "'co...
Compile *.py in directory `dfn` to *.pyo
[ "Compile", "*", ".", "py", "in", "directory", "dfn", "to", "*", ".", "pyo" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/common/build/build.py#L250-L271
train
Compile all. py in directory dfn to all. pyo.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipes/hostpython3crystax/__init__.py
Hostpython3CrystaXRecipe.build_arch
def build_arch(self, arch): """ Creates expected build and symlinks system Python version. """ self.ctx.hostpython = '/usr/bin/false' # creates the sub buildir (used by other recipes) # https://github.com/kivy/python-for-android/issues/1154 sub_build_dir = join(se...
python
def build_arch(self, arch): """ Creates expected build and symlinks system Python version. """ self.ctx.hostpython = '/usr/bin/false' # creates the sub buildir (used by other recipes) # https://github.com/kivy/python-for-android/issues/1154 sub_build_dir = join(se...
[ "def", "build_arch", "(", "self", ",", "arch", ")", ":", "self", ".", "ctx", ".", "hostpython", "=", "'/usr/bin/false'", "# creates the sub buildir (used by other recipes)", "# https://github.com/kivy/python-for-android/issues/1154", "sub_build_dir", "=", "join", "(", "self...
Creates expected build and symlinks system Python version.
[ "Creates", "expected", "build", "and", "symlinks", "system", "Python", "version", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/hostpython3crystax/__init__.py#L25-L41
train
Creates expected build and symlinks system Python version.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/build.py
render
def render(template, dest, **kwargs): '''Using jinja2, render `template` to the filename `dest`, supplying the keyword arguments as template parameters. ''' template = environment.get_template(template) text = template.render(**kwargs) f = open(dest, 'wb') f.write(text.encode('utf-8')) ...
python
def render(template, dest, **kwargs): '''Using jinja2, render `template` to the filename `dest`, supplying the keyword arguments as template parameters. ''' template = environment.get_template(template) text = template.render(**kwargs) f = open(dest, 'wb') f.write(text.encode('utf-8')) ...
[ "def", "render", "(", "template", ",", "dest", ",", "*", "*", "kwargs", ")", ":", "template", "=", "environment", ".", "get_template", "(", "template", ")", "text", "=", "template", ".", "render", "(", "*", "*", "kwargs", ")", "f", "=", "open", "(", ...
Using jinja2, render `template` to the filename `dest`, supplying the keyword arguments as template parameters.
[ "Using", "jinja2", "render", "template", "to", "the", "filename", "dest", "supplying", "the" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/build.py#L62-L73
train
Using jinja2 render template to the filename dest supplying the keyword arguments as template parameters.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
md5sum
def md5sum(filen): '''Calculate the md5sum of a file. ''' with open(filen, 'rb') as fileh: md5 = hashlib.md5(fileh.read()) return md5.hexdigest()
python
def md5sum(filen): '''Calculate the md5sum of a file. ''' with open(filen, 'rb') as fileh: md5 = hashlib.md5(fileh.read()) return md5.hexdigest()
[ "def", "md5sum", "(", "filen", ")", ":", "with", "open", "(", "filen", ",", "'rb'", ")", "as", "fileh", ":", "md5", "=", "hashlib", ".", "md5", "(", "fileh", ".", "read", "(", ")", ")", "return", "md5", ".", "hexdigest", "(", ")" ]
Calculate the md5sum of a file.
[ "Calculate", "the", "md5sum", "of", "a", "file", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L1167-L1173
train
Calculate the md5sum of a file.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.versioned_url
def versioned_url(self): '''A property returning the url of the recipe with ``{version}`` replaced by the :attr:`url`. If accessing the url, you should use this property, *not* access the url directly.''' if self.url is None: return None return self.url.format(version...
python
def versioned_url(self): '''A property returning the url of the recipe with ``{version}`` replaced by the :attr:`url`. If accessing the url, you should use this property, *not* access the url directly.''' if self.url is None: return None return self.url.format(version...
[ "def", "versioned_url", "(", "self", ")", ":", "if", "self", ".", "url", "is", "None", ":", "return", "None", "return", "self", ".", "url", ".", "format", "(", "version", "=", "self", ".", "version", ")" ]
A property returning the url of the recipe with ``{version}`` replaced by the :attr:`url`. If accessing the url, you should use this property, *not* access the url directly.
[ "A", "property", "returning", "the", "url", "of", "the", "recipe", "with", "{", "version", "}", "replaced", "by", "the", ":", "attr", ":", "url", ".", "If", "accessing", "the", "url", "you", "should", "use", "this", "property", "*", "not", "*", "access...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L120-L126
train
A property returning the url of the recipe with the version replaced by the url.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.download_file
def download_file(self, url, target, cwd=None): """ (internal) Download an ``url`` to a ``target``. """ if not url: return info('Downloading {} from {}'.format(self.name, url)) if cwd: target = join(cwd, target) parsed_url = urlparse(url)...
python
def download_file(self, url, target, cwd=None): """ (internal) Download an ``url`` to a ``target``. """ if not url: return info('Downloading {} from {}'.format(self.name, url)) if cwd: target = join(cwd, target) parsed_url = urlparse(url)...
[ "def", "download_file", "(", "self", ",", "url", ",", "target", ",", "cwd", "=", "None", ")", ":", "if", "not", "url", ":", "return", "info", "(", "'Downloading {} from {}'", ".", "format", "(", "self", ".", "name", ",", "url", ")", ")", "if", "cwd",...
(internal) Download an ``url`` to a ``target``.
[ "(", "internal", ")", "Download", "an", "url", "to", "a", "target", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L128-L185
train
Download an url to a target.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.apply_patch
def apply_patch(self, filename, arch, build_dir=None): """ Apply a patch from the current recipe directory into the current build directory. .. versionchanged:: 0.6.0 Add ability to apply patch from any dir via kwarg `build_dir`''' """ info("Applying patch {}...
python
def apply_patch(self, filename, arch, build_dir=None): """ Apply a patch from the current recipe directory into the current build directory. .. versionchanged:: 0.6.0 Add ability to apply patch from any dir via kwarg `build_dir`''' """ info("Applying patch {}...
[ "def", "apply_patch", "(", "self", ",", "filename", ",", "arch", ",", "build_dir", "=", "None", ")", ":", "info", "(", "\"Applying patch {}\"", ".", "format", "(", "filename", ")", ")", "build_dir", "=", "build_dir", "if", "build_dir", "else", "self", ".",...
Apply a patch from the current recipe directory into the current build directory. .. versionchanged:: 0.6.0 Add ability to apply patch from any dir via kwarg `build_dir`'''
[ "Apply", "a", "patch", "from", "the", "current", "recipe", "directory", "into", "the", "current", "build", "directory", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L187-L199
train
Apply a patch from the current recipe directory into the current currentCOOKIE build directory.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.filtered_archs
def filtered_archs(self): '''Return archs of self.ctx that are valid build archs for the Recipe.''' result = [] for arch in self.ctx.archs: if not self.archs or (arch.arch in self.archs): result.append(arch) return result
python
def filtered_archs(self): '''Return archs of self.ctx that are valid build archs for the Recipe.''' result = [] for arch in self.ctx.archs: if not self.archs or (arch.arch in self.archs): result.append(arch) return result
[ "def", "filtered_archs", "(", "self", ")", ":", "result", "=", "[", "]", "for", "arch", "in", "self", ".", "ctx", ".", "archs", ":", "if", "not", "self", ".", "archs", "or", "(", "arch", ".", "arch", "in", "self", ".", "archs", ")", ":", "result"...
Return archs of self.ctx that are valid build archs for the Recipe.
[ "Return", "archs", "of", "self", ".", "ctx", "that", "are", "valid", "build", "archs", "for", "the", "Recipe", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L223-L230
train
Return archs of self. ctx that are valid build archs for the Recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.check_recipe_choices
def check_recipe_choices(self): '''Checks what recipes are being built to see which of the alternative and optional dependencies are being used, and returns a list of these.''' recipes = [] built_recipes = self.ctx.recipe_build_order for recipe in self.depends: ...
python
def check_recipe_choices(self): '''Checks what recipes are being built to see which of the alternative and optional dependencies are being used, and returns a list of these.''' recipes = [] built_recipes = self.ctx.recipe_build_order for recipe in self.depends: ...
[ "def", "check_recipe_choices", "(", "self", ")", ":", "recipes", "=", "[", "]", "built_recipes", "=", "self", ".", "ctx", ".", "recipe_build_order", "for", "recipe", "in", "self", ".", "depends", ":", "if", "isinstance", "(", "recipe", ",", "(", "tuple", ...
Checks what recipes are being built to see which of the alternative and optional dependencies are being used, and returns a list of these.
[ "Checks", "what", "recipes", "are", "being", "built", "to", "see", "which", "of", "the", "alternative", "and", "optional", "dependencies", "are", "being", "used", "and", "returns", "a", "list", "of", "these", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L232-L247
train
Checks what recipes are being built to see which of the alternative and optional dependencies are being used and returns a list of these.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.get_build_container_dir
def get_build_container_dir(self, arch): '''Given the arch name, returns the directory where it will be built. This returns a different directory depending on what alternative or optional dependencies are being built. ''' dir_name = self.get_dir_name() return joi...
python
def get_build_container_dir(self, arch): '''Given the arch name, returns the directory where it will be built. This returns a different directory depending on what alternative or optional dependencies are being built. ''' dir_name = self.get_dir_name() return joi...
[ "def", "get_build_container_dir", "(", "self", ",", "arch", ")", ":", "dir_name", "=", "self", ".", "get_dir_name", "(", ")", "return", "join", "(", "self", ".", "ctx", ".", "build_dir", ",", "'other_builds'", ",", "dir_name", ",", "'{}__ndk_target_{}'", "."...
Given the arch name, returns the directory where it will be built. This returns a different directory depending on what alternative or optional dependencies are being built.
[ "Given", "the", "arch", "name", "returns", "the", "directory", "where", "it", "will", "be", "built", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L255-L264
train
Given the arch name returns the directory where it will be built.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.get_recipe_dir
def get_recipe_dir(self): """ Returns the local recipe directory or defaults to the core recipe directory. """ if self.ctx.local_recipes is not None: local_recipe_dir = join(self.ctx.local_recipes, self.name) if exists(local_recipe_dir): re...
python
def get_recipe_dir(self): """ Returns the local recipe directory or defaults to the core recipe directory. """ if self.ctx.local_recipes is not None: local_recipe_dir = join(self.ctx.local_recipes, self.name) if exists(local_recipe_dir): re...
[ "def", "get_recipe_dir", "(", "self", ")", ":", "if", "self", ".", "ctx", ".", "local_recipes", "is", "not", "None", ":", "local_recipe_dir", "=", "join", "(", "self", ".", "ctx", ".", "local_recipes", ",", "self", ".", "name", ")", "if", "exists", "("...
Returns the local recipe directory or defaults to the core recipe directory.
[ "Returns", "the", "local", "recipe", "directory", "or", "defaults", "to", "the", "core", "recipe", "directory", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L277-L286
train
Returns the local recipe directory or defaults to the core recipe directory.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.get_recipe_env
def get_recipe_env(self, arch=None, with_flags_in_cc=True, clang=False): """Return the env specialized for the recipe """ if arch is None: arch = self.filtered_archs[0] return arch.get_env(with_flags_in_cc=with_flags_in_cc, clang=clang)
python
def get_recipe_env(self, arch=None, with_flags_in_cc=True, clang=False): """Return the env specialized for the recipe """ if arch is None: arch = self.filtered_archs[0] return arch.get_env(with_flags_in_cc=with_flags_in_cc, clang=clang)
[ "def", "get_recipe_env", "(", "self", ",", "arch", "=", "None", ",", "with_flags_in_cc", "=", "True", ",", "clang", "=", "False", ")", ":", "if", "arch", "is", "None", ":", "arch", "=", "self", ".", "filtered_archs", "[", "0", "]", "return", "arch", ...
Return the env specialized for the recipe
[ "Return", "the", "env", "specialized", "for", "the", "recipe" ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L433-L438
train
Return the env specialized for the recipe
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.apply_patches
def apply_patches(self, arch, build_dir=None): '''Apply any patches for the Recipe. .. versionchanged:: 0.6.0 Add ability to apply patches from any dir via kwarg `build_dir`''' if self.patches: info_main('Applying patches for {}[{}]' .format(self.na...
python
def apply_patches(self, arch, build_dir=None): '''Apply any patches for the Recipe. .. versionchanged:: 0.6.0 Add ability to apply patches from any dir via kwarg `build_dir`''' if self.patches: info_main('Applying patches for {}[{}]' .format(self.na...
[ "def", "apply_patches", "(", "self", ",", "arch", ",", "build_dir", "=", "None", ")", ":", "if", "self", ".", "patches", ":", "info_main", "(", "'Applying patches for {}[{}]'", ".", "format", "(", "self", ".", "name", ",", "arch", ".", "arch", ")", ")", ...
Apply any patches for the Recipe. .. versionchanged:: 0.6.0 Add ability to apply patches from any dir via kwarg `build_dir`
[ "Apply", "any", "patches", "for", "the", "Recipe", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L454-L478
train
Apply any patches for the Recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.clean_build
def clean_build(self, arch=None): '''Deletes all the build information of the recipe. If arch is not None, only this arch dir is deleted. Otherwise (the default) all builds for all archs are deleted. By default, this just deletes the main build dir. If the recipe has e.g. objec...
python
def clean_build(self, arch=None): '''Deletes all the build information of the recipe. If arch is not None, only this arch dir is deleted. Otherwise (the default) all builds for all archs are deleted. By default, this just deletes the main build dir. If the recipe has e.g. objec...
[ "def", "clean_build", "(", "self", ",", "arch", "=", "None", ")", ":", "if", "arch", "is", "None", ":", "base_dir", "=", "join", "(", "self", ".", "ctx", ".", "build_dir", ",", "'other_builds'", ",", "self", ".", "name", ")", "else", ":", "base_dir",...
Deletes all the build information of the recipe. If arch is not None, only this arch dir is deleted. Otherwise (the default) all builds for all archs are deleted. By default, this just deletes the main build dir. If the recipe has e.g. object files biglinked, or .so files stored ...
[ "Deletes", "all", "the", "build", "information", "of", "the", "recipe", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L512-L544
train
Deletes all the build information of the recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
Recipe.get_recipe
def get_recipe(cls, name, ctx): '''Returns the Recipe with the given name, if it exists.''' name = name.lower() if not hasattr(cls, "recipes"): cls.recipes = {} if name in cls.recipes: return cls.recipes[name] recipe_file = None for recipes_dir in...
python
def get_recipe(cls, name, ctx): '''Returns the Recipe with the given name, if it exists.''' name = name.lower() if not hasattr(cls, "recipes"): cls.recipes = {} if name in cls.recipes: return cls.recipes[name] recipe_file = None for recipes_dir in...
[ "def", "get_recipe", "(", "cls", ",", "name", ",", "ctx", ")", ":", "name", "=", "name", ".", "lower", "(", ")", "if", "not", "hasattr", "(", "cls", ",", "\"recipes\"", ")", ":", "cls", ".", "recipes", "=", "{", "}", "if", "name", "in", "cls", ...
Returns the Recipe with the given name, if it exists.
[ "Returns", "the", "Recipe", "with", "the", "given", "name", "if", "it", "exists", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L580-L612
train
Returns the Recipe with the given name if it exists.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
PythonRecipe.folder_name
def folder_name(self): '''The name of the build folders containing this recipe.''' name = self.site_packages_name if name is None: name = self.name return name
python
def folder_name(self): '''The name of the build folders containing this recipe.''' name = self.site_packages_name if name is None: name = self.name return name
[ "def", "folder_name", "(", "self", ")", ":", "name", "=", "self", ".", "site_packages_name", "if", "name", "is", "None", ":", "name", "=", "self", ".", "name", "return", "name" ]
The name of the build folders containing this recipe.
[ "The", "name", "of", "the", "build", "folders", "containing", "this", "recipe", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L769-L774
train
The name of the build folders containing this recipe.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
PythonRecipe.build_arch
def build_arch(self, arch): '''Install the Python module by calling setup.py install with the target Python dir.''' super(PythonRecipe, self).build_arch(arch) self.install_python_package(arch)
python
def build_arch(self, arch): '''Install the Python module by calling setup.py install with the target Python dir.''' super(PythonRecipe, self).build_arch(arch) self.install_python_package(arch)
[ "def", "build_arch", "(", "self", ",", "arch", ")", ":", "super", "(", "PythonRecipe", ",", "self", ")", ".", "build_arch", "(", "arch", ")", "self", ".", "install_python_package", "(", "arch", ")" ]
Install the Python module by calling setup.py install with the target Python dir.
[ "Install", "the", "Python", "module", "by", "calling", "setup", ".", "py", "install", "with", "the", "target", "Python", "dir", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L834-L838
train
Install the Python module by calling setup. py install with the target Python dir.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
PythonRecipe.install_python_package
def install_python_package(self, arch, name=None, env=None, is_dir=True): '''Automate the installation of a Python package (or a cython package where the cython components are pre-built).''' # arch = self.filtered_archs[0] # old kivy-ios way if name is None: name = self.name...
python
def install_python_package(self, arch, name=None, env=None, is_dir=True): '''Automate the installation of a Python package (or a cython package where the cython components are pre-built).''' # arch = self.filtered_archs[0] # old kivy-ios way if name is None: name = self.name...
[ "def", "install_python_package", "(", "self", ",", "arch", ",", "name", "=", "None", ",", "env", "=", "None", ",", "is_dir", "=", "True", ")", ":", "# arch = self.filtered_archs[0] # old kivy-ios way", "if", "name", "is", "None", ":", "name", "=", "self", "...
Automate the installation of a Python package (or a cython package where the cython components are pre-built).
[ "Automate", "the", "installation", "of", "a", "Python", "package", "(", "or", "a", "cython", "package", "where", "the", "cython", "components", "are", "pre", "-", "built", ")", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L840-L877
train
Automate the installation of a Python package or a Cython package where the cython components are pre - built.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
CompiledComponentsPythonRecipe.build_arch
def build_arch(self, arch): '''Build any cython components, then install the Python module by calling setup.py install with the target Python dir. ''' Recipe.build_arch(self, arch) self.build_compiled_components(arch) self.install_python_package(arch)
python
def build_arch(self, arch): '''Build any cython components, then install the Python module by calling setup.py install with the target Python dir. ''' Recipe.build_arch(self, arch) self.build_compiled_components(arch) self.install_python_package(arch)
[ "def", "build_arch", "(", "self", ",", "arch", ")", ":", "Recipe", ".", "build_arch", "(", "self", ",", "arch", ")", "self", ".", "build_compiled_components", "(", "arch", ")", "self", ".", "install_python_package", "(", "arch", ")" ]
Build any cython components, then install the Python module by calling setup.py install with the target Python dir.
[ "Build", "any", "cython", "components", "then", "install", "the", "Python", "module", "by", "calling", "setup", ".", "py", "install", "with", "the", "target", "Python", "dir", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L898-L904
train
Build any cython components then install the Python module by calling setup. py install with the target Python dir.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
CythonRecipe.build_arch
def build_arch(self, arch): '''Build any cython components, then install the Python module by calling setup.py install with the target Python dir. ''' Recipe.build_arch(self, arch) self.build_cython_components(arch) self.install_python_package(arch)
python
def build_arch(self, arch): '''Build any cython components, then install the Python module by calling setup.py install with the target Python dir. ''' Recipe.build_arch(self, arch) self.build_cython_components(arch) self.install_python_package(arch)
[ "def", "build_arch", "(", "self", ",", "arch", ")", ":", "Recipe", ".", "build_arch", "(", "self", ",", "arch", ")", "self", ".", "build_cython_components", "(", "arch", ")", "self", ".", "install_python_package", "(", "arch", ")" ]
Build any cython components, then install the Python module by calling setup.py install with the target Python dir.
[ "Build", "any", "cython", "components", "then", "install", "the", "Python", "module", "by", "calling", "setup", ".", "py", "install", "with", "the", "target", "Python", "dir", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L981-L987
train
Build any cython components then install the Python module by calling setup. py install with the target Python dir.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipe.py
TargetPythonRecipe.reduce_object_file_names
def reduce_object_file_names(self, dirn): """Recursively renames all files named XXX.cpython-...-linux-gnu.so" to "XXX.so", i.e. removing the erroneous architecture name coming from the local system. """ py_so_files = shprint(sh.find, dirn, '-iname', '*.so') filens = py_s...
python
def reduce_object_file_names(self, dirn): """Recursively renames all files named XXX.cpython-...-linux-gnu.so" to "XXX.so", i.e. removing the erroneous architecture name coming from the local system. """ py_so_files = shprint(sh.find, dirn, '-iname', '*.so') filens = py_s...
[ "def", "reduce_object_file_names", "(", "self", ",", "dirn", ")", ":", "py_so_files", "=", "shprint", "(", "sh", ".", "find", ",", "dirn", ",", "'-iname'", ",", "'*.so'", ")", "filens", "=", "py_so_files", ".", "stdout", ".", "decode", "(", "'utf-8'", ")...
Recursively renames all files named XXX.cpython-...-linux-gnu.so" to "XXX.so", i.e. removing the erroneous architecture name coming from the local system.
[ "Recursively", "renames", "all", "files", "named", "XXX", ".", "cpython", "-", "...", "-", "linux", "-", "gnu", ".", "so", "to", "XXX", ".", "so", "i", ".", "e", ".", "removing", "the", "erroneous", "architecture", "name", "coming", "from", "the", "loc...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipe.py#L1152-L1164
train
Recursively renames all files named XXX. cpython -... - linux - gnu. so to XXX. so i. e. removing the erroneous architecture name coming from the local system.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipes/android/src/android/runnable.py
run_on_ui_thread
def run_on_ui_thread(f): '''Decorator to create automatically a :class:`Runnable` object with the function. The function will be delayed and call into the Activity thread. ''' def f2(*args, **kwargs): Runnable(f)(*args, **kwargs) return f2
python
def run_on_ui_thread(f): '''Decorator to create automatically a :class:`Runnable` object with the function. The function will be delayed and call into the Activity thread. ''' def f2(*args, **kwargs): Runnable(f)(*args, **kwargs) return f2
[ "def", "run_on_ui_thread", "(", "f", ")", ":", "def", "f2", "(", "*", "args", ",", "*", "*", "kwargs", ")", ":", "Runnable", "(", "f", ")", "(", "*", "args", ",", "*", "*", "kwargs", ")", "return", "f2" ]
Decorator to create automatically a :class:`Runnable` object with the function. The function will be delayed and call into the Activity thread.
[ "Decorator", "to", "create", "automatically", "a", ":", "class", ":", "Runnable", "object", "with", "the", "function", ".", "The", "function", "will", "be", "delayed", "and", "call", "into", "the", "Activity", "thread", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/android/src/android/runnable.py#L43-L49
train
Decorator to create automatically a : class:`Runnable` object with the function. The function will be run in the UI thread.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/recipes/android/src/android/mixer.py
Channel
def Channel(n): """ Gets the channel with the given number. """ rv = channels.get(n, None) if rv is None: rv = ChannelImpl(n) channels[n] = rv return rv
python
def Channel(n): """ Gets the channel with the given number. """ rv = channels.get(n, None) if rv is None: rv = ChannelImpl(n) channels[n] = rv return rv
[ "def", "Channel", "(", "n", ")", ":", "rv", "=", "channels", ".", "get", "(", "n", ",", "None", ")", "if", "rv", "is", "None", ":", "rv", "=", "ChannelImpl", "(", "n", ")", "channels", "[", "n", "]", "=", "rv", "return", "rv" ]
Gets the channel with the given number.
[ "Gets", "the", "channel", "with", "the", "given", "number", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/recipes/android/src/android/mixer.py#L184-L194
train
Returns the channel with the given number.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
generate
def generate(node, environment, name, filename, stream=None, defer_init=False): """Generate the python source for a node tree.""" if not isinstance(node, nodes.Template): raise TypeError('Can\'t compile non template nodes') generator = CodeGenerator(environment, name, filename, stream, ...
python
def generate(node, environment, name, filename, stream=None, defer_init=False): """Generate the python source for a node tree.""" if not isinstance(node, nodes.Template): raise TypeError('Can\'t compile non template nodes') generator = CodeGenerator(environment, name, filename, stream, ...
[ "def", "generate", "(", "node", ",", "environment", ",", "name", ",", "filename", ",", "stream", "=", "None", ",", "defer_init", "=", "False", ")", ":", "if", "not", "isinstance", "(", "node", ",", "nodes", ".", "Template", ")", ":", "raise", "TypeErro...
Generate the python source for a node tree.
[ "Generate", "the", "python", "source", "for", "a", "node", "tree", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L57-L65
train
Generate the python source for a node tree.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
Identifiers.add_special
def add_special(self, name): """Register a special name like `loop`.""" self.undeclared.discard(name) self.declared.add(name)
python
def add_special(self, name): """Register a special name like `loop`.""" self.undeclared.discard(name) self.declared.add(name)
[ "def", "add_special", "(", "self", ",", "name", ")", ":", "self", ".", "undeclared", ".", "discard", "(", "name", ")", "self", ".", "declared", ".", "add", "(", "name", ")" ]
Register a special name like `loop`.
[ "Register", "a", "special", "name", "like", "loop", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L125-L128
train
Register a special name like loop.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
Identifiers.is_declared
def is_declared(self, name, local_only=False): """Check if a name is declared in this or an outer scope.""" if name in self.declared_locally or name in self.declared_parameter: return True if local_only: return False return name in self.declared
python
def is_declared(self, name, local_only=False): """Check if a name is declared in this or an outer scope.""" if name in self.declared_locally or name in self.declared_parameter: return True if local_only: return False return name in self.declared
[ "def", "is_declared", "(", "self", ",", "name", ",", "local_only", "=", "False", ")", ":", "if", "name", "in", "self", ".", "declared_locally", "or", "name", "in", "self", ".", "declared_parameter", ":", "return", "True", "if", "local_only", ":", "return",...
Check if a name is declared in this or an outer scope.
[ "Check", "if", "a", "name", "is", "declared", "in", "this", "or", "an", "outer", "scope", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L130-L136
train
Check if a name is declared in this or an outer scope.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
Frame.copy
def copy(self): """Create a copy of the current one.""" rv = object.__new__(self.__class__) rv.__dict__.update(self.__dict__) rv.identifiers = object.__new__(self.identifiers.__class__) rv.identifiers.__dict__.update(self.identifiers.__dict__) return rv
python
def copy(self): """Create a copy of the current one.""" rv = object.__new__(self.__class__) rv.__dict__.update(self.__dict__) rv.identifiers = object.__new__(self.identifiers.__class__) rv.identifiers.__dict__.update(self.identifiers.__dict__) return rv
[ "def", "copy", "(", "self", ")", ":", "rv", "=", "object", ".", "__new__", "(", "self", ".", "__class__", ")", "rv", ".", "__dict__", ".", "update", "(", "self", ".", "__dict__", ")", "rv", ".", "identifiers", "=", "object", ".", "__new__", "(", "s...
Create a copy of the current one.
[ "Create", "a", "copy", "of", "the", "current", "one", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L188-L194
train
Create a copy of the current one.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
Frame.find_shadowed
def find_shadowed(self, extra=()): """Find all the shadowed names. extra is an iterable of variables that may be defined with `add_special` which may occour scoped. """ i = self.identifiers return (i.declared | i.outer_undeclared) & \ (i.declared_locally | i.decla...
python
def find_shadowed(self, extra=()): """Find all the shadowed names. extra is an iterable of variables that may be defined with `add_special` which may occour scoped. """ i = self.identifiers return (i.declared | i.outer_undeclared) & \ (i.declared_locally | i.decla...
[ "def", "find_shadowed", "(", "self", ",", "extra", "=", "(", ")", ")", ":", "i", "=", "self", ".", "identifiers", "return", "(", "i", ".", "declared", "|", "i", ".", "outer_undeclared", ")", "&", "(", "i", ".", "declared_locally", "|", "i", ".", "d...
Find all the shadowed names. extra is an iterable of variables that may be defined with `add_special` which may occour scoped.
[ "Find", "all", "the", "shadowed", "names", ".", "extra", "is", "an", "iterable", "of", "variables", "that", "may", "be", "defined", "with", "add_special", "which", "may", "occour", "scoped", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L205-L212
train
Find all the shadowed names.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.blockvisit
def blockvisit(self, nodes, frame): """Visit a list of nodes as block in a frame. If the current frame is no buffer a dummy ``if 0: yield None`` is written automatically unless the force_generator parameter is set to False. """ if frame.buffer is None: self.writeline...
python
def blockvisit(self, nodes, frame): """Visit a list of nodes as block in a frame. If the current frame is no buffer a dummy ``if 0: yield None`` is written automatically unless the force_generator parameter is set to False. """ if frame.buffer is None: self.writeline...
[ "def", "blockvisit", "(", "self", ",", "nodes", ",", "frame", ")", ":", "if", "frame", ".", "buffer", "is", "None", ":", "self", ".", "writeline", "(", "'if 0: yield None'", ")", "else", ":", "self", ".", "writeline", "(", "'pass'", ")", "try", ":", ...
Visit a list of nodes as block in a frame. If the current frame is no buffer a dummy ``if 0: yield None`` is written automatically unless the force_generator parameter is set to False.
[ "Visit", "a", "list", "of", "nodes", "as", "block", "in", "a", "frame", ".", "If", "the", "current", "frame", "is", "no", "buffer", "a", "dummy", "if", "0", ":", "yield", "None", "is", "written", "automatically", "unless", "the", "force_generator", "para...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L482-L495
train
Visit a list of nodes as block in a frame.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.pull_locals
def pull_locals(self, frame): """Pull all the references identifiers into the local scope.""" for name in frame.identifiers.undeclared: self.writeline('l_%s = context.resolve(%r)' % (name, name))
python
def pull_locals(self, frame): """Pull all the references identifiers into the local scope.""" for name in frame.identifiers.undeclared: self.writeline('l_%s = context.resolve(%r)' % (name, name))
[ "def", "pull_locals", "(", "self", ",", "frame", ")", ":", "for", "name", "in", "frame", ".", "identifiers", ".", "undeclared", ":", "self", ".", "writeline", "(", "'l_%s = context.resolve(%r)'", "%", "(", "name", ",", "name", ")", ")" ]
Pull all the references identifiers into the local scope.
[ "Pull", "all", "the", "references", "identifiers", "into", "the", "local", "scope", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L577-L580
train
Pull all the references identifiers into the local scope.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.unoptimize_scope
def unoptimize_scope(self, frame): """Disable Python optimizations for the frame.""" # XXX: this is not that nice but it has no real overhead. It # mainly works because python finds the locals before dead code # is removed. If that breaks we have to add a dummy function # that ...
python
def unoptimize_scope(self, frame): """Disable Python optimizations for the frame.""" # XXX: this is not that nice but it has no real overhead. It # mainly works because python finds the locals before dead code # is removed. If that breaks we have to add a dummy function # that ...
[ "def", "unoptimize_scope", "(", "self", ",", "frame", ")", ":", "# XXX: this is not that nice but it has no real overhead. It", "# mainly works because python finds the locals before dead code", "# is removed. If that breaks we have to add a dummy function", "# that just accepts the argument...
Disable Python optimizations for the frame.
[ "Disable", "Python", "optimizations", "for", "the", "frame", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L595-L605
train
Disable Python optimizations for the frame.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.push_scope
def push_scope(self, frame, extra_vars=()): """This function returns all the shadowed variables in a dict in the form name: alias and will write the required assignments into the current scope. No indentation takes place. This also predefines locally declared variables from the loop ...
python
def push_scope(self, frame, extra_vars=()): """This function returns all the shadowed variables in a dict in the form name: alias and will write the required assignments into the current scope. No indentation takes place. This also predefines locally declared variables from the loop ...
[ "def", "push_scope", "(", "self", ",", "frame", ",", "extra_vars", "=", "(", ")", ")", ":", "aliases", "=", "{", "}", "for", "name", "in", "frame", ".", "find_shadowed", "(", "extra_vars", ")", ":", "aliases", "[", "name", "]", "=", "ident", "=", "...
This function returns all the shadowed variables in a dict in the form name: alias and will write the required assignments into the current scope. No indentation takes place. This also predefines locally declared variables from the loop body because under some circumstances it may be t...
[ "This", "function", "returns", "all", "the", "shadowed", "variables", "in", "a", "dict", "in", "the", "form", "name", ":", "alias", "and", "will", "write", "the", "required", "assignments", "into", "the", "current", "scope", ".", "No", "indentation", "takes"...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L607-L627
train
This function returns all the shadowed variables in a dict in the form name alias.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.pop_scope
def pop_scope(self, aliases, frame): """Restore all aliases and delete unused variables.""" for name, alias in aliases.iteritems(): self.writeline('l_%s = %s' % (name, alias)) to_delete = set() for name in frame.identifiers.declared_locally: if name not in aliases...
python
def pop_scope(self, aliases, frame): """Restore all aliases and delete unused variables.""" for name, alias in aliases.iteritems(): self.writeline('l_%s = %s' % (name, alias)) to_delete = set() for name in frame.identifiers.declared_locally: if name not in aliases...
[ "def", "pop_scope", "(", "self", ",", "aliases", ",", "frame", ")", ":", "for", "name", ",", "alias", "in", "aliases", ".", "iteritems", "(", ")", ":", "self", ".", "writeline", "(", "'l_%s = %s'", "%", "(", "name", ",", "alias", ")", ")", "to_delete...
Restore all aliases and delete unused variables.
[ "Restore", "all", "aliases", "and", "delete", "unused", "variables", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L629-L641
train
Restore all aliases and delete unused variables.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.function_scoping
def function_scoping(self, node, frame, children=None, find_special=True): """In Jinja a few statements require the help of anonymous functions. Those are currently macros and call blocks and in the future also recursive loops. As there is currently technical l...
python
def function_scoping(self, node, frame, children=None, find_special=True): """In Jinja a few statements require the help of anonymous functions. Those are currently macros and call blocks and in the future also recursive loops. As there is currently technical l...
[ "def", "function_scoping", "(", "self", ",", "node", ",", "frame", ",", "children", "=", "None", ",", "find_special", "=", "True", ")", ":", "# we have to iterate twice over it, make sure that works", "if", "children", "is", "None", ":", "children", "=", "node", ...
In Jinja a few statements require the help of anonymous functions. Those are currently macros and call blocks and in the future also recursive loops. As there is currently technical limitation that doesn't allow reading and writing a variable in a scope where the initial value is comin...
[ "In", "Jinja", "a", "few", "statements", "require", "the", "help", "of", "anonymous", "functions", ".", "Those", "are", "currently", "macros", "and", "call", "blocks", "and", "in", "the", "future", "also", "recursive", "loops", ".", "As", "there", "is", "c...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L643-L710
train
This function is used to generate code for the anonymous functions.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.macro_body
def macro_body(self, node, frame, children=None): """Dump the function def of a macro or call block.""" frame = self.function_scoping(node, frame, children) # macros are delayed, they never require output checks frame.require_output_check = False args = frame.arguments # ...
python
def macro_body(self, node, frame, children=None): """Dump the function def of a macro or call block.""" frame = self.function_scoping(node, frame, children) # macros are delayed, they never require output checks frame.require_output_check = False args = frame.arguments # ...
[ "def", "macro_body", "(", "self", ",", "node", ",", "frame", ",", "children", "=", "None", ")", ":", "frame", "=", "self", ".", "function_scoping", "(", "node", ",", "frame", ",", "children", ")", "# macros are delayed, they never require output checks", "frame"...
Dump the function def of a macro or call block.
[ "Dump", "the", "function", "def", "of", "a", "macro", "or", "call", "block", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L712-L734
train
Dump the function def of a macro or call block.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.macro_def
def macro_def(self, node, frame): """Dump the macro definition for the def created by macro_body.""" arg_tuple = ', '.join(repr(x.name) for x in node.args) name = getattr(node, 'name', None) if len(node.args) == 1: arg_tuple += ',' self.write('Macro(environment, macro...
python
def macro_def(self, node, frame): """Dump the macro definition for the def created by macro_body.""" arg_tuple = ', '.join(repr(x.name) for x in node.args) name = getattr(node, 'name', None) if len(node.args) == 1: arg_tuple += ',' self.write('Macro(environment, macro...
[ "def", "macro_def", "(", "self", ",", "node", ",", "frame", ")", ":", "arg_tuple", "=", "', '", ".", "join", "(", "repr", "(", "x", ".", "name", ")", "for", "x", "in", "node", ".", "args", ")", "name", "=", "getattr", "(", "node", ",", "'name'", ...
Dump the macro definition for the def created by macro_body.
[ "Dump", "the", "macro", "definition", "for", "the", "def", "created", "by", "macro_body", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L736-L751
train
Dump the macro definition for the def created by macro_body.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.visit_Block
def visit_Block(self, node, frame): """Call a block and register it for the template.""" level = 1 if frame.toplevel: # if we know that we are a child template, there is no need to # check if we are one if self.has_known_extends: return ...
python
def visit_Block(self, node, frame): """Call a block and register it for the template.""" level = 1 if frame.toplevel: # if we know that we are a child template, there is no need to # check if we are one if self.has_known_extends: return ...
[ "def", "visit_Block", "(", "self", ",", "node", ",", "frame", ")", ":", "level", "=", "1", "if", "frame", ".", "toplevel", ":", "# if we know that we are a child template, there is no need to", "# check if we are one", "if", "self", ".", "has_known_extends", ":", "r...
Call a block and register it for the template.
[ "Call", "a", "block", "and", "register", "it", "for", "the", "template", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L861-L878
train
Call a block and register it for the template.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py
CodeGenerator.visit_Import
def visit_Import(self, node, frame): """Visit regular imports.""" if node.with_context: self.unoptimize_scope(frame) self.writeline('l_%s = ' % node.target, node) if frame.toplevel: self.write('context.vars[%r] = ' % node.target) self.write('environment.ge...
python
def visit_Import(self, node, frame): """Visit regular imports.""" if node.with_context: self.unoptimize_scope(frame) self.writeline('l_%s = ' % node.target, node) if frame.toplevel: self.write('context.vars[%r] = ' % node.target) self.write('environment.ge...
[ "def", "visit_Import", "(", "self", ",", "node", ",", "frame", ")", ":", "if", "node", ".", "with_context", ":", "self", ".", "unoptimize_scope", "(", "frame", ")", "self", ".", "writeline", "(", "'l_%s = '", "%", "node", ".", "target", ",", "node", ")...
Visit regular imports.
[ "Visit", "regular", "imports", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/compiler.py#L969-L985
train
Visit regular imports.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py
safe_range
def safe_range(*args): """A range that can't generate ranges with a length of more than MAX_RANGE items. """ rng = xrange(*args) if len(rng) > MAX_RANGE: raise OverflowError('range too big, maximum size for range is %d' % MAX_RANGE) return rng
python
def safe_range(*args): """A range that can't generate ranges with a length of more than MAX_RANGE items. """ rng = xrange(*args) if len(rng) > MAX_RANGE: raise OverflowError('range too big, maximum size for range is %d' % MAX_RANGE) return rng
[ "def", "safe_range", "(", "*", "args", ")", ":", "rng", "=", "xrange", "(", "*", "args", ")", "if", "len", "(", "rng", ")", ">", "MAX_RANGE", ":", "raise", "OverflowError", "(", "'range too big, maximum size for range is %d'", "%", "MAX_RANGE", ")", "return"...
A range that can't generate ranges with a length of more than MAX_RANGE items.
[ "A", "range", "that", "can", "t", "generate", "ranges", "with", "a", "length", "of", "more", "than", "MAX_RANGE", "items", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py#L90-L98
train
A range that can t generate more than MAX_RANGE items.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py
is_internal_attribute
def is_internal_attribute(obj, attr): """Test if the attribute given is an internal python attribute. For example this function returns `True` for the `func_code` attribute of python objects. This is useful if the environment method :meth:`~SandboxedEnvironment.is_safe_attribute` is overriden. >>...
python
def is_internal_attribute(obj, attr): """Test if the attribute given is an internal python attribute. For example this function returns `True` for the `func_code` attribute of python objects. This is useful if the environment method :meth:`~SandboxedEnvironment.is_safe_attribute` is overriden. >>...
[ "def", "is_internal_attribute", "(", "obj", ",", "attr", ")", ":", "if", "isinstance", "(", "obj", ",", "FunctionType", ")", ":", "if", "attr", "in", "UNSAFE_FUNCTION_ATTRIBUTES", ":", "return", "True", "elif", "isinstance", "(", "obj", ",", "MethodType", ")...
Test if the attribute given is an internal python attribute. For example this function returns `True` for the `func_code` attribute of python objects. This is useful if the environment method :meth:`~SandboxedEnvironment.is_safe_attribute` is overriden. >>> from jinja2.sandbox import is_internal_attr...
[ "Test", "if", "the", "attribute", "given", "is", "an", "internal", "python", "attribute", ".", "For", "example", "this", "function", "returns", "True", "for", "the", "func_code", "attribute", "of", "python", "objects", ".", "This", "is", "useful", "if", "the...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py#L113-L142
train
Test if the attribute given is an internal python attribute.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py
SandboxedEnvironment.getitem
def getitem(self, obj, argument): """Subscribe an object from sandboxed code.""" try: return obj[argument] except (TypeError, LookupError): if isinstance(argument, basestring): try: attr = str(argument) except: ...
python
def getitem(self, obj, argument): """Subscribe an object from sandboxed code.""" try: return obj[argument] except (TypeError, LookupError): if isinstance(argument, basestring): try: attr = str(argument) except: ...
[ "def", "getitem", "(", "self", ",", "obj", ",", "argument", ")", ":", "try", ":", "return", "obj", "[", "argument", "]", "except", "(", "TypeError", ",", "LookupError", ")", ":", "if", "isinstance", "(", "argument", ",", "basestring", ")", ":", "try", ...
Subscribe an object from sandboxed code.
[ "Subscribe", "an", "object", "from", "sandboxed", "code", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py#L207-L226
train
Subscribe an object from sandboxed code.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py
SandboxedEnvironment.call
def call(__self, __context, __obj, *args, **kwargs): """Call an object from sandboxed code.""" # the double prefixes are to avoid double keyword argument # errors when proxying the call. if not __self.is_safe_callable(__obj): raise SecurityError('%r is not safely callable' % ...
python
def call(__self, __context, __obj, *args, **kwargs): """Call an object from sandboxed code.""" # the double prefixes are to avoid double keyword argument # errors when proxying the call. if not __self.is_safe_callable(__obj): raise SecurityError('%r is not safely callable' % ...
[ "def", "call", "(", "__self", ",", "__context", ",", "__obj", ",", "*", "args", ",", "*", "*", "kwargs", ")", ":", "# the double prefixes are to avoid double keyword argument", "# errors when proxying the call.", "if", "not", "__self", ".", "is_safe_callable", "(", ...
Call an object from sandboxed code.
[ "Call", "an", "object", "from", "sandboxed", "code", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/sandbox.py#L253-L259
train
Call an object from sandboxed code.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/utils.py
open_if_exists
def open_if_exists(filename, mode='rb'): """Returns a file descriptor for the filename if that file exists, otherwise `None`. """ try: return open(filename, mode) except IOError, e: if e.errno not in (errno.ENOENT, errno.EISDIR): raise
python
def open_if_exists(filename, mode='rb'): """Returns a file descriptor for the filename if that file exists, otherwise `None`. """ try: return open(filename, mode) except IOError, e: if e.errno not in (errno.ENOENT, errno.EISDIR): raise
[ "def", "open_if_exists", "(", "filename", ",", "mode", "=", "'rb'", ")", ":", "try", ":", "return", "open", "(", "filename", ",", "mode", ")", "except", "IOError", ",", "e", ":", "if", "e", ".", "errno", "not", "in", "(", "errno", ".", "ENOENT", ",...
Returns a file descriptor for the filename if that file exists, otherwise `None`.
[ "Returns", "a", "file", "descriptor", "for", "the", "filename", "if", "that", "file", "exists", "otherwise", "None", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/utils.py#L219-L227
train
Returns a file descriptor for the filename if that file exists otherwise None.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/utils.py
object_type_repr
def object_type_repr(obj): """Returns the name of the object's type. For some recognized singletons the name of the object is returned instead. (For example for `None` and `Ellipsis`). """ if obj is None: return 'None' elif obj is Ellipsis: return 'Ellipsis' if obj.__class__...
python
def object_type_repr(obj): """Returns the name of the object's type. For some recognized singletons the name of the object is returned instead. (For example for `None` and `Ellipsis`). """ if obj is None: return 'None' elif obj is Ellipsis: return 'Ellipsis' if obj.__class__...
[ "def", "object_type_repr", "(", "obj", ")", ":", "if", "obj", "is", "None", ":", "return", "'None'", "elif", "obj", "is", "Ellipsis", ":", "return", "'Ellipsis'", "if", "obj", ".", "__class__", ".", "__module__", "==", "'__builtin__'", ":", "name", "=", ...
Returns the name of the object's type. For some recognized singletons the name of the object is returned instead. (For example for `None` and `Ellipsis`).
[ "Returns", "the", "name", "of", "the", "object", "s", "type", ".", "For", "some", "recognized", "singletons", "the", "name", "of", "the", "object", "is", "returned", "instead", ".", "(", "For", "example", "for", "None", "and", "Ellipsis", ")", "." ]
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/utils.py#L230-L243
train
Returns the name of the object s type.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...
kivy/python-for-android
pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/utils.py
urlize
def urlize(text, trim_url_limit=None, nofollow=False): """Converts any URLs in text into clickable links. Works on http://, https:// and www. links. Links can have trailing punctuation (periods, commas, close-parens) and leading punctuation (opening parens) and it'll still do the right thing. If tr...
python
def urlize(text, trim_url_limit=None, nofollow=False): """Converts any URLs in text into clickable links. Works on http://, https:// and www. links. Links can have trailing punctuation (periods, commas, close-parens) and leading punctuation (opening parens) and it'll still do the right thing. If tr...
[ "def", "urlize", "(", "text", ",", "trim_url_limit", "=", "None", ",", "nofollow", "=", "False", ")", ":", "trim_url", "=", "lambda", "x", ",", "limit", "=", "trim_url_limit", ":", "limit", "is", "not", "None", "and", "(", "x", "[", ":", "limit", "]"...
Converts any URLs in text into clickable links. Works on http://, https:// and www. links. Links can have trailing punctuation (periods, commas, close-parens) and leading punctuation (opening parens) and it'll still do the right thing. If trim_url_limit is not None, the URLs in link text will be limite...
[ "Converts", "any", "URLs", "in", "text", "into", "clickable", "links", ".", "Works", "on", "http", ":", "//", "https", ":", "//", "and", "www", ".", "links", ".", "Links", "can", "have", "trailing", "punctuation", "(", "periods", "commas", "close", "-", ...
8e0e8056bc22e4d5bd3398a6b0301f38ff167933
https://github.com/kivy/python-for-android/blob/8e0e8056bc22e4d5bd3398a6b0301f38ff167933/pythonforandroid/bootstraps/pygame/build/buildlib/jinja2.egg/jinja2/utils.py#L258-L299
train
Converts any URLs in text into clickable links.
Pu7Z6IJCgH3a,vcEHXBQXuDuh,sHOWSIAKtU58,ZVWAAMjVVHHl,qRin5pdYOdbB,IySsVMyKT3tF,FwEHNICjJCy0,yISIa0MMKKfB,GAtvbI59wr0o,OmNM6rT0Sgul,gu1MSKhYvigU,S2TTo9DhhiSh,aaLV7ZjAfkcR,ker4pIJmdvxf,WaQEaQCVMQ03,xV97BFGi0hY9,YnM1HtHE4j7G,X5FyJb4ToTo6,jLmadlzMdunT,GGFwFLsDF9Fv,prtR0Uw1GMh5,oNamnshN4dFG,QZzQeAYvsoum,VHAt7CcYKC2T,cKsTbNGL...