]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/ja/usage/updating.itely
5cfb3f03fcff8fdb9e62fc5d62f0e11f03f1c467
[lilypond.git] / Documentation / ja / usage / updating.itely
1 @c -*- coding: utf-8; mode: texinfo; documentlanguage: ja -*-
2
3 @ignore
4     Translation of GIT committish: 9a65042d49324f2e3dff18c4b0858def81232eea
5
6     When revising a translation, copy the HEAD committish of the
7     version that you are working on.  For details, see the Contributors'
8     Guide, node Updating translation committishes..
9 @end ignore
10
11 @c \version "2.12.0"
12
13 @c Translators: Yoshiki Sawada
14 @c Translation status: post-GDP
15
16
17 @node convert-ly を使ってファイルを更新する
18 @chapter @command{convert-ly} を使ってファイルを更新する
19 @translationof Updating files with convert-ly
20
21 @cindex Updating a LilyPond file (LilyPond ファイルを更新する)
22 @cindex convert-ly
23
24 LilyPond の入力構文は、さまざまな方法で単純化または改善するために、@c
25 定期的に変更されます。@c
26 その副作用として、LilyPond のインタプリタは@c
27 しばしば古い入力ファイルと互換性を持たなくなります。@c
28 これを救済するために、プログラム @command{convert-ly} を用いることで、@c
29 たいていの LilyPond のバージョン間での構文変更を処理することができます。
30
31
32 @menu
33 * 何故構文は変更されるのか?::
34 * convert-ly を呼び出す::
35 * convert-ly のコマンド ライン オプション::
36 * convert-ly の問題点::
37 @end menu
38
39 @node 何故構文は変更されるのか?
40 @section 何故構文は変更されるのか?
41 @translationof Why does the syntax change?
42 @untranslated
43
44 @node convert-ly を呼び出す
45 @section @command{convert-ly} を呼び出す
46 @translationof Invoking convert-ly
47
48 @command{convert-ly} は古いバージョン番号を検出するために@c
49 入力ファイルの @code{version} ステートメントを使用します。@c
50 たいていの場合、あなたの入力ファイルをアップグレードするには、@c
51 そのファイルを保持しているディレクトリで以下を実行することで十分です:
52
53 @example
54 convert-ly -e myfile.ly
55 @end example
56
57 @noindent
58 これにより、@code{myfile.ly} はアップグレードされ、@c
59 オリジナル ファイルは @code{myfile.ly~} に保存されます。
60
61 ディレクトリの中にある入力ファイルをすべて変換するには、@c
62 以下のようにします:
63
64 @example
65 convert-ly -e *.ly
66 @end example
67
68 オリジナル ファイルをアップグレードされたファイルで置き換える代わりに、@c
69 アップグレードされたファイルに異なるファイル名を指定して、@c
70 オリジナル ファイルをそのまま残しておくには、@c
71 以下のようにします:
72
73 @example
74 convert-ly myfile.ly > mynewfile.ly
75 @end example
76
77 @command{convert-ly} は常にそれが扱っている最新の構文変更に変換します。@c
78 このことは、通常、ファイルの中にある @code{version} 番号は 
79 @command{convert-ly} 自体のバージョンよりも低いということを意味します。
80
81 このプログラムは変換元のバージョン番号をリストアップします。
82 バージョン番号がリストアップされない場合、@c
83 そのファイルは最新であるということになります。
84
85 MacOS@tie{}X ユーザはこのコマンドをメニュー エントリ 
86 (@code{Compile > Update syntax}) 下で実行することになるかもしれません。
87
88 Windows ユーザはこれらのコマンドを @q{コマンド プロンプト} ウィンドウから@c
89 実行する必要があります。@c
90 コマンド プロンプトは通常、@code{スタート > アクセサリ > コマンド プロンプト}
91 で見つかります。
92
93
94 @node convert-ly のコマンド ライン オプション
95 @section @command{convert-ly} のコマンド ライン オプション
96 @translationof Command line options for convert-ly
97
98 一般に、このプログラムは以下のように呼び出されます:
99
100 @example
101 convert-ly [@var{option}]@dots{} @var{filename}@dots{}
102 @end example
103
104
105 以下のオプションを与えることができます:
106
107 @table @code
108 @item -e,--edit
109 Apply the conversions direct to the input file, modifying it
110 in-place.
111
112 @item -f,--from=@var{from-patchlevel}
113 変換元のバージョンをセットします。@c
114 これがセットされていない場合、@c
115 @command{convert-ly} は入力ファイルの中にある 
116 @code{version} 文字列を基に推測します。@c
117 例: @code{--from=2.10.25}
118
119 @item -n,--no-version
120 通常、@command{convert-ly} は @code{\version} インジケータを@c
121 出力に付け加えます。@c
122 このオプションを指定すると、それを抑制します。
123
124 @item -s, --show-rules
125 すべての変換を表示して、終了します。
126
127 @item --to=@var{to-patchlevel}
128 変換先のバージョンをセットします。@c
129 デフォルトは利用可能な最新バージョンです。@c
130 例: @code{--to=2.12.2}
131
132 @item -h, --help
133 使用方法についてのヘルプを表示します。
134 @end table
135
136 texinfo ファイルの中にある LilyPond 断片をアップグレードするには@c
137 以下を使用してください:
138
139 @example
140 convert-ly --from=... --to=... --no-version *.itely
141 @end example
142
143 2 つのバージョン間での LilyPond 構文の変更を調べるには、@c
144 以下を使用してください:
145
146 @example
147 convert-ly --from=... --to=... -s
148 @end example
149
150
151 @node convert-ly の問題点
152 @section @code{convert-ly} の問題点
153 @translationof Problems with convert-ly
154
155 Windows の @q{コマンド プロンプト} ウィンドウから@c
156 スペースを含むファイル名やパスを持つファイルに対して@c
157 convert-ly を実行する場合、@c
158 入力ファイル名全体を 3 つ (!) のダブル クォートで囲む必要があります:
159
160 @example
161 convert-ly """D:/My Scores/Ode.ly""" > "D:/My Scores/new Ode.ly"
162 @end example
163
164 @command{convert-ly -e *.ly} コマンドが@c
165 展開時に長くなりすぎて失敗する場合、@c
166 @command{convert-ly} コマンドをループさせてやります。@c
167 以下の例は UNIX 用であり、@c
168 カレント ディレクトリの中にあるすべての @code{.ly} ファイルを@c
169 アップグレードします:
170
171 @example
172 for f in *.ly; do convert-ly -e $f; done;
173 @end example
174
175 Windows の @q{コマンド プロンプト} ウィンドウでの@c
176 上の例に対応するコマンドは以下の通りです:
177
178 @example
179 for %x in (*.ly) do convert-ly -e """%x"""
180 @end example
181
182 言語の変更がすべて処理されるわけではありません。@c
183 指定できる出力オプションは 1 つだけです。@c
184 自動的に Scheme と更新することと 
185 LilyPond の Scheme インタフェイスを更新することはまったく異なります。@c
186 Scheme コードの調整は手動で行う覚悟でいてください。
187
188 convert-ly が処理できないことがいくつかあります。@c
189 ここに、LilyPond コミュニティがそのことについて訴えたリストを挙げます。
190
191 convert-ly は必要とされるすべての変更を@c
192 スムーズに実装できるような構造にはなっていないため、@c
193 このようなバグ レポートがあります。@c
194 以下は対応して欲しいという望みのリストであり、@c
195 参照のためにここに置かれています。
196
197 @verbatim
198 1.6->2.0:
199  Doesn't always convert figured bass correctly, specifically things like {<
200 >}.  Mats' comment on working around this:
201    To be able to run convert-ly
202    on it, I first replaced all occurrences of '{<' to some dummy like '{#'
203    and similarly I replaced '>}' with '&}'.  After the conversion, I could
204    then change back from '{ #' to '{ <' and from '& }' to '> }'.
205  Doesn't convert all text markup correctly.  In the old markup syntax,
206  it was possible to group a number of markup commands together within
207 parentheses, e.g.
208    -#'((bold italic) "string")
209    This will incorrectly be converted into
210    -\markup{{\bold italic} "string"}
211    instead of the correct
212    -\markup{\bold \italic "string"}
213 2.0->2.2:
214  Doesn't handle \partcombine
215  Doesn't do \addlyrics => \lyricsto, this breaks some scores with multiple
216 stanzas.
217 2.0->2.4:
218  \magnify isn't changed to \fontsize.
219     - \magnify #m => \fontsize #f, where f = 6ln(m)/ln(2)
220  remove-tag isn't changed.
221     - \applyMusic #(remove-tag '. . .) => \keepWithTag #'. . .
222  first-page-number isn't changed.
223     - first-page-number no => print-first-page-number = ##f
224  Line breaks in header strings aren't converted.
225     - \\\\  as line break in \header strings => \markup \center-align <
226       "First Line" "Second Line" >
227  Crescendo and decrescendo terminators aren't converted.
228     - \rced => \!
229     - \rc => \!
230 2.2->2.4:
231  \turnOff (used in \set Staff.VoltaBracket = \turnOff) is not properly
232 converted.
233 2.4.2->2.5.9
234  \markup{ \center-align <{ ... }> } should be converted to:
235  \markup{ \center-align {\line { ... }} }
236  but now, \line is missing.
237 2.4->2.6
238  Special LaTeX characters such as $~$ in text are not converted to UTF8.
239 2.8
240  \score{} must now begin with a music expression.  Anything else
241  (particularly \header{}) must come after the music.
242 @end verbatim