Skip to content

Latest commit

 

History

History
813 lines (487 loc) · 24.5 KB

CHANGELOG.md

File metadata and controls

813 lines (487 loc) · 24.5 KB

Changelog

Unreleased

Additions

Changes

Deletions

7.0.0

This is the first release that supports the 0.14.0 compiler and its syntactical changes.

Overall, not much has changed. The new syntactic constructs are kind signatures and roles. Kind signatures are formatted like type signatures. Roles are are all on a single line for now.

This release will likely still work for most 0.13.x code. Though there's no explicit support for the 0.13.x series at the moment. The breaking changes are for some edge cases that it doesn't seem like many would run into, but they're breaking for a reason.

Additions

Changes

Deletions

6.3.1

This is a small release with all internal-facing changes.

This is mostly updating dependencies and fixing some CI issues. There should be no behavioral change from the previous version.

Additions

Changes

Deletions

6.3.0

This is a small release to address the formatting of nested conditionals.

Additions

Changes

Deletions

6.2.1

This is a small release with internal project changes.

Additions

Changes

Deletions

6.2.0

This is a bug fix release to address a long standing bug.

Trailing comments in a module have been formatted incorrectly since 4.0.0. It was largely tangled up in all trailing comments being formatted incorrectly since 4.0.0. We took some time to dig in further and found a way to address at least this one part.

Additions

Changes

Deletions

6.1.3

Another small release. More internal project changes.

Additions

Changes

Deletions

6.1.2

Another small release. This should all be internal project changes.

Additions

Changes

Deletions

6.1.1

Another small release. This should all be internal project changes related to using bazel as the bulk of the build system.

Additions

Changes

Deletions

6.1.0

This is a small release to fix an oddity of formatting.

Additions

Changes

Deletions

6.0.2

This is a bugfix due to recent changes. We were accidentally dropping code coverage information whenever purty was run. That should be taken care of, now.

Additions

Changes

Deletions

6.0.1

This release is all internal project changes.

Additions

Changes

Deletions

6.0.0

This release smooths out some rough edges.

First, we added a version mode so you can know which version of purty you're using. It's pretty impressive tha we went this long without it, but it wasn't intentional. In any case, by default it outputs a verbose, human-readable version information. There is also a --numeric flag if you need a more machine-friendly version.

