Skip to content

Commit

Permalink
Merge pull request #886 from tgodzik/add-release-notes
Browse files Browse the repository at this point in the history
Add release notes for v0.7.2
  • Loading branch information
tgodzik committed Sep 2, 2019
2 parents 75f7b60 + f2ffed1 commit 8d56426
Show file tree
Hide file tree
Showing 5 changed files with 343 additions and 1 deletion.
32 changes: 32 additions & 0 deletions bin/merged_prs.py
@@ -0,0 +1,32 @@
from github import Github
import subprocess
import re

PIPE = subprocess.PIPE

gh = Github()

# Needed data
first_tag = "v0.7.0"
last_tag = "v0.7.2"

# Running
org = gh.get_organization('scalameta')
repo = org.get_repo('metals')

tag_range = "%s..%s" % (first_tag, last_tag)
command = ['git', 'log', tag_range, "--merges", "--first-parent", "master", "--pretty=format:\"%s\""]
process = subprocess.Popen(command, stdout=PIPE, stderr=PIPE)
stdoutput, stderroutput = process.communicate()

all_prs = []
for line in stdoutput.split("\n"):
pr_num = re.findall("#\d+", line)
all_prs.append(int(pr_num[0][1:]))

for pr in all_prs:
pull = repo.get_pull(pr)
print ("- %s" % pull.title)
print ("[\#%s](%s)" % (pull.number, pull.url))
print ("([%s](https://github.com/%s))" % (pull.user.login, pull.user.login))

2 changes: 1 addition & 1 deletion build.sbt
@@ -1,4 +1,4 @@
def localSnapshotVersion = "0.7.1-SNAPSHOT"
def localSnapshotVersion = "0.7.3-SNAPSHOT"
def isCI = System.getenv("CI") != null

