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

JBang Scripts Inside a Maven Project #95

Open
aghasemi opened this issue Oct 18, 2023 · 2 comments
Open

JBang Scripts Inside a Maven Project #95

aghasemi opened this issue Oct 18, 2023 · 2 comments

Comments

@aghasemi
Copy link

Hi,

I have a typical maven project that I can open and edit in IntelliJ. In this project, I have some utility scripts to e.g. upload files to a remote directory etc..

The problem is that the JBang IntelliJ plugin does not work with these individual scripts inside a Maven project: Dependencies added via //DEPS are not recognised, and autocomplete does not work unless I move the script to the project source directory (src/main/java - and then only for dependencies added in project's pom.xml).

Can the plugin handle such a situation, or I have to open scripts in a parallel IDE?

Thanks

@maxandersen
Copy link
Contributor

They currently need to be in a sources directory. You can mark the folder they are in as one and it should work.

I agree it's not optimal and we should see if the classpath could be scope
To just apply to the nearest sources dir instead of globally.

@aghasemi
Copy link
Author

I see. Thanks for the clarification. Then I also need to replicate the dependencies between the Jbang script and the POM file of the main project, but it's ok.

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

No branches or pull requests

2 participants