libsass-python: Sass_/SCSS for Python
=====================================
.. image:: https://badge.fury.io/py/libsass.svg
:alt: PyPI
:target: https://pypi.org/pypi/libsass/
.. image:: https://github.com/sass/libsass-python/actions/workflows/main.yml/badge.svg
:target: https://github.com/sass/libsass-python/actions/workflows/main.yml
:alt: Build Status
.. image:: https://results.pre-commit.ci/badge/github/sass/libsass-python/main.svg
:target: https://results.pre-commit.ci/latest/github/sass/libsass-python/main
:alt: pre-commit.ci status
This package provides a simple Python extension module ``sass`` which is
binding LibSass_ (written in C/C++ by Hampton Catlin and Aaron Leung).
It's very straightforward and there isn't any headache related to Python
distribution/deployment. That means you can add just ``libsass`` into
your ``setup.py``'s ``install_requires`` list or ``requirements.txt`` file.
No need for Ruby nor Node.js.
It currently supports CPython 3.7+, and PyPy 3!
.. _Sass: https://sass-lang.com/
.. _LibSass: https://github.com/sass/libsass
Features
--------
- You don't need any Ruby/Node.js stack at all, for development or deployment
either.
- Fast. (LibSass_ is written in C++.)
- Simple API. See the below example code for details.
- Custom functions.
- ``@import`` callbacks.
- Support both tabbed (Sass) and braces (SCSS) syntax.
- WSGI middleware for ease of development.
It automatically compiles Sass/SCSS files for each request.
- ``setuptools``/``distutils`` integration.
You can build all Sass/SCSS files using
``setup.py build_sass`` command.
- Works also on PyPy.
- Provides prebuilt wheel_ binaries for Linux, Windows, and Mac.
.. _wheel: https://www.python.org/dev/peps/pep-0427/
Install
-------
It's available on PyPI_, so you can install it using ``pip`` (or
``easy_install``):
.. code-block:: console
$ pip install libsass
.. note::
libsass requires some features introduced by the recent C++ standard.
You need a C++ compiler that support those features.
See also libsass project's README_ file.
.. _PyPI: https://pypi.org/pypi/libsass/
.. _README: https://github.com/sass/libsass#readme
.. _example:
Example
-------
.. code-block:: pycon
>>> import sass
>>> print sass.compile(string='a { b { color: blue; } }')
a b {
color: blue; }
Docs
----
There's the user guide manual and the full API reference for ``libsass``:
https://sass.github.io/libsass-python/
You can build the docs by yourself:
.. code-block:: console
$ cd docs/
$ make html
The built docs will go to ``docs/_build/html/`` directory.
Credit
------
Hong Minhee wrote this Python binding of LibSass_.
Hampton Catlin and Aaron Leung wrote LibSass_, which is portable C/C++
implementation of Sass_.
Hampton Catlin originally designed Sass_ language and wrote the first
reference implementation of it in Ruby.
The above three are all distributed under `MIT license`_.
.. _MIT license: https://mit-license.org/
Raw data
{
"_id": null,
"home_page": "https://sass.github.io/libsass-python/",
"name": "libsass",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": "",
"keywords": "",
"author": "Hong Minhee",
"author_email": "minhee@dahlia.kr",
"download_url": "https://files.pythonhosted.org/packages/79/b4/ab091585eaa77299558e3289ca206846aefc123fb320b5656ab2542c20ad/libsass-0.23.0.tar.gz",
"platform": null,
"description": "libsass-python: Sass_/SCSS for Python\n=====================================\n\n.. image:: https://badge.fury.io/py/libsass.svg\n :alt: PyPI\n :target: https://pypi.org/pypi/libsass/\n\n.. image:: https://github.com/sass/libsass-python/actions/workflows/main.yml/badge.svg\n :target: https://github.com/sass/libsass-python/actions/workflows/main.yml\n :alt: Build Status\n\n.. image:: https://results.pre-commit.ci/badge/github/sass/libsass-python/main.svg\n :target: https://results.pre-commit.ci/latest/github/sass/libsass-python/main\n :alt: pre-commit.ci status\n\nThis package provides a simple Python extension module ``sass`` which is\nbinding LibSass_ (written in C/C++ by Hampton Catlin and Aaron Leung).\nIt's very straightforward and there isn't any headache related to Python\ndistribution/deployment. That means you can add just ``libsass`` into\nyour ``setup.py``'s ``install_requires`` list or ``requirements.txt`` file.\nNo need for Ruby nor Node.js.\n\nIt currently supports CPython 3.7+, and PyPy 3!\n\n.. _Sass: https://sass-lang.com/\n.. _LibSass: https://github.com/sass/libsass\n\n\nFeatures\n--------\n\n- You don't need any Ruby/Node.js stack at all, for development or deployment\n either.\n- Fast. (LibSass_ is written in C++.)\n- Simple API. See the below example code for details.\n- Custom functions.\n- ``@import`` callbacks.\n- Support both tabbed (Sass) and braces (SCSS) syntax.\n- WSGI middleware for ease of development.\n It automatically compiles Sass/SCSS files for each request.\n- ``setuptools``/``distutils`` integration.\n You can build all Sass/SCSS files using\n ``setup.py build_sass`` command.\n- Works also on PyPy.\n- Provides prebuilt wheel_ binaries for Linux, Windows, and Mac.\n\n.. _wheel: https://www.python.org/dev/peps/pep-0427/\n\n\nInstall\n-------\n\nIt's available on PyPI_, so you can install it using ``pip`` (or\n``easy_install``):\n\n.. code-block:: console\n\n $ pip install libsass\n\n.. note::\n\n libsass requires some features introduced by the recent C++ standard.\n You need a C++ compiler that support those features.\n See also libsass project's README_ file.\n\n.. _PyPI: https://pypi.org/pypi/libsass/\n.. _README: https://github.com/sass/libsass#readme\n\n\n.. _example:\n\nExample\n-------\n\n.. code-block:: pycon\n\n >>> import sass\n >>> print sass.compile(string='a { b { color: blue; } }')\n a b {\n color: blue; }\n\n\nDocs\n----\n\nThere's the user guide manual and the full API reference for ``libsass``:\n\nhttps://sass.github.io/libsass-python/\n\nYou can build the docs by yourself:\n\n.. code-block:: console\n\n $ cd docs/\n $ make html\n\nThe built docs will go to ``docs/_build/html/`` directory.\n\n\nCredit\n------\n\nHong Minhee wrote this Python binding of LibSass_.\n\nHampton Catlin and Aaron Leung wrote LibSass_, which is portable C/C++\nimplementation of Sass_.\n\nHampton Catlin originally designed Sass_ language and wrote the first\nreference implementation of it in Ruby.\n\nThe above three are all distributed under `MIT license`_.\n\n.. _MIT license: https://mit-license.org/\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Sass for Python: A straightforward binding of libsass for Python.",
"version": "0.23.0",
"project_urls": {
"Homepage": "https://sass.github.io/libsass-python/"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "e513fc1bea1de880ca935137183727c7d4dd921c4128fc08b8ddc3698ba5a8a3",
"md5": "1a51aebce8227bfad3b20de83559bf2b",
"sha256": "34cae047cbbfc4ffa832a61cbb110f3c95f5471c6170c842d3fed161e40814dc"
},
"downloads": -1,
"filename": "libsass-0.23.0-cp38-abi3-macosx_11_0_x86_64.whl",
"has_sig": false,
"md5_digest": "1a51aebce8227bfad3b20de83559bf2b",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 1086783,
"upload_time": "2024-01-06T19:02:38",
"upload_time_iso_8601": "2024-01-06T19:02:38.903560Z",
"url": "https://files.pythonhosted.org/packages/e5/13/fc1bea1de880ca935137183727c7d4dd921c4128fc08b8ddc3698ba5a8a3/libsass-0.23.0-cp38-abi3-macosx_11_0_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "552f6af938651ff3aec0a0b00742209df1172bc297fa73531f292801693b7315",
"md5": "ce87b28b06615881d98b092f17b72910",
"sha256": "ea97d1b45cdc2fc3590cb9d7b60f1d8915d3ce17a98c1f2d4dd47ee0d9c68ce6"
},
"downloads": -1,
"filename": "libsass-0.23.0-cp38-abi3-macosx_14_0_arm64.whl",
"has_sig": false,
"md5_digest": "ce87b28b06615881d98b092f17b72910",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 982759,
"upload_time": "2024-01-06T19:02:41",
"upload_time_iso_8601": "2024-01-06T19:02:41.331579Z",
"url": "https://files.pythonhosted.org/packages/55/2f/6af938651ff3aec0a0b00742209df1172bc297fa73531f292801693b7315/libsass-0.23.0-cp38-abi3-macosx_14_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "fd5aeb5b62641df0459a3291fc206cf5bd669c0feed7814dded8edef4ade8512",
"md5": "d8e55b5f9f37c422ea19507655782db1",
"sha256": "4a218406d605f325d234e4678bd57126a66a88841cb95bee2caeafdc6f138306"
},
"downloads": -1,
"filename": "libsass-0.23.0-cp38-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.whl",
"has_sig": false,
"md5_digest": "d8e55b5f9f37c422ea19507655782db1",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 9444543,
"upload_time": "2024-01-06T19:02:43",
"upload_time_iso_8601": "2024-01-06T19:02:43.191988Z",
"url": "https://files.pythonhosted.org/packages/fd/5a/eb5b62641df0459a3291fc206cf5bd669c0feed7814dded8edef4ade8512/libsass-0.23.0-cp38-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "e5fc275783f5120970d859ae37d04b6a60c13bdec2aa4294b9dfa8a37b5c2513",
"md5": "6f4d6d332c7ed1da466b3cdf4357f1ca",
"sha256": "31e86d92a5c7a551df844b72d83fc2b5e50abc6fbbb31e296f7bebd6489ed1b4"
},
"downloads": -1,
"filename": "libsass-0.23.0-cp38-abi3-win32.whl",
"has_sig": false,
"md5_digest": "6f4d6d332c7ed1da466b3cdf4357f1ca",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 775481,
"upload_time": "2024-01-06T19:02:46",
"upload_time_iso_8601": "2024-01-06T19:02:46.050861Z",
"url": "https://files.pythonhosted.org/packages/e5/fc/275783f5120970d859ae37d04b6a60c13bdec2aa4294b9dfa8a37b5c2513/libsass-0.23.0-cp38-abi3-win32.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "ef20caf3c7cf2432d85263119798c45221ddf67bdd7dae8f626d14ff8db04040",
"md5": "b616a56b951e5ef16efc528928eb7f3d",
"sha256": "a2ec85d819f353cbe807432d7275d653710d12b08ec7ef61c124a580a8352f3c"
},
"downloads": -1,
"filename": "libsass-0.23.0-cp38-abi3-win_amd64.whl",
"has_sig": false,
"md5_digest": "b616a56b951e5ef16efc528928eb7f3d",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": ">=3.8",
"size": 872914,
"upload_time": "2024-01-06T19:02:47",
"upload_time_iso_8601": "2024-01-06T19:02:47.610733Z",
"url": "https://files.pythonhosted.org/packages/ef/20/caf3c7cf2432d85263119798c45221ddf67bdd7dae8f626d14ff8db04040/libsass-0.23.0-cp38-abi3-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "79b4ab091585eaa77299558e3289ca206846aefc123fb320b5656ab2542c20ad",
"md5": "e948913a9370ab648686ab7a83e4228a",
"sha256": "6f209955ede26684e76912caf329f4ccb57e4a043fd77fe0e7348dd9574f1880"
},
"downloads": -1,
"filename": "libsass-0.23.0.tar.gz",
"has_sig": false,
"md5_digest": "e948913a9370ab648686ab7a83e4228a",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 316068,
"upload_time": "2024-01-06T18:53:05",
"upload_time_iso_8601": "2024-01-06T18:53:05.404549Z",
"url": "https://files.pythonhosted.org/packages/79/b4/ab091585eaa77299558e3289ca206846aefc123fb320b5656ab2542c20ad/libsass-0.23.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-01-06 18:53:05",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "libsass"
}