def crossSetting[A](
Expand Down
3 changes: 3 additions & 0 deletions docs/contributors/releasing.md
Expand Up @@ -33,6 +33,9 @@ title: Making a release
- While waiting for Travis, draft the release notes:

- Copy `website/blog/2018-12-06-iron.md` as a template
- You might use `.bin/release_notes.py` script to generate merged PRs list. It
requires the official Github library (`pip install PyGithub`) and you will
also need to fill in tag names.
- Open a PR to the repo
- https://github.com/scalameta/metals/releases/new.

Expand Down
13 changes: 13 additions & 0 deletions docs/editors/vscode.md
Expand Up @@ -123,6 +123,19 @@ without opening the sidebar.
As you type, the symbol outline is also visible at the top of the file.
![Document Symbols Outline](https://i.imgur.com/L217n4q.png)

## Enable onTypeFormatting for multiline string formatting

![pipes](https://i.imgur.com/iXGYOf0.gif)

To properly support adding `|` in multiline strings we are using the
`onTypeFormatting` method. To enable the functionality you need to enable
`onTypeFormatting` inside Visual Studio Code.

This needs to be done in settings by checking
`Editor: Format On Type`:

![on-type](https://i.imgur.com/4eVvSP5.gif)

## Coming from IntelliJ

Install the
Expand Down
294 changes: 294 additions & 0 deletions website/blog/2019-09-02-thorium.md
@@ -0,0 +1,294 @@
---
author: Tomasz Godzik
title: Metals v0.7.2 - Thorium
authorURL: https://twitter.com/TomekGodzik
authorImageURL: https://github.com/tgodzik.png
---

We are excited to announce the release of Metals v0.7.2 - codename "Thorium" 🎉
The release includes mostly bug fixes with some smaller new features. We are
skipping over 0.7.1 due to a critical bug we discovered

Metals is a language server for Scala that works with VS Code, Atom, Vim,
Sublime Text and Emacs. Metals is developed at the
[Scala Center](https://scala.epfl.ch/) and [VirtusLab](https://virtuslab.com)
along with contributors from the community.

In this release we merged 39 PRs and closed 11 issues, full details:
https://github.com/scalameta/metals/milestone/12?closed=1

## TL;DR

Check out the website and give Metals a try: https://scalameta.org/metals/

- support for Scala 2.12.9
- fix completions in case of inline comments
- add support for non-directory sources
- automatically add package definition to new source files
- automatically insert pipes in multiline string
- a lot of miscellaneous fixes

## Fix completions in case of inline comments

Previously, completions after a comment and newline would yield no results:

```scala
val List(1,2,3)
.map(num => num + 1) // comment
@@
```

This was fixed by the Metals team in the presentation compiler itself for 2.12.9
and 2.13.1, however we also added a workaround for all supported older Scala
versions.

## Add support for non-directory sources

In case that your build tool supports having single files as sources, we now
offer full support for them. That corresponds to the most recent BSP
specification
[request](https://github.com/scalacenter/bsp/blob/master/docs/bsp.md#build-target-sources-request)

## Automatically add package definition to new source files

For every new Scala file we automatically add package definition based on the
relative path between the new source file and source root. This is done using
applyWorkspaceEdit method, which causes the change to be done in editor and this
can easily be rewerted like any other change you would type.

![add-package](https://i.imgur.com/6V9gHnM.gif)

We also added support for package objects. Whenever you create `package.scala`
file, we will automatically create the barebone definition of the package
object.

![package-object](https://i.imgur.com/CfF0cdE.gif)

There is still some work to be done about moving files between packages, which
will be addressed in the next release.

Big thanks to the first time contributor from VirtusLab Tomasz Dudzik for
implementing most of the functionality! 🎉

## Automatically insert pipes in multiline string

We finally managed to properly support adding `|` in multiline strings using the
`onTypeFormatting` method. Previous implementation was very naive and often
added pipes in wrong places.

![pipes](https://i.imgur.com/iXGYOf0.gif)

To enable the functionality you need to enable `onTypeFormatting` inside your
editor if it's not enabled by default.

In Visual Studio Code this needs to be done in settings by checking
`Editor: Format On Type`:

![on-type](https://i.imgur.com/4eVvSP5.gif)

You will also need the newest version of the Visual Studio Code plugin.

There is still some possible improvements in case of copy pasting entire text
fragments, but that needs some more work.

Big thanks to another of our first time contributors from VirtusLab Karolina
Bogacka! Great work! 🎉

## Add support for Scala 2.12.9

Metals now supports Scala 2.12.9! No new Scala version has been deprecated in
this release, since it is possible that Scala 2.12.10 version with some
important fixes will be released soon.

Big thanks to [@gabro](https://github.com/gabro) for again leading the effort!
This took considerably more time and effort than expected.

## Miscellaneous fixes

- erroneous warning for Scala 2.11 is no longer displayed
- don't infer build target for non-readonly files
- fix several small issues in the tree view protocol spec
- set h2.bindAddress to avoid exposing open ports (thanks @blast-hardcheese!)
- resolve symlinks that are used within workspaces
- fix issues when import was requested multiple times without any change
- detect openjdk as a valid jdk home
- warn when java sources were not found
- string interpolation completions now work properly in multiline string
- add ReloadDoctor to the list of all commands (thanks @kurnevsky!)
- add correct mill version in the predef script when running `bloopInstall`
- SemanticDB plugin issues are no longer reported in java only projects
- check if SeamnticDB really exists and only report issue when it doesn't
- update default scalafmt to 2.0.1
- use recommended version for build tools in UI message
- fix file leak when importing large Gradle workspaces

## Contributors

Big thanks to everybody who contributed to this release, a lot more people
joined this time to make the release better!

```
$ git shortlog -sn --no-merges v0.7.0..v0.7.2
Gabriele Petronella
Tomasz Godzik
Ólafur Páll Geirsson
Evgeny Kurnevsky
Marek Żarnowski
Lucas Satabin
Ayoub Benali
Chris Birchall
Compro Prasad
Devon Stewart
Jesús Martínez
Karolina Bogacka
Tomasz Dudzik
Chris Kipp
Rikito Taniguchi
```

## Merged PRs

## [v0.7.2](https://github.com/scalameta/metals/tree/v0.7.2) (2019-08-29)

[Full Changelog](https://github.com/scalameta/metals/compare/v0.7.0...v0.7.2)

**Merged pull requests:**

- Fix not closing streams when using Files.list
[\#892](https://api.github.com/repos/scalameta/metals/pulls/892)
([tgodzik](https://github.com/tgodzik))
- Avoid file leaks when digesting Gradle builds
[\#889](https://api.github.com/repos/scalameta/metals/pulls/889)
([olafurpg](https://github.com/olafurpg))
- Fix broken tests
[\#888](https://api.github.com/repos/scalameta/metals/pulls/888)
([olafurpg](https://github.com/olafurpg))
- Bump Metals Scala version to 2.12.9
[\#887](https://api.github.com/repos/scalameta/metals/pulls/887)
([tgodzik](https://github.com/tgodzik))
- Add check mark for formatting under vim
[\#885](https://api.github.com/repos/scalameta/metals/pulls/885)
([satabin](https://github.com/satabin))
- Recommend a recent version of the build tool when incompatible or unknown
[\#881](https://api.github.com/repos/scalameta/metals/pulls/881)
([gabro](https://github.com/gabro))
- Use BuildInfo.scalaCompilerVersion over Properties.versionNumberString
[\#876](https://api.github.com/repos/scalameta/metals/pulls/876)
([olafurpg](https://github.com/olafurpg))
- Remove use of early intializers
[\#877](https://api.github.com/repos/scalameta/metals/pulls/877)
([gabro](https://github.com/gabro))
- Catch ShutdownReq exception from stopping a presentation compiler.
[\#873](https://api.github.com/repos/scalameta/metals/pulls/873)
([olafurpg](https://github.com/olafurpg))
- Transpose features/editors table
[\#875](https://api.github.com/repos/scalameta/metals/pulls/875)
([gabro](https://github.com/gabro))
- Make presentation compiler work on 2.12.9
[\#872](https://api.github.com/repos/scalameta/metals/pulls/872)
([gabro](https://github.com/gabro))
- Scala 2.12.9 support
[\#867](https://api.github.com/repos/scalameta/metals/pulls/867)
([gabro](https://github.com/gabro))
- Automatically add package objects when creating package.scala file
[\#866](https://api.github.com/repos/scalameta/metals/pulls/866)
([tgodzik](https://github.com/tgodzik))
- Automatically add package declaration when creating a file
[\#862](https://api.github.com/repos/scalameta/metals/pulls/862)
([tdudzik](https://github.com/tdudzik))
- Fix TreeViewSlowSuite tests
[\#864](https://api.github.com/repos/scalameta/metals/pulls/864)
([gabro](https://github.com/gabro))
- Update scalafmt to 2.0.1
[\#863](https://api.github.com/repos/scalameta/metals/pulls/863)
([tanishiking](https://github.com/tanishiking))
- Add support for non-directory sources
[\#857](https://api.github.com/repos/scalameta/metals/pulls/857)
([tgodzik](https://github.com/tgodzik))
- Report an issue only if SemanticDB file doesn't really exist.
[\#853](https://api.github.com/repos/scalameta/metals/pulls/853)
([tgodzik](https://github.com/tgodzik))
- Do not report issues in Java only projects
[\#850](https://api.github.com/repos/scalameta/metals/pulls/850)
([tgodzik](https://github.com/tgodzik))
- Emacs supports client commands now
[\#848](https://api.github.com/repos/scalameta/metals/pulls/848)
([kurnevsky](https://github.com/kurnevsky))
- Fix issue if exact query is longer than the class name
[\#843](https://api.github.com/repos/scalameta/metals/pulls/843)
([tgodzik](https://github.com/tgodzik))
- Fix issue with wrong mill version in predef script and update millw scripts
[\#842](https://api.github.com/repos/scalameta/metals/pulls/842)
([tgodzik](https://github.com/tgodzik))
- Fix Mercury blog post date by adding an unlisted redirect
[\#836](https://api.github.com/repos/scalameta/metals/pulls/836)
([gabro](https://github.com/gabro))
- Update sublime doc regarding autoimport
[\#839](https://api.github.com/repos/scalameta/metals/pulls/839)
([ayoub-benali](https://github.com/ayoub-benali))
- Improve handling of the java sources
[\#825](https://api.github.com/repos/scalameta/metals/pulls/825)
([marek1840](https://github.com/marek1840))
- Add exact libraries that are expected and fix the test
[\#837](https://api.github.com/repos/scalameta/metals/pulls/837)
([tgodzik](https://github.com/tgodzik))
- Add ReloadDoctor to the list of all commands.
[\#830](https://api.github.com/repos/scalameta/metals/pulls/830)
([kurnevsky](https://github.com/kurnevsky))
- Install use-package if not already installed
[\#828](https://api.github.com/repos/scalameta/metals/pulls/828)
([Compro-Prasad](https://github.com/Compro-Prasad))
- Fix multiline edits
[\#826](https://api.github.com/repos/scalameta/metals/pulls/826)
([tgodzik](https://github.com/tgodzik))
- Timestamps should use currentTimeMillis
[\#822](https://api.github.com/repos/scalameta/metals/pulls/822)
([tgodzik](https://github.com/tgodzik))
- resolve symlinks from client requests
[\#824](https://api.github.com/repos/scalameta/metals/pulls/824)
([marek1840](https://github.com/marek1840))
- Setting h2.bindAddress to avoid exposing open ports
[\#821](https://api.github.com/repos/scalameta/metals/pulls/821)
([blast-hardcheese](https://github.com/blast-hardcheese))
- Use Scalafmt 2.0.0 when setting the version in .scalafmt.conf
[\#806](https://api.github.com/repos/scalameta/metals/pulls/806)
([gabro](https://github.com/gabro))
- Don't infer build target for non-readonly files.
[\#810](https://api.github.com/repos/scalameta/metals/pulls/810)
([olafurpg](https://github.com/olafurpg))
- Fix versions in docs - wrong number of @ was used
[\#820](https://api.github.com/repos/scalameta/metals/pulls/820)
([tgodzik](https://github.com/tgodzik))
- Update the list of supported Scala binary versions
[\#818](https://api.github.com/repos/scalameta/metals/pulls/818)
([cb372](https://github.com/cb372))
- Bump mill version
[\#817](https://api.github.com/repos/scalameta/metals/pulls/817)
([satabin](https://github.com/satabin))
- Send treeViewDidChange only when the client supports it
[\#816](https://api.github.com/repos/scalameta/metals/pulls/816)
([kurnevsky](https://github.com/kurnevsky))
- Fix issue with missing completions after comment and newline.
[\#814](https://api.github.com/repos/scalameta/metals/pulls/814)
([tgodzik](https://github.com/tgodzik))
- Fix several issues in the tree view protocol spec
[\#811](https://api.github.com/repos/scalameta/metals/pulls/811)
([olafurpg](https://github.com/olafurpg))
- Make test-release.sh script check that artifacts have synced to Maven
[\#812](https://api.github.com/repos/scalameta/metals/pulls/812)
([olafurpg](https://github.com/olafurpg))
- nvim version and updated info about required java versions
[\#807](https://api.github.com/repos/scalameta/metals/pulls/807)
([ckipp01](https://github.com/ckipp01))
- Lost a word in the last PR and adding it now
[\#805](https://api.github.com/repos/scalameta/metals/pulls/805)
([tgodzik](https://github.com/tgodzik))
- Use sonatype:public in our own meta build
[\#803](https://api.github.com/repos/scalameta/metals/pulls/803)
([gabro](https://github.com/gabro))
- Fix an issue with wrong deprecation warning for 2.11 and update snapshot
version [\#804](https://api.github.com/repos/scalameta/metals/pulls/804)
([tgodzik](https://github.com/tgodzik))
- Fix version typo
[\#802](https://api.github.com/repos/scalameta/metals/pulls/802)
([JesusMtnez](https://github.com/JesusMtnez))

0 comments on commit 8d56426

Please sign in to comment.