Lines Matching +full:some +full:- +full:project +full:- +full:name
14 run them by hand, you can execute `pre-upload.py` directly. By default, that
23 `--no-verify` when running `repo upload` to skip all upload checks. This will
30 * Repo project-wide settings (e.g. all of AOSP). These set up defaults for all
32 * Project-local settings (e.g. a single .git repo). These control settings for
33 the local project you're working on.
38 ## GLOBAL-PREUPLOAD.cfg
40 These are the manifest-wide defaults and can be located in two places:
41 * `.repo/manifests/GLOBAL-PREUPLOAD.cfg`: The manifest git repo.
43 * `GLOBAL-PREUPLOAD.cfg`: The top level of the repo checkout.
44 For manifests that don't have a project checked out at the top level,
58 # Per-project `repo upload` hook settings.
65 name = script --with args ${PREUPLOAD_FILES}
71 cpplint = --filter=-x ${PREUPLOAD_FILES}
74 clang-format = /usr/bin/clang-format
84 * `REPO_PROJECT`: The name of the project.
86 * `REPO_PATH`: The path to the project relative to the root.
88 * `REPO_REMOTE`: The name of the git remote.
90 * `REPO_LREV`: The name of the remote revision, translated to a local tracking
91 branch. This is typically latest commit in the remote-tracking branch.
113 Some variables are available to make it easier to handle OS differences. These
116 * `${REPO_PATH}`: The path to the project relative to the root.
118 * `${REPO_PROJECT}`: The name of the project.
121 project is in a submanifest, this points to the root of the submanifest.
124 * `${BUILD_OS}`: The string `darwin-x86` for macOS and the string `linux-x86`
129 Here are some examples of using the placeholders.
134 checker prefix = check --file=${PREUPLOAD_FILES_PREFIXED}
135 checker flag = check --file ${PREUPLOAD_FILES_PREFIXED}
140 * ['check', '--file=path1/file1', '--file=path2/file2']
141 * ['check', '--file', 'path1/file1', '--file', 'path2/file2']
146 pre-upload checks. The following options are recognized:
153 This section allows for completely arbitrary hooks to run on a per-repo basis.
155 The key can be any name (as long as the syntax is valid), as can the program
156 that is executed. The key is used as the name of the hook for reporting purposes,
159 Whitespace in the key name is OK!
168 my first hook = program --gogog ${PREUPLOAD_FILES}
169 another hook = funtimes --i-need "some space" ${PREUPLOAD_FILES}
170 some fish = linter --ate-a-cat ${PREUPLOAD_FILES}
171 some cat = formatter --cat-commit ${PREUPLOAD_COMMIT}
172 some dog = tool --no-cat-in-commit-message ${PREUPLOAD_COMMIT_MESSAGE}
180 * `aidl_format`: Run AIDL files (.aidl) through `aidl-format`.
181 * `aosp_license`: Check if all new-added file have valid AOSP license headers.
183 code. Refer to go/test-mapping for more details.
186 * `clang_format`: Run git-clang-format against the commit. The default style is
189 * `commit_msg_changeid_field`: Require a valid `Change-Id:` Gerrit line.
202 [`google-java-format`](https://github.com/google/google-java-format).
203 Supports an additional option --include-dirs, which if specified will limit
207 --include-dirs, which if specified will limit enforcement to only files under
231 (especially `${PREUPLOAD_FILES}` -- see below).
241 cpplint = --filter=-x ${PREUPLOAD_FILES}
247 This section can only be added to the repo project-wide settings
248 [GLOBAL-PREUPLOAD.cfg].
251 Used to explicitly exclude some projects when processing a hook. With this
255 An entry must completely match the project's `REPO_PATH`. The paths can use the
256 [shell-style wildcards](https://docs.python.org/library/fnmatch.html) and
274 Some builtin hooks need to call external executables to work correctly. By
280 * `aidl-format`: used for the `aidl_format` builtin hook.
281 * `android-test-mapping-format`: used for the `android_test_mapping_format`
284 * `clang-format`: used for the `clang_format` builtin hook.
286 * `git-clang-format`: used for the `clang_format` builtin hook.
288 * `google-java-format`: used for the `google_java_format` builtin hook.
289 * `google-java-format-diff`: used for the `google_java_format` builtin hook.
299 clang-format = /usr/bin/clang-format
300 # Or paths relative to the top of the git project.
301 clang-format = prebuilts/bin/clang-format
303 clang-format = ${REPO_ROOT}/prebuilts/clang/host/${BUILD_OS}/clang-stable/bin/clang-format
308 These are notes for people updating the `pre-upload.py` hook itself:
310 * Don't worry about namespace collisions. The `pre-upload.py` script is loaded
311 and exec-ed in its own context. The only entry-point that matters is `main`.
312 * New hooks can be added in `rh/hooks.py`. Be sure to keep the list up-to-date
323 * Some checkers operate on the files as they exist in the filesystem. This is
334 * `clang-check`: Runs static analyzers against code.