read_netrc: read file directly

...instead of working around the now-dropped restriction of read to the
current repository.

Change-Id: I2de6189144519459fcddc79e6b15592d0760d713
PiperOrigin-RevId: 258362084
diff --git a/tools/build_defs/repo/utils.bzl b/tools/build_defs/repo/utils.bzl
index 79e2dcc..5e7b4aa 100644
--- a/tools/build_defs/repo/utils.bzl
+++ b/tools/build_defs/repo/utils.bzl
@@ -180,13 +180,7 @@
       dict mapping a machine names to a dict with the information provided
       about them
     """
-
-    # We have to first symlink into the current repository, as ctx.read only
-    # allows read from the output directory. Alternatively, we could use
-    # ctx.execute() to call cat(1).
-    ctx.symlink(filename, ".netrc")
-    contents = ctx.read(".netrc")
-    ctx.delete(".netrc")
+    contents = ctx.read(filename)
 
     # Parse the file. This is mainly a token-based update of a simple state
     # machine, but we need to keep the line structure to correctly determine