Skip to content
This repository has been archived by the owner on Mar 11, 2022. It is now read-only.

Provide a Makefile supporting travis as well as local tasks #12

Open
marcellanz opened this issue Oct 25, 2019 · 5 comments
Open

Provide a Makefile supporting travis as well as local tasks #12

marcellanz opened this issue Oct 25, 2019 · 5 comments

Comments

@marcellanz
Copy link
Contributor

marcellanz commented Oct 25, 2019

The travis-ci configuration has some tasks that are valuable also for local development, make them available by a Makefile.

Tasks

  • ci tasks
  • goimports
@marcellanz
Copy link
Contributor Author

marcellanz commented Aug 22, 2020

@hungaikev sure :) Please also have a look at the feature/crdt_support branch where much of the 0.2.0 milestone work is currently being done and to be built artefacts have moved.

@hungaikev
Copy link

hungaikev commented Aug 22, 2020

I am not sure I understand the last part of the response. For clarification, would you like the work to be done under the feature/crdt_support branch or should I just create a new branch and open my PR from that?

Follow up question: Other than go test -v ./... and go build ./... and maybe goimports -w . what other commands do you think would be valuable on the Makefile

Would adding https://github.com/golangci/golangci-lint provide any value? @marcellanz

@marcellanz
Copy link
Contributor Author

would you like the work to be done under the feature/crdt_support branch or should I just create a new branch and open my PR from that?

Good question @hungaikev. With the second part, I wanted to say that I'd propose to have this Issue solved with the 0.2.x milestone as all of the planned work for this milestone is in the crtd branch. The reason for this is, that since the original release of 0.1.0, too much has changed and it would be better to work against this branch I've worked on for the last couple of weeks. This issue itself is planned for 0.2.x and therefore its best to do a PR against the state of the crdt branch. I pushed a current copy of the crdt branch branch as milestone/0_2_x so that you can start from it and then open your PR against it. This way you won't work against something we have replaced with 0.2.0 in the near future.

Regarding features of value for the Makefile. Having golangci-lint would be a great addition having it run with a build too and fail the build on rules enabled. Otherwise having the Makefile would help to have

  • build docs
  • build the tck
  • run the tck locally (see the scripts under /tck)
  • run commands running during travis build
  • compile protobufs (consider to use go generate and gen.go files for such a task)

In general, I like to have things simple and go [build|test] ./... should be enough most of the time if possible.

@hungaikev
Copy link

hungaikev commented Aug 22, 2020

Thanks for the clarification,

I tried running https://github.com/golangci/golangci-lint adding the following rules that have are disabled by default:

    - dogsled
    - gochecknoinits
    - goconst
    - godox
    - goimports
    - golint
    - gosec
    - rowserrcheck
    - stylecheck
    - unparam

Please look at https://golangci-lint.run/usage/linters/#disabled-by-default-linters--e--enable and let me know apart from what I have already posted what else looks useful.

Based on the results of the lint, a lot of clean up needs to happen and it might make more sense to have this as a separate PR. Let me know what you think

@marcellanz
Copy link
Contributor Author

Great. As the branch is a current WIP it's a good idea to have the addition of golangci-lint and the fixes of its reported issues separated. I still work on all the things of milestone 2 on this branch and will fix the relevant parts along until I'll PR the work.

Regarding rules applied, please enable what you think what is appropriate and we then can review that with the PR. wdyt @hungaikev? and thanks for working on this issue.

@marcellanz marcellanz removed this from the Go Support v0.2.0 milestone Sep 7, 2020
@marcellanz marcellanz self-assigned this Jan 18, 2021
@marcellanz marcellanz added this to the Go Support v0.3.0 milestone Jan 18, 2021
@marcellanz marcellanz removed their assignment Feb 3, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants