Skip to content

Ignore these lines #533

Closed
Closed

Description

@russHyde

Is there a way to tell styler not to style a subset of the lines in a file?
I couldn't find anything in the docs or the github issues.

Activity

  1. lorenzwalthert commented on Jul 10, 2019

    @lorenzwalthert
    Collaborator

    Thanks for searching first :-) We decided against this in (agree hard to find) #365 for the reasons outlined there. Note that as far as alignment goes, there are considerations to detect certain patterns and don't apply styling, see #258.

  2. lorenzwalthert commented on Jul 10, 2019

    @lorenzwalthert
    Collaborator

    If you want you can try the version of the WIP for detecting alignment, but no guarantees about future maintenance or further development. https://github.com/lorenzwalthert/styler/tree/detect-alignment. The goal is, however, to once finish this up and merge it into master. You can also subscribe to the other issue to make sure you don't miss anything.

  3. lorenzwalthert commented on Oct 11, 2019

    @lorenzwalthert
    Collaborator

    @russHyde by popular request we think we might anyways implement this feature (although I don't recommend using it) and progress is tracked in #365 if you want to follow up on that.

  4. russHyde commented on Oct 16, 2019

    @russHyde
    Author

    Thanks. It was the introduction of the {{ syntax in rlang (and the expectation that additional syntax might be added that styler wouldn't immediately handle; I appreciate that you've addressed {{ in styler) that spurred me to ask about this. However, I've rethought my process and tried to remove 'weird new syntax' from my packages as much as possible ...

  5. lorenzwalthert commented on Oct 16, 2019

    @lorenzwalthert
    Collaborator

    Ok. Yes, I suppose it would have been helpful for me to know that earlier, I could have pointed you to #528 :-). In almost any problem with styling, there is a general rule we can derive from it and which I am happy to implement (as it is obvious to me we need to handle {{). I'll make a CRAN submission soon as you might have seen in #556 so this should lower the barrieres to use styler again 😄 . In the meanwhile, you can just install from the master branch from GitHub.

  6. lorenzwalthert commented on Oct 22, 2019

    @lorenzwalthert
    Collaborator

    We have a draft :-). Feedback welcome, please in the PR (#560), not here in the issue.

    remotes::install_github("lorenzwalthert/styler@stylerignore")
  7. lorenzwalthert commented on Nov 30, 2019

    @lorenzwalthert
    Collaborator

    Closed with #560.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions