]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/contributor/quick-start.itexi
CG: move lilybuntu into new "quick start" chapter.
[lilypond.git] / Documentation / contributor / quick-start.itexi
1 @c -*- coding: utf-8; mode: texinfo; -*-
2
3 @node Quick start
4 @chapter Quick start
5
6 Want to submit a patch for LilyPond?  Great!  This chapter is
7 designed to let you do this as quickly and easily as possible.
8
9 It is not possible to compile LilyPond on Windows, and extremely
10 difficulty to compile it on MacOS X.  We have therefore made a
11 @q{remix} of Ubuntu which includes all necessary dependencies to
12 compile both LilyPond and the documentation.  This can be run
13 inside a virtual machine without disturbing your main operating
14 system.
15
16 @advanced{experienced developers may prefer to use their own
17 development environment.  It may be instructive to skim over these
18 instructions, but be aware that this chapter is intended for
19 helpful users who may have never created a patch before.}
20
21 @menu
22 * Lilybuntu::
23 * Using lily-git::
24 @end menu
25
26 @node Lilybuntu
27 @section Lilybuntu
28
29 text.
30
31 @menu
32 * Installing lilybuntu::
33 * Configuring lilybuntu in virtualbox::
34 * Using lilybuntu::
35 @end menu
36
37 @node Installing lilybuntu
38 @subsection Installing lilybuntu
39
40 @enumerate
41 @item
42 Install some virtualization software.
43
44 Any virtualization tool can be used, but we recommend VirtualBox:
45
46 @example
47 @uref{http://@/www.virtualbox.org/@/wiki/@/Downloads}
48 @end example
49
50 In virtualization terminology, your main operating system is the
51 @qq{host}, while lilybuntu is the @qq{guest}.
52
53 @item
54 Download the @file{lilybuntu2.iso} disk image: (approximately 1
55 GB)
56
57 @example
58 @uref{http://files.lilynet.net/lilybuntu2.iso}
59 @end example
60
61 @advanced{There is a md5sum available:
62 @uref{http://files.lilynet.net/lilybuntu2.iso.md5}}
63
64 @item
65 Install @file{lilybuntu2.iso} as the @qq{guest} operating system
66 on your virtualized system.
67
68 @itemize
69
70 @item
71 If possible, use at least 700 MB of RAM (1GB would be better) for
72 the virtual machine, and use @qq{dynamically expanding storage}
73 for the virtual hard drive.  A complete compile of everything
74 (code, docs, regression tests) can reach 10 GB.
75
76 @item
77 When @file{lilybuntu2.iso} boots, it shows an ISOLINUX
78 @code{boot:} prompt.  Type:
79
80 @example
81 install
82 @end example
83
84 @item
85 At the @qq{Prepare disk space} stage, do not be afraid to select
86 @qq{Erase and use the entire disk}, since this refers to your
87 @emph{virtual disk}, not your machine's actual hard drive.
88
89 @item
90 When prompted to remove the installation CD, go to
91 @clicksequence{Devices @click{} CD/DVD Devices} and de-select
92 @file{lilybuntu2.iso}.
93
94 @end itemize
95
96 @advanced{
97 The latest version of lilybuntu is based on Ubuntu 10.04.1; if you
98 encounter any difficulties installing it, search for one of the
99 many tutorials for installing that particular version of Ubuntu as
100 a guest operating system.
101 }
102
103 @item
104 Do any extra configuration for your virtualization software.
105
106 We have additional instructions in
107 @ref{Configuring lilybuntu in virtualbox}.
108
109 If you use other virtualization software, then follow the normal
110 procedures for your virtualization software with Ubuntu as the
111 client.
112
113 @advanced{not all hardware is supported in all virtualization
114 tools.  In particular, some contributors have reported problems
115 with USB devices.  If you would like to investigate further, then
116 look for help for your virtualization tool using your normal OS as
117 the @qq{host} and Ubuntu as the @qq{client}.}
118
119 @end enumerate
120
121
122 @node Configuring lilybuntu in virtualbox
123 @subsection Configuring lilybuntu in virtualbox
124
125 VirtualBox has extra @qq{guest additions} which can make the
126 virtualization easier to use (full-screen, easy file sharing
127 between host and guest operating systems, shared clipboards, etc).
128
129 @enumerate
130
131 @item
132 In @emph{VirtualBox}, select @clicksequence{Devices @click{}
133 Install Guest Additions...}.
134
135 @item
136 In @emph{Ubuntu}, select @clicksequence{Places @click{}
137 VBOXADDITIONS_}.  A file-system window will open.
138
139 @item
140 Double-click on the @file{autorun.sh} file, then select @qq{Run in
141 Terminal}, and enter your password when prompted.
142
143 @item
144 Once the script is finished, restart Ubuntu to complete the
145 installation.
146
147 @item
148 Set up any additional features, such as @q{Shared Folders} between
149 your main operating system and ubuntu.  Consult external
150 documentation for this step.
151
152 @advanced{If you do any kernel upgrades, you may need to re-run
153 these VBOXADDITIONS instructions.}
154
155 @end enumerate
156
157
158 @node Using lilybuntu
159 @subsection Using lilybuntu
160
161 If you are not familiar with Linux, it may be beneficial to read a
162 couple of @qq{introduction to Ubuntu} webpages.
163
164 @itemize
165 @item
166 One particular change from Windows and MacOS X is that most
167 software should be installed with your @qq{package manager}; this
168 vastly simplifies the process of installing and configuring
169 software.  Go to @clicksequence{System @click{} Administration
170 @click{} Synaptic Package Manager}.
171
172 @item
173 The rest of this manual assumes that you are using the
174 command-line; go to @clicksequence{Applications @click{}
175 Accessories @click{} Terminal}.
176
177 @end itemize
178
179
180 @c if you change this node name, you'll need to change the @ref in
181 @c web/ and/or included/, along with all the translations.
182 @node Using lily-git
183 @section Using lily-git
184
185 @command{lily-git.tcl} is a graphical tool to help you access and
186 share changes to the lilypond source code.
187
188 @menu
189 * Install and configuration of lily-git.tcl::
190 * Daily use of lily-git.tcl::
191 @end menu
192
193 @node Install and configuration of lily-git.tcl
194 @unnumberedsubsec Install and configuration of @command{lily-git.tcl}
195
196 @warning{The rest of this manual assumes that you are using the
197 command-line; go to @clicksequence{Applications @click{}
198 Accessories @click{} Terminal}.}
199
200 @enumerate
201 @item
202 @code{lily-git.tcl} has already been install for you.  Simply type
203 (or copy&paste):
204
205 @example
206 cd
207 wish lily-git.tcl
208 @end example
209
210 @item
211 Click on the @qq{Get source} button.
212
213 This will create a directory called @file{lilypond-git/} within
214 your home directory, and will download the source code into that
215 directory (around 55Mb).  When the process is finished, the
216 @qq{Command output} window will display @qq{Done}, and the button
217 label will change to say @qq{Update source}.
218
219 @item
220 Navigate to the @file{lilypond-git/} directory to view the source
221 files.  You should now be able to modify the source files using
222 your normal text editor.
223
224 @end enumerate
225
226 You should now progress to @ref{Compiling with lilybuntu}.
227
228 @warning{Throughout the rest of this manual, most command-line
229 input should be entered from @file{~/lilypond-git/}.  This is
230 referred to as the @emph{top source directory}.}
231
232
233 @subsubheading Other operating music systems
234
235 @enumerate
236 @item
237 If you haven't already, download and install Git.
238
239 @itemize
240
241 @item
242 Lilybuntu users: git has already been installed for you.
243
244 @item Windows users: download the @code{.exe} file labeled
245 @qq{Full installer for official Git} from:
246
247 @example
248 @uref{http://code.google.com/p/msysgit/downloads/list}
249 @end example
250
251 @item Other operating systems: either install @command{git} with
252 your package manager, or download it from the @qq{Binaries}
253 section of:
254
255 @example
256 @uref{http://git-scm.com/download}
257 @end example
258
259 @end itemize
260
261
262 @item
263 Download the @command{lily-git.tcl} script from:
264
265 @c don't change the cgit link below to gitweb; gitweb uses
266 @c long filenames like "scripts_auxiliar_lily-git.tcl"
267
268 @example
269 @uref{http://git.sv.gnu.org/cgit/lilypond.git/plain/scripts/auxiliar/lily-git.tcl}
270 @end example
271
272 @item
273 To run the program from the command line, navigate to the
274 directory containing @command{lily-git.tcl} and enter:
275
276 @example
277 wish lily-git.tcl
278 @end example
279
280 @item
281 Go read the lilybuntu instructions, starting from the @qq{get
282 source} step.
283
284 @end enumerate
285
286 @advanced{the @qq{Get source} button does not fetch the entire
287 history of the git repository, so utilities like @command{gitk}
288 will only be able to display the most recent additions.  As you
289 continue to work with @command{lily-git.tcl}, the @qq{Update
290 source} button will take any new additions and add it to whatever
291 is currently in your repository's history.}
292
293
294 @node Daily use of lily-git.tcl
295 @unnumberedsubsec Daily use of @command{lily-git.tcl}
296
297 @warning{Only work on one set of changes at once.  Do not start
298 work on any new changes until your first set has been accepted.}
299
300 @subsubheading 1. Update source
301
302 At the beginning of each session of lilypond work, you should
303 click the @qq{Update source} button to get the latest changes to
304 the source code.
305
306 @warning{In some rare and unfortunate circumstances, this will
307 result in a @emph{merge conflict}.  If this occurs, follow the
308 instructions for @qq{Abort changes}, below.  Your work will not be
309 lost.}
310
311
312 @subsubheading 2a. New local commit
313
314 A single commit typically represents one logical set of related
315 changes (such as a bug-fix), and may incorporate changes to
316 multiple files at the same time.
317
318 When you're finished making the changes for a commit, click the
319 @qq{New local commit} button.  This will open the @qq{Git Commit
320 Message} window.  The message header is required, and the message
321 body is optional.
322
323 After entering a commit message, click @qq{OK} to finalize the
324 commit.
325
326 @advanced{for more information regarding commits and commit
327 messages, see @ref{Commits and patches}.}
328
329
330 @subsubheading 2b. Amend previous commit
331
332 You can go back and make changes to the most recent commit with
333 the @qq{Amend previous commit} button.  This is useful if a
334 mistake is found after you have clicked the @qq{New local commit}
335 button.
336
337 To amend the most recent commit, re-edit the source files as
338 needed and then click the @qq{Amend previous commit} button.  The
339 earlier version of the commit is not saved, but is replaced by the
340 new one.
341
342 @warning{This does not update the patch @strong{files}; if you
343 have a patch file from an earlier version of the commit, you will
344 need to make another patch set when using this feature.  The old
345 patch file will not be saved, but will be replaced by the new one
346 after you click on @qq{Make patch set}.}
347
348
349 @subsubheading 3. Make patch set
350
351 Before making a patch set from any commits, you should click the
352 @qq{Update source} button to make sure the commits are based on
353 the most recent remote snapshot.
354
355 When you click the @qq{Make patch set} button,
356 @command{lily-git.tcl} will produce patch files for any new
357 commits, saving them to the current directory.  The command output
358 will display the name of the new patch files near the end of the
359 output:
360
361 @example
362 0001-CG-add-lily-git-instructions.patch
363 Done.
364 @end example
365
366 Send patch files to the appropriate place:
367
368 @itemize
369 @item
370 If you have a mentor, send it to them via email.
371
372 @item
373 New contributors should send the patch attached to an email to
374 @email{frogs@@lilynet.net}.  Please add @qq{[PATCH]} to the
375 subject line.
376
377 @item
378 Translators should send patches to
379 @email{translations@@lilynet.net}.
380
381 @item
382 More experienced contributors should upload the patch for
383 web-based review.  This requires additional software and use of
384 the command-line; see @ref{Uploading a patch for review}.
385
386 @end itemize
387
388
389 @subsubheading The @qq{Abort changes -- Reset to origin} button
390
391 @warning{Only use this if your local commit history gets
392 hopelessly confused!}
393
394 The button labeled @qq{Abort changes -- Reset to origin} will copy
395 all changed files to a subdirectory of @file{lilypond-git/} named
396 @file{aborted_edits/}, and will reset the repository to the
397 current state of the remote repository (at @code{git.sv.gnu.org}).
398
399
400
401