File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ See below for details.
1515[ /_ tools/patch_for_go_gem/] ( /_tools/patch_for_go_gem/ )
1616
1717## Usage
18- ### ` create_go_makefile `
18+ ### [ ` create_go_makefile ` ] ( https://ruby-go-gem.github.io/go-gem-wrapper/GoGem/Mkmf.html#create_go_makefile-instance_method )
1919` create_go_makefile ` is an extension of ` create_makefile ` .
2020
2121Add a task and hacks to build Go against the ` Makefile ` generated by ` create_makefile ` .
@@ -31,9 +31,12 @@ require "go_gem/mkmf" # Append this
3131# Use create_go_makefile instead of create_makefile
3232# create_makefile("example/example")
3333create_go_makefile(" example/example" )
34+
35+ # Pass debug flags to `go build`
36+ create_go_makefile(" example/example" , go_build_args: " -gcflags='all=-N -l'" )
3437```
3538
36- ### ` GoGem::RakeTask `
39+ ### [ ` GoGem::RakeTask ` ] ( https://ruby-go-gem.github.io/go-gem-wrapper/GoGem/RakeTask.html )
3740Provides rake tasks for ` go test ` with CRuby
3841
3942#### Example (Without config)
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ module GoGem
4040 # end
4141 #
4242 # build_tag = GoGem::Util.ruby_minor_version_build_tag
43- # sh GoGem::RakeTask.build_env_vars, "golangci-lint run --build-tags #{build_tag}"
43+ # sh GoGem::RakeTask.build_env_vars, "golangci-lint run --build-tags #{build_tag} --modules-download-mode=readonly "
4444 # end
4545 # end
4646 # end
@@ -112,14 +112,16 @@ def self.build_env_vars
112112 }
113113 end
114114
115+ # Change current working dir inside `ext/<GEM_NAME>/`
116+ #
115117 # @yield
116118 def within_target_dir
117119 Dir . chdir ( target_dir ) do # rubocop:disable Style/ExplicitBlockArgument
118120 yield
119121 end
120122 end
121123
122- # @return [String]
124+ # @return [String] ext dir name (e.g.`ext/<GEM_NAME>/`)
123125 def ext_dir
124126 File . join ( "ext" , gem_name )
125127 end
You can’t perform that action at this time.
0 commit comments