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

Embed local imports and cached remote imports into binary #32

Merged
merged 2 commits into from
Sep 28, 2020

Conversation

mumoshu
Copy link
Owner

@mumoshu mumoshu commented Sep 27, 2020

variant export binary should now emit a binary containing all the local imports and cached remote imports in it.

Under the hood, it uses statik for embedding all the files present in the source directory and the cached remote imports.

All the remote imports are resolved and cached to $TEMPDIR/.variant2/cache on running variant export binary. It's like what happen when you run variant run, but the cache is persisted in the temporary directory that contains the exported Go project tree with all the embedded files.

Note that variant export binary uses variant export go internally so the latter command is affected as well.

Resolves #28

@mumoshu mumoshu merged commit c9a9541 into master Sep 28, 2020
@mumoshu mumoshu deleted the embed-imports branch September 28, 2020 01:55
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 this pull request may close these issues.

Feature Request: variant export binary should bundle modules
1 participant