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

Feature: Support scala-cli style directives such as //> using #603

Open
SethTisue opened this issue Apr 5, 2022 · 10 comments
Open

Feature: Support scala-cli style directives such as //> using #603

SethTisue opened this issue Apr 5, 2022 · 10 comments

Comments

@SethTisue
Copy link
Contributor

SethTisue commented Apr 5, 2022

I'd love to be able to just paste a scala-cli script into Scastie and have it recognize //> using scala ... (to set Scala version) and //> using option ... (to set compiler flags) and //> using dep ... to add dependencies, so I could easily move back and forth between the tools (Scastie and scala-cli)

@SethTisue SethTisue changed the title Support scala-cli style directives such as //> using Feature: Support scala-cli style directives such as //> using Apr 5, 2022
@bjornregnell
Copy link

This would indeed be cool! Meanwhile, as a workaround, you can use

scala-cli export . --sbt --output ../some-new-dir 

to get a build definition to paste into scasties Build Settings

@julienrf
Copy link
Contributor

julienrf commented Jul 6, 2022

Thank you for the suggestion! Once the specification for configuration directives is settled, we could consider working on this issue. One challenge is that currently we assume an sbt build by default. So, there should be an additional setting in “build settings” to switch between scala-cli based snippets and sbt based snippets.

@SethTisue
Copy link
Contributor Author

SethTisue commented Jul 6, 2022

perhaps Scastie only actually needs to support scala-cli based snippets? how much benefit is there from continuing to support the sbt style?

@julienrf
Copy link
Contributor

Feature-wise, there is no need to continue using sbt. Everything we use sbt for, we will be able to use scala-cli instead.

That being said, we may want to still support sbt because we want the existing snippets to still work.

@SethTisue
Copy link
Contributor Author

Julien mentioned at the Scala Center's advisory board meeting today that work on this is happening at the Center.

@tgodzik
Copy link
Contributor

tgodzik commented Apr 27, 2023

Important side note: I am streamlining the using directives and I am almost finished. I will release 1.0.0 version as soon as I finish

@SethTisue
Copy link
Contributor Author

I believe @bishabosha just said this is still being worked on

@rochala
Copy link
Collaborator

rochala commented Sep 16, 2023

I'll try my best to merge it during the next week.

@mpilquist
Copy link

#919 was closed in favor of #997, which is still pending. Any update on when this feature will be available on the public Scastie instance?

@rochala
Copy link
Collaborator

rochala commented Apr 17, 2024

This is a very tough one. We've had a bit of different priorities, mostly in Scala 3 compiler repository, that took precedence over finishing this PR.

I can't tell you the exact date, but hopefully it will happen soon (at least I'll try to find some time and finish this).

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 a pull request may close this issue.

6 participants