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

Replace go-bindata with //go:embed and upgrade to go 1.18 #430

Closed
wants to merge 7 commits into from

Conversation

kinghrothgar
Copy link
Contributor

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe:

The PR fulfills these requirements:

  • All tests are passing?
  • New/updated tests are included?
  • If any static assets have been updated, has ui/bindata.go been regenerated?
  • Are there doc blocks for functions that I updated/created?

If adding a new feature, the PR's description includes:

  • A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)

Other information:
This is an attempt to revive this PR #392. As it as sat for a long time, there are new versions of go available. This PR does the following:

  • Depends on this PR as a newer version of alpine is needed that has go 1.18
  • Updates go.mod, README, and CI to use go 1.18
  • Drop unsupported go 1.14 from CI
  • Switches from go-bindata to stdlib embed package
  • Ran a make node_modules with the latest version of npm (8.13.2) which updated the package-lock.json

@kinghrothgar
Copy link
Contributor Author

As far as this discussion of losing the fact that previously building this from main only required Golang and in the current state of this PR, you will now need npm also.

As far as I see it, we have three solutions. They're all independent of each other, so any number of them could be chosen:

  • Convert dev / local build workflow to utilize Docker. I'm in strong support of this. The Update package-lock.json with latest npm install commit was required because I'm not sure what version of npm was needed or even how to get specific version of npm on OS X. This would make it easy to pin specific versions of golang / npm and would reduce the local requirements to do full deving from Docker, golang, npm, jest, to JUST Docker.
  • Provide binaries with releases. I think this would just be nice anyways.
  • Commit the ui build artifacts to the repo. This is the only one I'm kinda meh on but will defer to the maintainers.

@kinghrothgar
Copy link
Contributor Author

As far as this discussion, I believe I tested that this works. If you run two make ui's in a row, the second one says there's nothing to do. If you then change anything in ui/assets/**/*, make correctly detected the need to do the rebuild.

Copy link
Contributor

@dschott68 dschott68 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me. Need to resolve merge conflicts.

@dschott68
Copy link
Contributor

replaced by #460

@dschott68 dschott68 closed this Jun 8, 2023
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.

3 participants