unicode_width.h: rename to use dash in file name
This is more consistent with the project style. The majority of Git's source files use dashes in preference to underscores in their file names. Also adjust contrib/update-unicode as well. Signed-off-by: Stefan Beller <sbeller@google.com>maint
parent
fa2656f1da
commit
e233bef43e
|
@ -1,10 +1,10 @@
|
||||||
TL;DR: Run update_unicode.sh after the publication of a new Unicode
|
TL;DR: Run update_unicode.sh after the publication of a new Unicode
|
||||||
standard and commit the resulting unicode_widths.h file.
|
standard and commit the resulting unicode-widths.h file.
|
||||||
|
|
||||||
The long version
|
The long version
|
||||||
================
|
================
|
||||||
|
|
||||||
The Git source code ships the file unicode_widths.h which contains
|
The Git source code ships the file unicode-widths.h which contains
|
||||||
tables of zero and double width Unicode code points, respectively.
|
tables of zero and double width Unicode code points, respectively.
|
||||||
These tables are generated using update_unicode.sh in this directory.
|
These tables are generated using update_unicode.sh in this directory.
|
||||||
update_unicode.sh itself uses a third-party tool, uniset, to query two
|
update_unicode.sh itself uses a third-party tool, uniset, to query two
|
||||||
|
@ -16,5 +16,5 @@ This requires a current-ish version of autoconf (2.69 works per December
|
||||||
|
|
||||||
On each run, update_unicode.sh checks whether more recent Unicode data
|
On each run, update_unicode.sh checks whether more recent Unicode data
|
||||||
files are available from the Unicode consortium, and rebuilds the header
|
files are available from the Unicode consortium, and rebuilds the header
|
||||||
unicode_widths.h with the new data. The new header can then be
|
unicode-widths.h with the new data. The new header can then be
|
||||||
committed.
|
committed.
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
#Cf Format a format control character
|
#Cf Format a format control character
|
||||||
#
|
#
|
||||||
cd "$(dirname "$0")"
|
cd "$(dirname "$0")"
|
||||||
UNICODEWIDTH_H=$(git rev-parse --show-toplevel)/unicode_width.h
|
UNICODEWIDTH_H=$(git rev-parse --show-toplevel)/unicode-width.h
|
||||||
|
|
||||||
wget -N http://www.unicode.org/Public/UCD/latest/ucd/UnicodeData.txt \
|
wget -N http://www.unicode.org/Public/UCD/latest/ucd/UnicodeData.txt \
|
||||||
http://www.unicode.org/Public/UCD/latest/ucd/EastAsianWidth.txt &&
|
http://www.unicode.org/Public/UCD/latest/ucd/EastAsianWidth.txt &&
|
||||||
|
|
2
utf8.c
2
utf8.c
|
@ -81,7 +81,7 @@ static int git_wcwidth(ucs_char_t ch)
|
||||||
/*
|
/*
|
||||||
* Sorted list of non-overlapping intervals of non-spacing characters,
|
* Sorted list of non-overlapping intervals of non-spacing characters,
|
||||||
*/
|
*/
|
||||||
#include "unicode_width.h"
|
#include "unicode-width.h"
|
||||||
|
|
||||||
/* test for 8-bit control characters */
|
/* test for 8-bit control characters */
|
||||||
if (ch == 0)
|
if (ch == 0)
|
||||||
|
|
Loading…
Reference in New Issue