Next, we added a validate mode so you can check whether a file is formatted correctly. This mode is useful for using purty as a lint step. We hope to expand this mode with more useful output (like a diff of what's unformatted).

Finally, we added a format mode so you can format a file or directory. This works exactly like using purty without the format mode. I.e. purty foo is exactly the same as purty format foo.

Because these two new modes–validate and version–act as commands on the purty binary, it's entirely possible that they might shadow existing files or directories that would have been formatted before. E.g. if you had a directory named version with PureScript files in it, it would no longer be formatted when you said purty version --write. To address this breaking change, we added a format mode to bring back the ability to format any file or directory shadowed by a mode the purty binary uses. This even works if there's a file or directory named format you'd like to format: purty format format.

Additions

Changes

Deletions

5.0.1

This is a smaller release. All of the changes here should be internal to the project.

Additions

Changes

Deletions

5.0.0

This is a big one! There are three important differences from previous verions of `purty:

  1. Configuration files are no longer supported. The configuration never panned out how it was supposed to. It was never meant to be for altering formatting, but for configuring the CLI. It was also meant to be an example of using Dhall.

  2. Binaries are statically linked. The binaries we were creating up until now have been dynamically linked. We were privvy to the same issues that the PureScript compiler runs into from time to time (runtime libraries not existing). We decide to link binaries statically, so we can mitigate runtime issues. We also can do more interesting things (like creating minimal Docker images) with statically linked binaries.

  3. Directories are supported. If you've used purty on any non-trivial codebase, you've probably run into an issue with trying to format multiple files. Up until now, you've had to script your own way to run all of these files. Depending on how you run purty, this could be a slow and tedious process. Now we support formatting all .purs recursively in a directory. This should make it easier to use purty in larger projects.

There were some other minor changes for dependencies in this release as well.

Additions

Changes

Deletions

4.6.0

There's been a process change. We're not accepting external merge requests for the time being.

This decision has been a long time coming, and it's almost entirely an internally motivated change. This long and short is that I'm burned out from open source work, and would like to try a different approach to developing this project. There's more details in the issue.

In other news, we've got a couple of small fixes to formatting.

Additions

Changes

Deletions

4.5.2

We've started working on the emacs integration. So far, there's a elisp file that allows formatting on save. In the coming releases, we hope to make installing and using it easier.

We're not officially supporting the emacs integration, but we're starting work on it!

Additions

Changes

Deletions

4.5.1

Mostly infrastructure changes. There should be no breaking changes or formatting changes in this version

Additions

Changes

Deletions

4.5.0

A couple of formatting changes and a bit of documentation. The formatting changes should make the output a bit more compatible with compilers older than 0.13.0.

Additions

Changes

Deletions

4.4.2

A bug fix for the formatting of unicode and escape characters.

Additions

Changes

Deletions

4.4.1

A bug fix for the formatting of multi-line renamed imports.

Additions

Changes

Deletions

4.4.0

A fix to the formatting of type annotations.

Additions

Changes

Deletions

4.3.0

A fix to the formatting of parenthesized expressions.

Additions

Changes

Deletions

4.2.0

Small change to display the file name when reporting errors.

Additions

Changes

Deletions

4.1.1

Quick bug fix to get STDIN working over the npm interface.

Additions

Changes

Deletions

4.1.0

Some cleanup to formatting. Thanks for all the feedback from the last big release.

We also add support for reading over STDIN. If the binary is invoked with -, it will read data over STDIN instead of expecting a file. E.g. purty - will read input over STDIN. Hopefully, this is useful for other tools and integrations to use.

Additions

Changes

Deletions

4.0.1

A quick bug fix for formatting string literals.

Additions

Changes

Deletions

4.0.0

First release in a while. We've moved over to interactive formatting!

We're now based off of the 0.13.x version of the purescript package. That means we've got a parser that gives us as close to source code as possible. Using the newer version, we can format a module much more carefully.

Interactive formatting is something that elm-format does. It's not clear if there's an official name for it. It could also be called VonderHaar-style formatting (after the author of elm-format). The way it works is by taking hints from the structure of the file to direct the formatting. If you have some syntactic construct that could be put on one line, and there are no line breaks in the construct, purty will format it on one line. If you have some syntactic construct that could be put on one line, and there is at least one line break in the construct, purty will format the entire construct as multiple lines. The formatting does not reach beneath the construct but may reach above it.

For example:

foo = [[1, 2, 3], [4,
  5, 6, 7]]

would be formatted as:

foo =
  [ [1, 2, 3]
  , [ 4
    , 5
    , 6
    , 7
    ]
  ]

The array [1, 2, 3] was formatted on a single line, since it was initially all on one line. The array [4, 5, 6, 7] was formatted over multiple lines, as it had at least one line break. Finally, the overall array [[1, 2, 3], [4, 5, 6, 7]] was formatted over multiple lines, as it also had at least one line break.

The long and short of the changes here are that the control of formatting is given more to the author of the code. This should still keep with the idea of formatting that works nicely, but it should also give a bit of freedom to people to structure the code a little bit differently if need be.

Bear in mind, almost all of the code is re-written so it's likely to contain a new set of bugs. Please feel free to report any bugs you find.

Additions

Changes

Deletions

3.0.7

Re-publishing to npm. There was a problem with the previous version.

There shouldn't be any changes with purty itself.

Additions

Changes

Deletions

3.0.6

Internal code cleanup. There shouldn't be any changes with purty itself.

Additions

Changes

Deletions

3.0.5

Patch release with a bug fix.

Additions

Changes

Deletions

3.0.4

Patch release with bug fixes.

Additions

Changes

Deletions

3.0.3

Patch release with CI changes.

Additions

Changes

Deletions

3.0.2

Squashing another boug from 3.0.0 changes.

This one was record puns not being formatted correctly. There were also some infrastructure changes.

Additions

Changes

Deletions

3.0.1

Those huge changes from 3.0.0 contained a few bugs :).

This is a quick patch release to address them. If there are more, please report them!

Additions

Changes

Deletions

3.0.0

Huge changes to the internals. We've got our own AST! Now, we can format things a bit purty-er.

It's already made some things easier and removed some bugs with the formatting. It should make other formatting easier and also will make implementing interactive formatting much easier.

Additions

Changes

Deletions

2.0.1

Internal changes to the code base. Feature-wise, everything should be the same.

Additions

Changes

Deletions

2.0.0

Lots more bug fixes.

Thanks to everyone who reported them. Keep 'em coming!

Additions

Changes

Deletions

1.0.1

Minor bug fix.

A fix for boolean literals.

Additions

Changes

Deletions

1.0.0

Official release

It's finally here! The 1.0.0 release!

Let's talk about what 1.0.0 doesn't mean: purty is now "done," purty has now become "stable," purty is now "production ready," purty generates "nice looking code."

  • purty will probably never be "done." A project like this is almost never "done." There will always be some improvement to make, a bug to fix, or a syntax to update. Just as languages continue to evolve, so do do styles of those languages.
  • purty will not be stable for quite some time. There are many new features in the future and most of these will alter the way modules are formatted.
  • purty has been "production ready" since about the 0.3.0 or 0.4.0 release. There are still bugs, there are still improvements to make for the formatting. But, running purty should not "eat your code", change the semantics of a module, or break in an otherwise bad way.
  • Generating "nice looking code" is entirely subjective. There's probably a consensus around what most people would consider nice, but there's no way to put a stamp on things and say purty generates "nice looking code."

1.0.0 is only the beginning. purty does enough now to be "useful." It's no longer a proof of concept, it's a useful tool. It will still have bugs, they will still get fixed. It will still have improvements.

This version also supports PureScript 0.12.0. It should be backwards compatible with PureScript 0.11.7, but there are no guarantees.

Additions

Changes

Deletions

0.6.0

Tiny release

One small addition for configuration.

Additions

Changes

Deletions

0.5.0

Small bug fixes

Not much happened in this release. There were a couple of bug fixes and a change to import sorting.

Additions

Changes

Deletions

0.4.0

Configuration and customization

This release had only a few additions, but they were big!

The first allows selecting between dynamic and static printing. Dynamic printing is what most people think of when they think of a pretty printer. Static printing is similar to how gofmt and similar tools work.

The second allows configuring purty with a file instead of command line arguments. That should allow for more reproducability and ease of use in the future. We're using Dhall as the configuration language because it should make working with the file easier in the long run.

Additions

Changes

Deletions

0.3.0

Bug fixes and small features

Most of what happened in this release were bug fixes after being used in a real project.

Additions

Changes

Deletions

0.2.0

Infrastructure changes

Most of this release was around making the infrastructure of creating purty. We had a few features and fixes, but mostly infrastructure.

Additions

Changes

Deletions

0.1.0

Initial release

Additions

Changes

Deletions