Introduce another file-to-array script
Created attachment 135280 [details] Patch
This will be used in Bug 53961. A WIP patch in Bug 53961 demonstrates how to use this.
Comment on attachment 135280 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=135280&action=review > Source/WebCore/ChangeLog:12 > + - No whitespace stripping for CSS files Maybe we want to support an option to strip whitespaces in make-file-arrays.py, and then remove make-css-file-arrays.pl (in another patch). > Source/WebCore/make-file-arrays.py:30 > +# Usage: make-file-arrays.py [--condition=condition-string] --out-h=<header-file-name> --out-cpp=<cpp-file-name> <input-file>... Nit: [--condition=conditional-flag-name] might be descriptive. > Source/WebCore/make-file-arrays.py:39 > + result = re.match(r"(\w+)\.(\w+)", os.path.basename(file_name)) r"([\w\d_]+)\.([\w\d_]+))" might be better?
(In reply to comment #3) > (From update of attachment 135280 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=135280&action=review > > > Source/WebCore/ChangeLog:12 > > + - No whitespace stripping for CSS files > > Maybe we want to support an option to strip whitespaces in make-file-arrays.py, and then remove make-css-file-arrays.pl (in another patch). Yes. I'd like to integrate make-css-file-arrays.pl and xxd.pl into this in the future. > > Source/WebCore/make-file-arrays.py:30 > > +# Usage: make-file-arrays.py [--condition=condition-string] --out-h=<header-file-name> --out-cpp=<cpp-file-name> <input-file>... > > Nit: [--condition=conditional-flag-name] might be descriptive. We can specify this flag like --condition="ENABLE(CALENDAR_PICKER) && ENABLE(PAGE_POPUP)". So, this isn't a name. > > Source/WebCore/make-file-arrays.py:39 > > + result = re.match(r"(\w+)\.(\w+)", os.path.basename(file_name)) > > r"([\w\d_]+)\.([\w\d_]+))" might be better? Looks nice. I'll apply it.
Committed r112988: <http://trac.webkit.org/changeset/112988>