diff --git a/README.md b/README.md index d65560a..00bc086 100644 --- a/README.md +++ b/README.md @@ -4,30 +4,14 @@ This is a fork of [vulkan-headers](https://github.com/KhronosGroup/Vulkan-Header ## Updating -To update this repository, we run the following: - -```sh -git remote add upstream https://github.com/KhronosGroup/Vulkan-Headers || true -git fetch upstream -git merge upstream/main --strategy ours -``` +To update this repository, run `./update.sh` followed by `./verify.sh` to verify the repository contents. ## Verifying repository contents -For supply chain security reasons (e.g. to confirm we made no patches to the code) you can verify the contents of this repository by adding the upstream version as a remote: +For supply chain security reasons (e.g. to confirm we made no patches to the code) we provide a `git diff` command you can run to verify the contents of this repository: ```sh -git remote add upstream https://github.com/KhronosGroup/Vulkan-Headers || true -git fetch upstream +./verify.sh ``` -And then comparing using `git diff` with some options to _exclude deleted files_, and exclude `README.md`, `build.zig`, and `.gitignore` from the diff: - -```sh -git diff $(git merge-base origin/main upstream/main)..origin/main \ - --diff-filter=d \ - ':(exclude)README.md' \ - ':(exclude)build.zig' \ - ':(exclude).gitignore' \ - ':(exclude)stub.c' -``` +If nothing is printed, there is no diff. Deleted files, and changes to `README.md`, `build.zig`, `.github` CI files and `.gitignore` are ignored. diff --git a/update.sh b/update.sh new file mode 100755 index 0000000..55b2c67 --- /dev/null +++ b/update.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +set -euo pipefail + +git remote add upstream https://github.com/KhronosGroup/Vulkan-Headers || true +git fetch upstream +git merge upstream/main --strategy ours diff --git a/verify.sh b/verify.sh new file mode 100755 index 0000000..ab45f13 --- /dev/null +++ b/verify.sh @@ -0,0 +1,10 @@ +#!/usr/bin/env bash +set -euo pipefail + +git diff $(git merge-base origin/main upstream/main)..origin/main \ + --diff-filter=d \ + ':(exclude)README.md' \ + ':(exclude)build.zig' \ + ':(exclude).github' \ + ':(exclude).gitignore' \ + ':(exclude)stub.c'