debian packaging: expand documentation
And print what the linter expects: 4 spaces.
Signed-off-by: Stephan Pleines <pleines.stephan@gmail.com>
Change-Id: Idf4d267457860faacf897f215b782ed8616ec7a7
diff --git a/debian/download_packages.py b/debian/download_packages.py
index 2d284d7..82f01ce 100755
--- a/debian/download_packages.py
+++ b/debian/download_packages.py
@@ -147,7 +147,7 @@
contents.sort()
print("_files = {")
for deb in contents:
- print(' "%s": "%s",' % (deb, sha256_checksum(deb)))
+ print(' "%s": "%s",' % (deb, sha256_checksum(deb)))
print("}")
diff --git a/debian/packages.bzl b/debian/packages.bzl
index babc0c0..d39f613 100644
--- a/debian/packages.bzl
+++ b/debian/packages.bzl
@@ -1,8 +1,9 @@
load("@rules_pkg//:pkg.bzl", "pkg_tar")
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_file")
-# In order to use deb packages in the build you have to follow these steps:
+# In order to use deb packages in the build you have to follow these steps.
#
+# Adding new packages:
# 1. Create a "download_packages" build step in //debian/BUILD. List the
# packages you care about and exclude the ones you don't care about.
# Invoke "bazel run" on the "download_packages" target you just created.
@@ -23,6 +24,13 @@
# and upload the resulting tarball to https://software.frc971.org/Build-Dependencies.
# 6. Add a new "new_http_archive" entry to the WORKSPACE file for the tarball
# you just uploaded.
+#
+# Updating existing packages:
+# 1. Read above instructions.
+# 2. The "download_packages" build step already exists, run it.
+# 3. The .bzl file with the file list already exists. Update it with the
+# output from the previous step.
+# 4. Follow steps 2., 5., and 6. from "adding new packages".
def download_packages(name, packages, excludes = [], force_includes = [], force_excludes = [], target_compatible_with = None, release = "bullseye"):
"""Downloads a set of packages as well as their dependencies.