summaryrefslogtreecommitdiff
path: root/data/vim/patches/8.1.0111
blob: c8efeab6b2c043b2d089cd972e8b7c4e0a4761a6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
To: vim_dev@googlegroups.com
Subject: Patch 8.1.0111
Fcc: outbox
From: Bram Moolenaar <Bram@moolenaar.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
------------

Patch 8.1.0111
Problem:    .po files do not use recommended names.
Solution:   Give a warning if the recommended name is not used.  Accept the
            recommended name for conversion. (Christian Brabandt, Ken Takata)
Files:	    src/po/Makefile, src/po/sjiscorr.c, src/po/check.vim


*** ../vim-8.1.0110/src/po/Makefile	2018-06-24 15:52:37.075719437 +0200
--- src/po/Makefile	2018-06-24 17:58:04.858324254 +0200
***************
*** 87,93 ****
  
  ja.euc-jp.po: ja.po
  	iconv -f utf-8 -t euc-jp ja.po | \
! 		sed -e 's/charset=utf-8/charset=euc-jp/' -e 's/# Original translations/# Generated from ja.po, DO NOT EDIT/' > ja.euc-jp.po
  
  # Convert cs.po to create cs.cp1250.po.
  cs.cp1250.po: cs.po
--- 87,93 ----
  
  ja.euc-jp.po: ja.po
  	iconv -f utf-8 -t euc-jp ja.po | \
! 		sed -e 's/charset=[uU][tT][fF]-8/charset=euc-jp/' -e 's/# Original translations/# Generated from ja.po, DO NOT EDIT/' > ja.euc-jp.po
  
  # Convert cs.po to create cs.cp1250.po.
  cs.cp1250.po: cs.po
***************
*** 105,111 ****
  pl.UTF-8.po: pl.po
  	rm -f pl.UTF-8.po
  	iconv -f iso-8859-2 -t utf-8 pl.po | \
! 		sed -e 's/charset=ISO-8859-2/charset=utf-8/' -e 's/# Original translations/# Generated from pl.po, DO NOT EDIT/' > pl.UTF-8.po
  
  # Convert sk.po to create sk.cp1250.po.
  sk.cp1250.po: sk.po
--- 105,111 ----
  pl.UTF-8.po: pl.po
  	rm -f pl.UTF-8.po
  	iconv -f iso-8859-2 -t utf-8 pl.po | \
! 		sed -e 's/charset=ISO-8859-2/charset=UTF-8/' -e 's/# Original translations/# Generated from pl.po, DO NOT EDIT/' > pl.UTF-8.po
  
  # Convert sk.po to create sk.cp1250.po.
  sk.cp1250.po: sk.po
***************
*** 119,125 ****
  zh_CN.cp936.po: zh_CN.UTF-8.po
  	rm -f zh_CN.cp936.po
  	iconv -f UTF-8 -t cp936 zh_CN.UTF-8.po | \
! 		sed -e 's/charset=utf-8/charset=gbk/' -e 's/# Original translations/# Generated from zh_CN.UTF-8.po, DO NOT EDIT/' > zh_CN.cp936.po
  
  # Convert ko.UTF-8.po to create ko.po.
  ko.po: ko.UTF-8.po
--- 119,125 ----
  zh_CN.cp936.po: zh_CN.UTF-8.po
  	rm -f zh_CN.cp936.po
  	iconv -f UTF-8 -t cp936 zh_CN.UTF-8.po | \
! 		sed -e 's/charset=[uU][tT][fF]-8/charset=gbk/' -e 's/# Original translations/# Generated from zh_CN.UTF-8.po, DO NOT EDIT/' > zh_CN.cp936.po
  
  # Convert ko.UTF-8.po to create ko.po.
  ko.po: ko.UTF-8.po
*** ../vim-8.1.0110/src/po/sjiscorr.c	2016-01-31 17:13:47.000000000 +0100
--- src/po/sjiscorr.c	2018-06-24 17:58:04.858324254 +0200
***************
*** 16,22 ****
  	{
  		for (p = buffer; *p != 0; p++)
  		{
! 			if (strncmp(p, "charset=utf-8", 13) == 0)
  			{
  				fputs("charset=cp932", stdout);
  				p += 12;
--- 16,23 ----
  	{
  		for (p = buffer; *p != 0; p++)
  		{
! 			if (strncmp(p, "charset=utf-8", 13) == 0
! 				|| strncmp(p, "charset=UTF-8", 13) == 0)
  			{
  				fputs("charset=cp932", stdout);
  				p += 12;
*** ../vim-8.1.0110/src/po/check.vim	2018-05-08 16:05:44.000000000 +0200
--- src/po/check.vim	2018-06-24 17:57:34.634490594 +0200
***************
*** 173,184 ****
--- 173,209 ----
    " We allow for a stray plural header, msginit adds one.
  endif
  
+ " Check that 8bit encoding is used instead of 8-bit
+ let cte = search('^"Content-Transfer-Encoding:\s\+8-bit', 'n')
+ let ctc = search('^"Content-Type:.*;\s\+\<charset=[iI][sS][oO]_', 'n')
+ let ctu = search('^"Content-Type:.*;\s\+\<charset=utf-8', 'n')
+ if cte
+   echomsg "Content-Transfer-Encoding should be 8bit instead of 8-bit"
+   " TODO: make this an error
+   " if error == 0
+   "   let error = cte
+   " endif
+ elseif ctc
+   echomsg "Content-Type charset should be 'ISO-...' instead of 'ISO_...'"
+   " TODO: make this an error
+   " if error == 0
+   "   let error = ct
+   " endif
+ elseif ctu
+   echomsg "Content-Type charset should be 'UTF-8' instead of 'utf-8'"
+   " TODO: make this an error
+   " if error == 0
+   "   let error = ct
+   " endif
+ endif
+ 
  
  if error == 0
    " If all was OK restore the view.
    call winrestview(wsv)
    echomsg "OK"
  else
+   " Put the cursor on the line with the error.
    exe error
  endif
  
*** ../vim-8.1.0110/src/version.c	2018-06-24 16:53:31.649909925 +0200
--- src/version.c	2018-06-24 18:04:11.412305463 +0200
***************
*** 791,792 ****
--- 791,794 ----
  {   /* Add new patch number below this line */
+ /**/
+     111,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
104. When people ask about the Presidential Election you ask "Which country?"

 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///