miracle2k / webassets

Asset management for Python web development.
BSD 2-Clause "Simplified" License
924 stars 259 forks source link

Update pypi package to last updates from master branch #503

Closed barbossa closed 4 years ago

barbossa commented 6 years ago

I see, that code from https://pypi.python.org/pypi/webassets and https://github.com/miracle2k/webassets/ are different. For example code for cleancss filter:

  1. From github -> https://github.com/miracle2k/webassets/blob/master/src/webassets/filter/cleancss.py#L9
  2. From pip 0.12.1
class CleanCSS(ExternalTool):
    """
    Minify css using `Clean-css <https://github.com/GoalSmashers/clean-css/>`_.

    Clean-css is an external tool written for NodeJS; this filter assumes that
    the ``cleancss`` executable is in the path. Otherwise, you may define
    a ``CLEANCSS_BIN`` setting.

    Additional options may be passed to ``cleancss`` binary using the setting
    ``CLEANCSS_EXTRA_ARGS``, which expects a list of strings.
    """
    name = 'cleancss'
    options = {
        'binary': 'CLEANCSS_BIN',
        'extra_args': 'CLEANCSS_EXTRA_ARGS',
    }

    def output(self, _in, out, **kw):
        args = [self.binary or 'cleancss']
        if self.extra_args:
            args.extend(self.extra_args)
        self.subprocess(args, out, _in)

    def input(self, _in, out, **kw):
        args = [self.binary or 'cleancss', '--root', os.path.dirname(kw['source_path'])]
        if self.extra_args:
            args.extend(self.extra_args)
        self.subprocess(args, out, _in)
barbossa commented 6 years ago

@miracle2k, why don`t you update https://pypi.python.org/pypi/webassets to latest version?

jhonatandarosa commented 6 years ago

@miracle2k, the Sass filter isn't updated too. Missing SASS_SOURCE_MAPS

miracle2k commented 4 years ago

Done.