April 10–16, 2022 in Darker: Enhancing syntax highlighting and import sorting #682
akaihola
announced in
Announcements
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Summer season was pretty quiet for Darker, but we did make significant improvements to Darker's syntax highlighting capabilities and addressed long-standing issues with import sorting. We merged a pull request (#356) that adds support for the
NO_COLOR
environment variable, complementing the previously addedPY_COLORS
option. This change allows users to disable syntax highlighting by settingNO_COLOR
to any non-empty value, which can be overridden byPY_COLORS=1
or the--color
command line option.We also resolved a long-standing issue (#72) related to import sorting. The newly implemented feature (#238) ensures that isort is only applied when changes overlap with user modifications. This approach prevents unnecessary import sorting and addresses the problem of imports being sorted even when they were not edited. Additionally, we updated our GitHub Actions workflow (#357) to fix macOS build errors by updating the
cachix/install-nix-action
tov17
and downgrading to Python 3.9 for macOS Nix builds.In other developments, we continued to refine our configuration options. We merged a pull request (#359) that allows Darker to read its configuration from the file specified using
-c
/--config
, reverting to previous behavior. This change partially addresses the issue of Darker's configuration in monorepo structures (#244). These improvements, along with various documentation updates and bug fixes, bring us closer to the upcoming 1.5.0 release.Beta Was this translation helpful? Give feedback.
All reactions