forked from cockroachdb/cockroach
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
68836: dev: generate `docs/generated/redact_safe.md` in `dev` r=rail a=rickystewart This file can't properly be bazelfied because generating it requires access to the entire source tree, which we can't easily pass into the Bazel sandbox. Instead it gets special non-Bazel support in `dev` and a special validation in CI. Closes cockroachdb#67923 Release note: None Co-authored-by: Ricky Stewart <[email protected]>
- Loading branch information
Showing
7 changed files
with
56 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -euo pipefail | ||
|
||
echo "The following types are considered always safe for reporting:" | ||
echo | ||
echo "File | Type"; echo "--|--" | ||
git grep --recurse-submodules -n '^func \(.*\) SafeValue\(\)' | \ | ||
grep -v '^vendor/github.com/cockroachdb/redact' | \ | ||
sed -E -e 's/^([^:]*):[0-9]+:func \(([^ ]* )?(.*)\) SafeValue.*$$/\1 | \`\3\`/g' | \ | ||
sort | ||
git grep --recurse-submodules -n 'redact\.RegisterSafeType' | \ | ||
grep -vE '^([^:]*):[0-9]+:[ ]*//' | \ | ||
grep -v '^vendor/github.com/cockroachdb/redact' | \ | ||
sed -E -e 's/^([^:]*):[0-9]+:.*redact\.RegisterSafeType\((.*)\).*/\1 | \`\2\`/g' | \ | ||
sort |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters