Giter Site home page Giter Site logo

gazel's People

Contributors

dixudx avatar ixdy avatar lstoll-sfdc avatar mikedanese avatar spxtr avatar tallclair avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

gazel's Issues

remove hardcoding of kubernetes specific paths

Right now gazel is coded to the kubernetes repository. It should be possible to run gazel on other go repos without forking. A json or yaml config file in the repo root might work.

cc @justinsb since you may have already done this. @pjjw since I see you've forked gazel because this feature didn't exist.

support darwin amd64

Right now the build context is hard coded to linux amd64 so that gazel is stable on all platforms it runs out. We should be able to support generating darwin amd64 BUILD files using select() statements on the cpu configuration of bazel.

ref

gazel/gazel.go

Line 483 in 1e36482

GOOS: "linux",

Vendored cgo fails if a headers etc. needed

If a vendored item depends on headers in the repo, it fails with the generated rule like:

ERROR: /home/lincoln.stoll/src/github.com/heroku/vendor/BUILD:2057:1: C++ compilation of rule '//vendor:github.com/erikdubbelboer/gspt_cgo.cgo.dir/gen/_cgo_lib' failed: linux-sandbox failed: error executing command /media/data/.cache/bazel/_bazel_lincoln.stoll/634c69ae0c5fc3015b4adea04323e7ab/execroot/_bin/linux-sandbox ... (remaining 43 argument(s) skipped).
/media/data/.cache/bazel/_bazel_lincoln.stoll/634c69ae0c5fc3015b4adea04323e7ab/bazel-sandbox/6cf18494-01f4-49d6-870b-bb664034f3b5-0/execroot/bazel-out/local-fastbuild/genfiles/vendor/github.com/erikdubbelboer/gspt_cgo.cgo.dir/src/vendor/github.com/erikdubbelboer/gspt/gspt.go:5:26: fatal error: setproctitle.h: No such file or directory

This seems to be because the gcc command runs in the sandbox root, but the header is in the vendor/xxx path so it isn't found. cgo_library seems like it would/could fix this by passing in that path as an include path (https://github.com/bazelbuild/rules_go/blob/master/go/def.bzl#L937-L938), but this isn't possible with cgo_genrule

I'm happy to have a go at a fix, but I was wondering what the reason was for switching to cgo_genrule in the first place?

Please add --version or --help or similar

Currently gazel does not print its version number and help text is sent to stdout.

I wanted to know which version of gazel I am currently using on my CI server to generate my go BUILD files and wasn't able to do so easily. Additionally, it would be nice to have a command that exits with a 0 but doesn't write anywhere except stdout (like --version or --help) for quick smoke tests.

autogenerate a `sources` filegroup for every package

A recursive filegroup only matches files that are not owned by any other package, which means that to create the kubernetes-src tarball for releases, we either need to do this outside bazel, or we need to autogen a sources filegroup for each BUILD file.

Any objections to just doing this? It'd be a good chance for me to jump into gazel.

--root causing trouble

$ go get -u gopkg.in/mikedanese/gazel.v10/gazel
$ gazel
$ gazel --root "."
$ gazel --root "${PWD}"
wrote "/home/me/go/src/foo/bar/BUILD"
wrote "foo/bar/BUILD"

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.