The open source OpenXR runtime
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

scripts: Format copybara.

Part-of: <https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2447>

authored by

Rylie Pavlik and committed by
Marge Bot
db176a64 7e9dd015

+86 -73
+86 -73
scripts/copy.bara.sky
··· 8 8 9 9 # update-stb: Update STB libraries 10 10 core.workflow( 11 - name = "update-stb", 11 + name="update-stb", 12 12 custom_rev_id="STB_REV_ID", 13 - origin = git.github_origin( 14 - url = "https://github.com/nothings/stb.git", 15 - ref = "master", 13 + origin=git.github_origin( 14 + url="https://github.com/nothings/stb.git", 15 + ref="master", 16 16 ), 17 - destination = git.destination( 18 - url = gitlab_url, 19 - fetch = "main", 20 - push = "update-stb", 17 + destination=git.destination( 18 + url=gitlab_url, 19 + fetch="main", 20 + push="update-stb", 21 21 ), 22 - destination_files = glob(["src/external/stb/*.h"]), 23 - origin_files = glob(["stb_image_write.h"]), 24 - authoring = authoring.pass_thru(author), 25 - transformations = [ 22 + destination_files=glob(["src/external/stb/*.h"]), 23 + origin_files=glob(["stb_image_write.h"]), 24 + authoring=authoring.pass_thru(author), 25 + transformations=[ 26 26 metadata.replace_message("external/stb: Update stb libraries from upstream"), 27 27 core.move("", "src/external/stb/"), 28 28 ], 29 29 ) 30 + 30 31 31 32 # Custom transformation that writes the COMMIT file in the nanopb directory 32 33 def write_nanopb_commit(ctx): ··· 35 36 core.format("%s\n", [ctx.find_label("GIT_DESCRIBE_CHANGE_VERSION")]), 36 37 ) 37 38 39 + 38 40 # update-nanopb: Update NanoPB library 39 41 # WARNING: Also requires update of the generated .pb.h and .pb.c files, 40 42 # not currently done by this code! 41 43 core.workflow( 42 - name = "update-nanopb", 44 + name="update-nanopb", 43 45 custom_rev_id="NANOPB_REV_ID", 44 - origin = git.github_origin( 45 - url = "https://github.com/nanopb/nanopb.git", 46 + origin=git.github_origin( 47 + url="https://github.com/nanopb/nanopb.git", 46 48 # ref = "master", 47 - describe_version = True, 48 - version_selector = core.latest_version( 49 - format = "refs/tags/nanopb-${n0}.${n1}.${n2}", 50 - regex_groups = { 49 + describe_version=True, 50 + version_selector=core.latest_version( 51 + format="refs/tags/nanopb-${n0}.${n1}.${n2}", 52 + regex_groups={ 51 53 "n0": "[0-9]+", 52 54 "n1": "[0-9]+", 53 55 "n2": "[0-9]+", 54 56 }, 55 57 ), 56 58 ), 57 - destination = git.destination( 58 - url = gitlab_url, 59 - fetch = "main", 60 - push = "update-nanopb", 59 + destination=git.destination( 60 + url=gitlab_url, 61 + fetch="main", 62 + push="update-nanopb", 61 63 ), 62 - destination_files = glob(["src/external/nanopb/*.{h,c,txt}"], exclude = ["src/external/nanopb/monado_metrics.pb.{c,h}"]), 63 - origin_files = glob(["*.{h,c,txt}"], exclude = ["CMakeLists.txt", "CHANGELOG.txt"]), 64 - authoring = authoring.pass_thru(author), 65 - transformations = [ 64 + destination_files=glob( 65 + ["src/external/nanopb/*.{h,c,txt}"], 66 + exclude=["src/external/nanopb/monado_metrics.pb.{c,h}"], 67 + ), 68 + origin_files=glob(["*.{h,c,txt}"], exclude=["CMakeLists.txt", "CHANGELOG.txt"]), 69 + authoring=authoring.pass_thru(author), 70 + transformations=[ 66 71 metadata.expose_label("GIT_DESCRIBE_CHANGE_VERSION"), 67 - metadata.replace_message("external/nanopb: Update nanopb from upstream ${GIT_DESCRIBE_CHANGE_VERSION}"), 72 + metadata.replace_message( 73 + "external/nanopb: Update nanopb from upstream ${GIT_DESCRIBE_CHANGE_VERSION}" 74 + ), 68 75 core.move("", "src/external/nanopb/"), 69 76 # core.format() 70 77 write_nanopb_commit, ··· 73 80 74 81 # update-cjson: Update cJSON library 75 82 core.workflow( 76 - name = "update-cjson", 83 + name="update-cjson", 77 84 custom_rev_id="CJSON_REV_ID", 78 - origin = git.github_origin( 79 - url = "https://github.com/DaveGamble/cJSON.git", 85 + origin=git.github_origin( 86 + url="https://github.com/DaveGamble/cJSON.git", 80 87 # ref = "master", 81 - describe_version = True, 82 - version_selector = core.latest_version( 83 - format = "refs/tags/v${n0}.${n1}.${n2}", 84 - regex_groups = { 88 + describe_version=True, 89 + version_selector=core.latest_version( 90 + format="refs/tags/v${n0}.${n1}.${n2}", 91 + regex_groups={ 85 92 "n0": "[0-9]+", 86 93 "n1": "[0-9]+", 87 94 "n2": "[0-9]+", 88 95 }, 89 96 ), 90 97 ), 91 - destination = git.destination( 92 - url = gitlab_url, 93 - fetch = "main", 94 - push = "update-cjson", 98 + destination=git.destination( 99 + url=gitlab_url, 100 + fetch="main", 101 + push="update-cjson", 95 102 ), 96 - destination_files = glob(["src/external/cjson/cjson/*"]), 97 - origin_files = glob(["cJSON.{h,c}", "{CHANGELOG,CONTRIBUTORS}.md", "LICENSE"]), 98 - authoring = authoring.pass_thru(author), 99 - transformations = [ 103 + destination_files=glob(["src/external/cjson/cjson/*"]), 104 + origin_files=glob(["cJSON.{h,c}", "{CHANGELOG,CONTRIBUTORS}.md", "LICENSE"]), 105 + authoring=authoring.pass_thru(author), 106 + transformations=[ 100 107 metadata.expose_label("GIT_DESCRIBE_CHANGE_VERSION"), 101 - metadata.replace_message("external/cjson: Update cJSON from upstream ${GIT_DESCRIBE_CHANGE_VERSION}"), 108 + metadata.replace_message( 109 + "external/cjson: Update cJSON from upstream ${GIT_DESCRIBE_CHANGE_VERSION}" 110 + ), 102 111 core.move("", "src/external/cjson/cjson/"), 103 112 ], 104 113 ) 105 114 106 115 # update-catch2: Update Catch2 library, in case there's another 2.x release 107 116 core.workflow( 108 - name = "update-catch2", 109 - origin = git.github_origin( 110 - url = "https://github.com/catchorg/Catch2.git", 117 + name="update-catch2", 118 + origin=git.github_origin( 119 + url="https://github.com/catchorg/Catch2.git", 111 120 # ref = "master", 112 - describe_version = True, 113 - version_selector = core.latest_version( 114 - format = "refs/tags/v${n0}.${n1}.${n2}", 115 - regex_groups = { 121 + describe_version=True, 122 + version_selector=core.latest_version( 123 + format="refs/tags/v${n0}.${n1}.${n2}", 124 + regex_groups={ 116 125 "n0": "2", 117 126 "n1": "[0-9]+", 118 127 "n2": "[0-9]+", 119 128 }, 120 129 ), 121 130 ), 122 - destination = git.destination( 123 - url = gitlab_url, 124 - fetch = "main", 125 - push = "update-catch2", 131 + destination=git.destination( 132 + url=gitlab_url, 133 + fetch="main", 134 + push="update-catch2", 126 135 ), 127 - destination_files = glob(["src/external/Catch2/*"]), 128 - origin_files = glob(["single_include/catch2/catch.hpp"]), 129 - authoring = authoring.pass_thru(author), 130 - transformations = [ 136 + destination_files=glob(["src/external/Catch2/*"]), 137 + origin_files=glob(["single_include/catch2/catch.hpp"]), 138 + authoring=authoring.pass_thru(author), 139 + transformations=[ 131 140 metadata.expose_label("GIT_DESCRIBE_CHANGE_VERSION"), 132 - metadata.replace_message("external/Catch2: Update Catch2 from upstream ${GIT_DESCRIBE_CHANGE_VERSION}"), 141 + metadata.replace_message( 142 + "external/Catch2: Update Catch2 from upstream ${GIT_DESCRIBE_CHANGE_VERSION}" 143 + ), 133 144 core.move("single_include/catch2/catch.hpp", "src/external/Catch2/catch/"), 134 145 ], 135 146 ) 136 147 137 148 # update-renderdoc: Update RenderDoc API 138 149 core.workflow( 139 - name = "update-renderdoc", 150 + name="update-renderdoc", 140 151 custom_rev_id="RENDERDOC_REV_ID", 141 - origin = git.github_origin( 142 - url = "https://github.com/baldurk/renderdoc.git", 143 - ref = "v1.x", 152 + origin=git.github_origin( 153 + url="https://github.com/baldurk/renderdoc.git", 154 + ref="v1.x", 144 155 ), 145 - destination = git.destination( 146 - url = gitlab_url, 147 - fetch = "main", 148 - push = "update-renderdoc", 156 + destination=git.destination( 157 + url=gitlab_url, 158 + fetch="main", 159 + push="update-renderdoc", 149 160 ), 150 - destination_files = glob(["src/external/renderdoc_api/*.h"]), 151 - origin_files = glob(["renderdoc/api/app/*.h"]), 152 - authoring = authoring.pass_thru(author), 153 - transformations = [ 154 - metadata.replace_message("external/renderdoc_api: Update RenderDoc API from upstream"), 161 + destination_files=glob(["src/external/renderdoc_api/*.h"]), 162 + origin_files=glob(["renderdoc/api/app/*.h"]), 163 + authoring=authoring.pass_thru(author), 164 + transformations=[ 165 + metadata.replace_message( 166 + "external/renderdoc_api: Update RenderDoc API from upstream" 167 + ), 155 168 core.move("renderdoc/api/app/", "src/external/renderdoc_api/"), 156 169 ], 157 170 )