You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to compile my rocket program into a single binary, so that it is easier to distribute. Since I use tera templates, I tried using Templates::custom so that I can add the templates with include_str! during compile time. Following this example, I was able to get the template working from a string, but it would not run unless template_dir existed. It works even if I create an empty templates directory. I think this shouldn't be a requirement unless external template files are being used, and now I'm unable to make the standalone binary work.
The code would run without a templates directory because I'm not using any external templates
Environment:
OS Distribution and Kernel: Artix Linux, 5.13.12-artix1-1
Rocket Version: 0.5.0-rc.1
Additional Context
I tried setting template_dir to ., which is a kinda hacky solution but worked. But that seems to be a runtime config setting, so I wasn't able to use it to make the single file binary.
The text was updated successfully, but these errors were encountered:
Description
I want to compile my rocket program into a single binary, so that it is easier to distribute. Since I use tera templates, I tried using
Templates::custom
so that I can add the templates withinclude_str!
during compile time. Following this example, I was able to get the template working from a string, but it would not run unlesstemplate_dir
existed. It works even if I create an emptytemplates
directory. I think this shouldn't be a requirement unless external template files are being used, and now I'm unable to make the standalone binary work.To Reproduce
Expected Behavior
The code would run without a
templates
directory because I'm not using any external templatesEnvironment:
Additional Context
I tried setting
template_dir
to.
, which is a kinda hacky solution but worked. But that seems to be a runtime config setting, so I wasn't able to use it to make the single file binary.The text was updated successfully, but these errors were encountered: