Lines Matching +full:update +full:- +full:commit +full:- +full:hash
8 # http://www.apache.org/licenses/LICENSE-2.0
37 def git_get_hash(commit): argument
38 return git(['show-ref', '--head', '--hash', commit]).stdout.strip()
43 ['show-ref', '--head', '--hash', '--verify', f'refs/heads/{ref}'],
49 git(['ls-tree', '-r', '--name-only',
54 r = git(['diff-files', '--quiet', '--ignore-submodules'], check=False)
59 ['diff-index', '--quiet', '--ignore-submodules', '--cached', 'HEAD'],
87 r = git(['remote', 'get-url', 'official-source'], check=False)
91 f' Configuring official-source remote {official_source_git_url}')
92 git(['remote', 'remove', 'official-source'], check=False)
93 git(['remote', 'add', 'official-source', official_source_git_url])
95 print(' Syncing official-source')
96 git(['remote', 'update', 'official-source'])
115 android_added_files = local_files - current_official_files
137 with open('./src/wayland-version.h.in', 'rt') as template_file:
147 with open('./src/wayland-version.h', 'wt') as version_header:
150 # wayland-version.h is in .gitignore, so we explicitly have to force-add it.
151 git(['add', '-f', './src/wayland-version.h'])
157 # Use `git-read-tree` to start with a pure copy of the imported version
158 git(['read-tree', '-m', '-u', f'{version}^{{tree}}'])
160 git(['commit', '-m', f'To squash: Clean import of {version}'])
165 git(['restore', '--staged', '--worktree', '--source', start_hash] +
172 git(['commit', '-a', '-m', f'To squash: Update versions {version}'])
183 git(['cherry-pick'] + patches)
194 Once the patches have been resolved, please re-export the patches with:
197 git format-patch HEAD~{len(patches)}..HEAD --no-stat --no-signature \\
198 --numbered --zero-commit --suffix=.diff --output-directory patches
200 ... and also add them to the final squashed commit.
208 git(['log', f'-{len(patches)}',
209 '--pretty=format:%H']).stdout.split()))
214 # Re-export the patches, omitting information that might change
216 'format-patch', f'HEAD~{len(patches)}..HEAD', '--no-stat',
217 '--no-signature', '--numbered', '--zero-commit', '--suffix=.diff',
218 '--output-directory', 'patches'
224 # Create a commit for the exported patches if there are any differences.
225 r = git(['diff-files', '--quiet', '--ignore-submodules'], check=False)
227 git(['commit', '-a', '-m', f'To squash: Update patches for {version}'])
240 '--no-validate-existing',
245 parser.add_argument('--no-squash',
249 help='Whether to squash the import to a single commit')
289 git(['checkout', '-b', import_branch_name])
291 'commit', '--allow-empty', '-m',
292 f'Update to Wayland {args.version}'
303 ['diff', '--quiet', '--ignore-submodules', initial_commit_hash],
307 Failed to recreate the pre-import tree by importing the prior Wayland version
327 print('Squashing to one commit')
328 git(['reset', '--soft', initial_commit_hash])
330 'commit', '--allow-empty', '-m', f'''
331 Update to Wayland {args.version}