Find and replace unneeded f-strings in your code.
pip install rm_unneeded_f_str
Run via the CLI on a file or folder:
rm-unneeded-f-str path/to/file.py
rm-unneeded-f-str path/to/folder/
Or use as a pre-commit hook:
- repo: https://github.com/dannysepler/rm_unneeded_f_str
rev: v0.2.0
hooks:
- id: rm-unneeded-f-str
-f'hello'
+'hello'
-f'''hello'''
+'''hello'''
-rf'hello'
+r'hello'
-f'''hello
-world'''
+f'''hello
+world'''
f'hello {world}'
f'''hello
{world}'''