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

Create a standalone binary artifact #326

Closed
clementdessoude opened this issue Dec 10, 2019 · 6 comments · Fixed by #399
Closed

Create a standalone binary artifact #326

clementdessoude opened this issue Dec 10, 2019 · 6 comments · Fixed by #399

Comments

@clementdessoude
Copy link
Contributor

I would be awesome to provide a standalone artifact to run Prettier for Java in an ecosystem without node/npm

See #317

@bd82
Copy link
Contributor

bd82 commented Dec 10, 2019

Perhaps with https://github.com/zeit/pkg

@Shaolans
Copy link
Member

I tested pkg to create a binary of prettier-java and it seems to be working !
I think we can add binaries at each release, btw @clementdessoude are the release automated ?

@bd82
Copy link
Contributor

bd82 commented May 1, 2020

You could evaluate GHR for automating binary upload to github releases.

I use it here: https://github.com/SAP/xml-tools/blob/master/.circleci/config.yml#L65-L68

@clementdessoude
Copy link
Contributor Author

Great news @Shaolans ! For the moment, release are not automated. Do you have a script to create the binary executable? If so, I can execute it this afternoon or tomorrow and make a release

@Shaolans
Copy link
Member

Shaolans commented May 2, 2020

I was just testing and I have not made a script but I done the following:
It might not be simple as running pkg on the repository since this is a prettier plugin.

  • Clone https://github.com/prettier/prettier
  • Checkout to the 2.0.0 (the one prettier-java use)
  • npm install prettier-plugin-java (in our case we should link to the one we release)
  • run pkg
    It will create 3 binary by default: linux, macos and windows but this is surely customizable.

@Shaolans
Copy link
Member

Shaolans commented May 2, 2020

Since we have now migrated to github actions, there is an interesting action here to upload binaries on publish https://github.com/marketplace/actions/github-action-publish-binaries

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants