Commit graph

66 commits

Author SHA1 Message Date
Christopher Pickering
e0814cf184
reformatted 2023-02-06 09:20:53 -06:00
Christopher Pickering
7c0a272150
fix(formatter): preserve windows line endings
Line ending from first line will now be preserved in the output.

closes #502
2023-01-19 08:30:31 -06:00
Christopher Pickering
9812f601e9
fix(check): fixed issue where check was reformatting files that contained a hyphen in the name
closes #494
2022-12-26 10:30:41 -06:00
Christopher Pickering
b53f670af8
feat(quiet): updated output of the --quiet flag to reduce unneeded verbose stuff 2022-09-26 13:47:41 +02:00
Christopher Pickering
489decb2e1
feat(linter): added --statistics flag to print summary of linter findings
closes #389
2022-09-19 09:41:54 +02:00
Christopher Pickering
bbcde2b426
feat(config): allow source files to be specified in the config file
This update allows a file list to be set in the config file.

closes #371
2022-09-12 12:43:04 +02:00
Christopher Pickering
2c46e976db
chore(lint): updated tox config 2022-09-12 09:58:45 +02:00
Christopher Pickering
3cdb7a7b97
feat(windows): added a better progress bar char for windows
closes #286
2022-09-07 13:25:00 -05:00
Christopher Pickering
83297bd15b
feat(config): added option for custom configuration file path
This can be used for a global .djlintrc file.

closes #170
2022-09-07 13:10:13 -05:00
John Mark Vandenberg
788715585c Fix spelling 2022-08-02 06:27:29 +08:00
Christopher Pickering
99b5ee2c1f
feat(formatter): added options to format css and js using jsbeautifier 2022-07-28 13:58:03 -05:00
Christopher Pickering
bbcf54a0f0
feat(new option): added option to attempt to keep blank lines in templates
--preser-blank-lines option can be used to try and keep existing blank lines during formatting.

closes #261
2022-06-30 07:53:24 -05:00
Christopher Pickering
15ead700d1
feat(whitespace): add option to preserver some whitespace before text
This option preserves some leading whitespace in text blocks.

closes #260
2022-06-15 13:41:14 -05:00
Christopher Pickering
6aa6986b6e
style(lint): fixed lint 2022-05-18 10:35:41 -05:00
Christopher Pickering
46395e28bc
fix(windows): fixed windows output. colorama was converting to cp1252 2022-05-18 10:31:19 -05:00
Christopher Pickering
e906b3e30a
fix(stdin encoding): added encoding to stdin text
Fixes #243
2022-05-18 08:35:54 -05:00
Christopher Pickering
8e0b4b1b41
fix(stdin and gitignore): updated to prevent gitignore from skipping std temp paths
Disabled gitignore option for stdin paths.

closes #224
2022-04-25 08:26:13 -05:00
Anders Kaseorg
beefd04471 Correctly initialize and deinitialize colorama
djlint is invoked with __name__ == "djlint" (it must be, or the
relative imports would fail), so the if __name__ == "__main__" block
does nothing.  These calls need to be made from main() itself.

The colorama_text decorator makes this easy.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2022-03-18 10:45:29 -07:00
Christopher Pickering
f9ff3477e1
closes #194, added test 2022-03-14 09:24:28 -05:00
Christopher Pickering
2acb8c3c28
closes #175, updated tests 2022-02-18 13:07:30 -06:00
Christopher Pickering
a260b8c063
docs update 2021-12-01 10:13:09 +01:00
Christopher Pickering
9a57551c7a
fixed test for github 2021-10-29 11:55:20 +03:00
Christopher Pickering
0111614913
closes #102, added test. 2021-10-29 11:42:39 +03:00
Christopher Pickering
ca87bb7d22
closes #115. added test 2021-10-14 13:30:24 +03:00
Christopher Pickering
f5334bb931
restructured code. closes #111 2021-10-14 13:19:48 +03:00
Mathias Jakobsen
ed3951838f
Add require_pragma option
This patch adds a configuration option for requiring files to have a
pragma comment at the beginning of the file in order to reformat the
file. This behaviour is useful for a slow adoption of the tool instead
of requiring the whole codebase to be converted at once.

The patch also contains tests for the different kinds of supported
pragma comments, based on the profile defined for the project.
2021-10-13 15:30:10 +01:00
John Vandenberg
af646f42e0 fix mypy error
os.cpu_count can return None.
2021-10-08 18:55:16 +08:00
Christopher Pickering
a657424ed6
closes #60 2021-10-05 13:11:08 +02:00
Christopher Pickering
2a85e0dbb1
fixed #52,50,48 2021-10-05 08:34:35 +02:00
yaegassy
9e2e99f370 chore: adjust docs and help for rule name changes 2021-10-01 16:40:41 +09:00
Christopher Pickering
c3b21323ea
closes #30, closes #28 2021-09-30 10:02:05 +02:00
Christopher Pickering
b00e51488a
closes #29 2021-09-28 13:42:13 +02:00
Christopher Pickering
8f78e1964b
closes #29 2021-09-28 13:04:04 +02:00
Christopher Pickering
a577817b41
fixed stdin check 2021-09-22 08:54:28 +02:00
Matthias Kestenholz
e23dc60ad7 Allowed more than one path at a time 2021-09-21 20:15:25 +02:00
Matthias Kestenholz
abba002433 Fixed #22: Added configuration options to define excluded paths 2021-09-21 13:02:33 +02:00
Christopher Pickering
8b2448644b
updated test 2021-09-20 11:49:31 +02:00
Christopher Pickering
70400fff61
updated for new pylint recommendations 2021-09-17 10:25:01 +02:00
Christopher Pickering
6eeb68c1ff
updated docs, added test, removed pkg_resources 2021-09-17 09:36:52 +02:00
yaegassy
bb9b734287 feat: Add --version option 2021-09-17 08:52:46 +09:00
Christopher Pickering
119cbb5b2b
attemped to fix windows permission issue w/ temp files 2021-09-16 13:47:25 +02:00
Christopher Pickering
78fea8ed4d
added option for stdin. closes #13 2021-09-16 13:36:44 +02:00
Christopher Pickering
94c1dd5958
changed build system to poetry, added more dj tags, added pyproject.toml support, fixed #11, closed #12, closed #1 2021-09-08 10:46:18 +02:00
Christopher Pickering
ba5818a1c7
fixed attribute formatting. fixes #8 2021-08-19 16:36:33 -05:00
Christopher Pickering
dcb1892e00
fixed #6. updated release 2021-08-19 10:16:41 -05:00
Christopher Pickering
4f38370225
fixed rule E001 for handlbars 2021-08-17 10:00:56 -05:00
Christopher Pickering
41e95ce63b
fixed test coverage 2021-08-17 08:56:40 -05:00
Christopher Pickering
582f40b6b1
fixed #5 updated version 2021-08-11 18:34:47 -05:00
Christopher Pickering
c7c0eb8594
changed from dict to tuple 2021-08-11 16:23:15 -05:00
Christopher Pickering
907fd9ad87
fixed lint 2021-08-03 10:03:26 -05:00