File tree Expand file tree Collapse file tree 2 files changed +16
-9
lines changed
Expand file tree Collapse file tree 2 files changed +16
-9
lines changed Original file line number Diff line number Diff line change @@ -79,27 +79,23 @@ rpmtree(
7979
8080The bazeldnf repository needs to be added to your ` WORKSPACE ` :
8181
82+ <!-- install_start -->
8283``` python
8384load(" @bazel_tools//tools/build_defs/repo:http.bzl" , " http_archive" )
8485
8586http_archive(
8687 name = " bazeldnf" ,
87- sha256 = " 74f977ab8f13e466168ff0c80322bcb665db9f79d1bc497c742f9512737b91ea" ,
88- strip_prefix = " bazeldnf-0.0.1" ,
88+ sha256 = " 8dcd8908d444d230192bba6965cfa7477554cc991da86b2b68aae956645c3d5e" ,
8989 urls = [
90- " https://github.com/rmohr/bazeldnf/archive/ v0.0.1 .tar.gz" ,
90+ " https://github.com/rmohr/bazeldnf/releases/download/ v0.5.6-rc1/bazeldnf-v0.5.6-rc1 .tar.gz" ,
9191 ],
9292)
9393
94- load(" @io_bazel_rules_go//go:deps.bzl" , " go_register_toolchains" , " go_rules_dependencies" )
9594load(" @bazeldnf//:deps.bzl" , " bazeldnf_dependencies" )
9695
97- go_rules_dependencies()
98-
99- go_register_toolchains()
100-
10196bazeldnf_dependencies()
10297```
98+ <!-- install_end -->
10399
104100Define the ` bazeldnf ` executable rule in your ` BUILD.bazel ` file:
105101``` python
Original file line number Diff line number Diff line change @@ -73,13 +73,24 @@ git archive --format tar.gz HEAD >./dist/bazeldnf-${VERSION}.tar.gz
7373DIGEST=$( sha256sum dist/bazeldnf-${VERSION} .tar.gz | cut -d " " -f 1)
7474
7575cat << EOT >>./dist/releasenote.txt
76- \`\`\`
76+ \`\`\` python
77+ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
78+
7779http_archive(
7880 name = "bazeldnf",
7981 sha256 = "${DIGEST} ",
8082 urls = [
8183 "https://github.com/rmohr/bazeldnf/releases/download/${VERSION} /bazeldnf-${VERSION} .tar.gz",
8284 ],
8385)
86+
87+ load("@bazeldnf//:deps.bzl", "bazeldnf_dependencies")
88+
89+ bazeldnf_dependencies()
8490\`\`\`
8591EOT
92+
93+ lead=' ^<!-- install_start -->$'
94+ tail=' ^<!-- install_end -->$'
95+ sed -e " /$lead /,/$tail /{ /$lead /{p; r dist/releasenote.txt
96+ }; /$tail /p; d }" README.md
You can’t perform that action at this time.
0 commit comments