# Path: statik/utils.py
# def add_url_path_component(path, component):
#     return '%s/%s' % (path.rstrip('/'), component.lstrip('/'))
# 
# Path: statik/templatetags.py
# class TemplateTagStore(object):
#     def __init__(self):
#     def invoke_tag(self, tag_name, context, *args, **kwargs):
#     def register_tag(self, name, fn):
#     def register_filter(self, name, fn):
#     def simple_tag(self, *args, **kwargs):
#             def decorator(fn):
#     def filter(self, *args, **kwargs):
#             def decorator(fn):


from jinja2 import nodes
from jinja2.ext import Extension
from jinja2.exceptions import TemplateSyntaxError
from statik.utils import add_url_path_component
from statik import templatetags
import lipsum
import logging

        # get the first parameter: the view name
        args = [parser.parse_expression()]

        # if there's a comma, we've also got an instance variable here
        if parser.stream.skip_if('comma'):
            args.append(parser.parse_expression())
        else:
            # no instance supplied for URL tag
            args.append(nodes.Const(None))

        return nodes.Output(
            [self.call_method('_url', args)],
            lineno=lineno
        )


class StatikAssetExtension(Extension):
    """Provides the `{% asset %}` extension for embedding URLs to asset files in your templates."""

    tags = {'asset'}

    def __init__(self, environment):
        super(StatikAssetExtension, self).__init__(environment)

        environment.extend(
            statik_base_asset_url=''
        )

    def _asset(self, filename):

# Path: statik/utils.py
# def add_url_path_component(path, component):
#     return '%s/%s' % (path.rstrip('/'), component.lstrip('/'))
# 
# Path: statik/templatetags.py
# class TemplateTagStore(object):
#     def __init__(self):
#     def invoke_tag(self, tag_name, context, *args, **kwargs):
#     def register_tag(self, name, fn):
#     def register_filter(self, name, fn):
#     def simple_tag(self, *args, **kwargs):
#             def decorator(fn):
#     def filter(self, *args, **kwargs):
#             def decorator(fn):


# Path: statik/jinja2ext.py
from jinja2 import nodes
from jinja2.ext import Extension
from jinja2.exceptions import TemplateSyntaxError
from statik.utils import add_url_path_component
from statik import templatetags
import lipsum
import logging


        # get the first parameter: the view name
        args = [parser.parse_expression()]

        # if there's a comma, we've also got an instance variable here
        if parser.stream.skip_if('comma'):
            args.append(parser.parse_expression())
        else:
            # no instance supplied for URL tag
            args.append(nodes.Const(None))

        return nodes.Output(
            [self.call_method('_url', args)],
            lineno=lineno
        )


class StatikAssetExtension(Extension):
    """Provides the `{% asset %}` extension for embedding URLs to asset files in your templates."""

    tags = {'asset'}

    def __init__(self, environment):
        super(StatikAssetExtension, self).__init__(environment)

        environment.extend(
            statik_base_asset_url=''
        )

    def _asset(self, filename):

        return add_url_path_component(