Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update rewrite to 1.0.0 #103

Merged
merged 3 commits into from
Nov 4, 2024
Merged

Conversation

NickNeck
Copy link
Contributor

@NickNeck NickNeck commented Nov 1, 2024

Hi @zachallaun

I have released a new version of rewrite and it comes with a bunch of breaking changes and a better handling of source formatting.

This PR contains all the changes needed for meneme:

  • The rewrite project now gets a %DotFormatter{} to format the code.
  • The resync_quoted: false prevents the AST from being changed when the source is updated with :quoted. I think this makes the Source.put_private(:patched_ast, ast) obsolete.
  • The TextDiff module has been moved to its own package.

For now we have a little conflict with igniter and for that we need {:rewrite, "~> 1.0", override: true}. The override: true can be removed once igniter also uses rewrite 1.0.0. A PR (ash-project/igniter#135) is already created merged in the igniter repo.

Have a nice weekend.

@zachallaun
Copy link
Owner

Thank you so much for doing the legwork on this!

It looks like the Igniter PR has already been merged, so I'll wait until that's out in a release and then upgrade that to solve for the override workaround.

@zachallaun
Copy link
Owner

@NickNeck If you don't mind, do you have a moment to take a look at this when you bump Rewrite to 1.0.1? With that version, the PR as it is now fails to format locals_without_parens in the integration tests. I know there were some changes to that and thought you might know off-hand what's going on. :)

@NickNeck
Copy link
Contributor Author

NickNeck commented Nov 4, 2024

I will take a look.

@zachallaun
Copy link
Owner

Thank you for updating this! Will get it merged shortly :)

@zachallaun zachallaun merged commit d80f3a1 into zachallaun:main Nov 4, 2024
13 of 14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants