https://github.com/mozillazg/f
Ruby-Style String Interpolation for Python.
https://github.com/mozillazg/f
python string-interpolation
Last synced: 8 months ago
JSON representation
Ruby-Style String Interpolation for Python.
- Host: GitHub
- URL: https://github.com/mozillazg/f
- Owner: mozillazg
- License: mit
- Created: 2016-12-28T14:18:38.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-01-12T13:40:06.000Z (about 9 years ago)
- Last Synced: 2025-01-05T18:47:30.781Z (about 1 year ago)
- Topics: python, string-interpolation
- Language: Python
- Homepage:
- Size: 16.6 KB
- Stars: 1
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- Changelog: CHANGELOG.rst
- License: LICENSE
Awesome Lists containing this project
README
f
=============================
|Build| |Coverage|
.. \|Pypi version\|
Ruby-Style String Interpolation for Python.
* GitHub: https://github.com/mozillazg/f
* License: MIT license
* Python version: 2.6, 2.7, pypy, pypy3, 3.3, 3.4, 3.5, 3.6
.. \PyPI: https://pypi.python.org/pypi/f
Usage
--------
.. code-block:: python
>>> import f
>>> a = 2
>>> b = 3
>>> f('#{a}')
'2'
>>> f('#{a + b}')
'5'
.. |Build| image:: https://img.shields.io/travis/mozillazg/f/master.svg
:target: https://travis-ci.org/mozillazg/f
.. |Coverage| image:: https://img.shields.io/coveralls/mozillazg/f/master.svg
:target: https://coveralls.io/r/mozillazg/f
.. .. |PyPI version| image:: https://img.shields.io/pypi/v/f.svg
.. :target: https://pypi.python.org/pypi/f