question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Is it possible to reference compiled Manifold templates without the IntelliJ plugin?

See original GitHub issue

I’m testing the use of Manifold templates in IntelliJ without the Manifold IntelliJ plugin. After defining a template, and running Gradle build successfully from the command line, IntelliJ is saying that it “Cannot resolve symbol ‘Hello’”). I see the generated class file in build/classes/java/..., but I guess it doesn’t work because there’s no source file placed in generated/sources/annotationProcessor/java/main/...?

If I start using Manifold templates in production, I’ll buy the plugin, but I want to see if I can at least get IntelliJ to be able to reference compiled templates. In open source projects that use Manifold Templates, there are probably use cases where developers need to make changes to a project, they don’t need to edit templates, and all they really want is IntelliJ to not tell them the code is broken.

Maybe I’m missing some IntelliJ setting that would make this work?

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
rsmckinneycommented, Sep 28, 2020

@mtdowling The latest IJ plugin release is free with Ultimate after the trial period, but nags on project load.

0reactions
mtdowlingcommented, Sep 27, 2020

You’re probably right about separating the projects, it just means stuff like code generators probably need like a 3 package layout (e.g., one for shared code, one for templates that uses shared code, and one to actually use the templates).

As for the IntelliJ plugins, I wouldn’t want you to lose a revenue stream. I also wouldn’t want you to have to maintain a separate plugin if it’s a lot of work or maintenance… if you’re already considering this, what about something like making templates free as part of the plugin for Pro users, and other manifold features aren’t available after the trial period (with the option to “not show again” for people just using templates)? Free with a periodic nag works too.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Manifold - IntelliJ IDEA & Android Studio Plugin | Marketplace
Manifold is a Java compiler plugin. It supplements Java with: Direct, type-safe access to: GraphQL schemas, queries, etc. JSON & JSON Schema, YAML,...
Read more >
ManTL (Manifold Template Language)
Templates compile directly in your build as if Java source files without a separate code generation build step, therefore your Java source code...
Read more >
manifold/README.md at master - GitHub
Manifold is a Java compiler plugin, its features include Metaprogramming, Properties, Extension Methods, Operator Overloading, Templates, a Preprocessor, ...
Read more >
Why does IntelliJ give me "Package doesn't exist" error?
Verify that the scope of the library (in the project structure window) is Compile . If set to a scope of Provided it...
Read more >
Manifold is a Java compiler plugin, its features include ...
Manifold is a Java compiler plugin, its features include Metaprogramming, Properties, Extension Methods, Operator Overloading, Templates, a ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found