Commit graph

12 commits

Author SHA1 Message Date
Charles Kerr
b253d52faf
build: export matching patches (#41174)
* build: make patches/config.json an array of objects

This file was previously an object of patch_dir keys to repo values;
Now is an array of objects containing `patch_dir` and `repo` properties.
This makes other per-target properties (e.g. `grep`) possible.

* build: include Note metadata when exporting patches

* build: support keyword filtering in export_patches()

* build: add optional `--grep` arg to git-export-patches script

* build: update export_all_patches to understand new config file

* fixup! build: update export_all_patches to understand new config file

chore: make lint happy

* fixup! build: make patches/config.json an array of objects

chore: fix oops

* refactor: remove support for the old file format

There is more code using config.json than I thought, so the
effort-to-reward of supporting the old format is not worth it.

* build: update apply_all_patches to understand new config file

* build: update lint.js to understand new config file

* build: update patches-mtime-cache.py to understand new config file

* fixup! build: update apply_all_patches to understand new config file

fix: oops

* fixup! build: update apply_all_patches to understand new config file

fix minor syntax wart

* fixup! build: support keyword filtering in export_patches()

refactor: use idiomatic python

* refactor: warn if config.json has an invalid repo
2024-02-08 13:47:59 -05:00
Jeremy Rose
c0d442364a
build: explicitly run scripts with python3 (#33720)
* build: explicitly run scripts with python3

* chore: update patches

Co-authored-by: PatchUp <73610968+patchup[bot]@users.noreply.github.com>
2022-04-12 13:21:55 +02:00
Romain Pokrzywka
483808a8cf
fix: Support running git-[im,ex]port-patches with Python3 too (#32303)
* script: Python3 compatibility for utf8 conversion

The unicode() method has been renamed to str() in Python3,
add a wrapper around it to support running against both versions.

* script: don't require python2 for git-[import,export]-patches

The scripts work just fine with python3 too, so use the generic
python executable as the script interpreter.
Most setups don't even require or provide python 2 anymore,
so this saves one from having to install it just for the scripts.
2022-01-10 16:47:55 -05:00
Charles Kerr
9b08fbefe5
chore: remove unused imports in our python scripts (#25406)
Seen at https://lgtm.com/projects/g/electron/electron/?mode=list&id=py%2Funused-import
and confirmed with manual inspection.
2020-09-14 10:25:49 +09:00
Valentin Hăloiu
a829ae56b2
build: use python 2 shebang for git scripts (#25335) 2020-09-10 10:05:19 +09:00
Jeremy Apthorp
29f773e008
ci: auto-3way patches and detect changes (#22976) 2020-04-08 08:59:14 -07:00
Jeremy Apthorp
fdaa75354a
chore: save HEAD when git-import-patches runs (#17824) 2019-04-17 11:16:03 -07:00
Samuel Attard
32c9597cbc
build: ensure we use objc regexps for export-patches (#17598)
* build: ensure we use objc regexps for export-patches

* build: also use objc for *.m

Co-Authored-By: MarshallOfSound <samuel.r.attard@gmail.com>
2019-03-28 14:01:43 -07:00
Jeremy Apthorp
825e526456
build: minor fixes to git-export-patches (#17276)
* fix: make export-patches robust to tags with dashes

* fix: --output is a required parameter of export-patches
2019-03-07 15:59:17 -08:00
Jeremy Apthorp
2e1c50c891
chore: fix missing \n at end of exported patches (#15579) 2018-11-05 13:50:35 -08:00
Milan Burda
d56617e5d0 chore: avoid appending git version to the exported patches (#15389)
* chore: avoid appending git version to the exported patches

* fix no-eol at end of v8 patch
2018-10-26 12:52:59 +05:30
Jeremy Apthorp
335e9f68b7
chore: deprecate apply-patches in favour of git-{import,export}-patches (#15300) 2018-10-24 11:24:11 -07:00