Update User Manual to use new site

This updates the Rakefile to import the User Manual and also
updates the manual itself to use correct headers.
This commit is contained in:
Pieter de Bie
2008-10-17 22:17:29 +02:00
parent 8738a4e724
commit 94db856f53
7 changed files with 44 additions and 60 deletions
+26 -1
View File
@@ -1,7 +1,7 @@
require 'fileutils'
require 'erb'
task :generate do
task :generate => [:generate_usermanual] do
require 'rdiscount'
`rm -rf output`
FileUtils.mkdir("output")
@@ -19,9 +19,34 @@ task :generate do
end
end
# Add the user manual
FileUtils.mkdir("output/images/UserManual")
`cp -r UserManual/output/images/* output/images/UserManual`
@filename = 'user_manual.html'
body = File.read("UserManual/output/UserManual.html")
File.open("output/user_manual.html", "w") do |f|
f.puts template.result(binding)
end
`open output/index.html`
end
task :generate_usermanual do
require 'rdiscount'
`rm -rf UserManual/output`
FileUtils.mkdir("UserManual/output")
`cat UserManual/text/*.markdown > output/UserManual.markdown`
`cp -r UserManual/assets/images UserManual/output`
source = Dir.glob("UserManual/text/**/*.markdown").map do |file|
File.read(file)
end.join("\n")
body = Markdown.new(source).to_html
File.open("UserManual/output/UserManual.html", "w") do |f|
f.puts body
end
end
task :upload do
`rsync -a output/ sydney:public_html/gitx/`
end
-22
View File
@@ -1,25 +1,3 @@
require 'fileutils'
require 'erb'
task :generate do
require 'rdiscount'
`rm -rf output`
FileUtils.mkdir("output")
`cat text/*.markdown > output/UserManual.markdown`
`cp -r assets output`
source = Dir.glob("text/**/*.markdown").map do |file|
File.read(file)
end.join("\n")
body = Markdown.new(source).to_html
template = ERB.new(File.read("template.html"))
File.open("output/UserManual.html", "w") do |f|
f.puts template.result(binding)
end
`open output/UserManual.html`
end
task :upload do
`rsync -a output/ sydney:public_html/gitx/`
end
@@ -0,0 +1,5 @@
User Manual
-----------
This is the GitX user's manual. In this document, you will be able to read
about everything you need to know on how to use GitX.
@@ -1,20 +0,0 @@
Introduction
============
This is the GitX user's manual. In this document, you will be able to read
about everything you need to know on how to use GitX.
Requirements
------------
GitX is made specifically for Mac OS X 10.5 and higher. Because it uses
features like Garbage Collection, you can't compile it on earlier systems.
GitX also requires a fairly recent Git -- version 1.5.4 and higher are all
supported.
Contact
-------
GitX is actively maintained on Github at [http://github.com/pieter/gitx](http://www.github.com/pieter/gitx/wikis). If you find any bugs or have feature requests, you can put them there.
GitX is actively maintained by Pieter de Bie. You can email him at [frimmirf@gmail.com](mailto:frimmirf@gmail.com)
@@ -1,14 +1,12 @@
Overview
========
### Overview
![GitX's Open Dialog](assets/images/opendialog.png)
![GitX's Open Dialog](images/UserManual/opendialog.png)
When you open GitX for the first time, you will be greeted by an open dialog. In this dialog. you should select the Git repository you want to open. You can select either a directory containing a .git directory, or a .git directory itself. After doing this, you will be greeted by the default GitX view, which is the History View. The history view consists of two main parts. In the top part, there is an overview of all commits in your currently checked out branch. In the bottom part is a detail view that can show you more information about the selected commit.
The commit list
---------------
#### The commit list
![History View](assets/images/historyview.png)
![History View](images/UserManual/historyview.png)
On the left side in the commit list you can see the _branch lines_. These show you how your history has diverged and merged. As newer commits are on top, two lines joining each other from the bottom is a merge. This way you see which branches were merged in without any effort.
On some commits, to the right of the branch lines you will find _commit labels_. These indicate references to these commits, for example branch heads and remote heads. _Green_ labels indicate local branches. _Blue_ labels indicate remote branches (it will be in the form of remote/branch). _Yellow_ labels indicate tags.
@@ -17,13 +15,12 @@ There are three columns, the first showing the commit _subject_ (which is the to
In the top right you will also find the search bar. Here you can search on subject, author or hash. If you do this, the branch lines will also disappear.
The detail view
---------------
#### The detail view
![The detail switch controller](assets/images/detailswitcher.png "The detail switch controller")
![The detail switch controller](images/UserManual/detailswitcher.png "The detail switch controller")
In the bottom part of the history view, you can see the detail view. This part changes every time you select another commit. The detail view can switch between three different parts using the _detail switch controller_. The first one shows information about the current commit in a nice markup and will probably be the view you use most. In this mode, you can see a pretty diff of the commit, and information such as the parent hashes and the author's email address.
If you right-click on a Reference in this view, you can choose to remove them. Be careful with this, there is no undo option! ![Removing a ref](assets/images/remove_ref.png "Removing references"). The diff view is created in such a way, that it is possible to select a part of the diff and copy and paste it, for example to paste it online and share it with someone. As this is such a common thing to do, GitX provides a way to do it automagically. If you click on the "paste online" link, GitX will try to upload your current commit as a _git patch_ to [gist.github.com](http://gist.github.com "Github's gist"). This will use your GitHub cookie from Safari if it has one -- otherwise it will create an anonymous gist. Because this patch is a proper git patch, others can then simply apply it using 'git am'. For example, if your Gistie id is 14667, someone else can run
If you right-click on a Reference in this view, you can choose to remove them. Be careful with this, there is no undo option! ![Removing a ref](images/UserManual/remove_ref.png "Removing references"). The diff view is created in such a way, that it is possible to select a part of the diff and copy and paste it, for example to paste it online and share it with someone. As this is such a common thing to do, GitX provides a way to do it automagically. If you click on the "paste online" link, GitX will try to upload your current commit as a _git patch_ to [gist.github.com](http://gist.github.com "Github's gist"). This will use your GitHub cookie from Safari if it has one -- otherwise it will create an anonymous gist. Because this patch is a proper git patch, others can then simply apply it using 'git am'. For example, if your Gistie id is 14667, someone else can run
curl gist.github.com/14667.txt | git am
@@ -1,7 +1,6 @@
Committing
==========
### Committing
![GitX's commit view](assets/images/commitview.png "The Commit View") GitX
![GitX's commit view](images/UserManual/commitview.png "The Commit View") GitX
also has a commit interface. This interface mimicks some of `git gui`'s
functionality, but will be extended in future releases.
@@ -22,6 +21,6 @@ Every file has an icon associated with it. This shows the status of that file:
* A _white_ icon indicates a file that is not tracked by Git, but also not ignored.
* A _red_ icon indicates a file that has been deleted.
### Committing
#### Committing
Once you have staged all your changes, you can commit them. Enter a commit message in the center pane, but remember to use proper commit messages: your first line should be a short description of what you have changed, on which you can elaborate below that. Make sure the subject of your commit is short enough to fit in GitX's history view! Pressing the commit button will hopefully convey to you that the commit was succesful, and also give you the commit hash.
@@ -1,5 +1,5 @@
Advance GitX usage
==================
### Advance GitX usage
While GitX can be used just fine without ever touching the terminal, some of
it's power can currently only be used through the command line utility.
@@ -55,4 +55,4 @@ If there are changes both on a remote and on your local side, you can show them
will show commits that are only on your side OR only on the remote side. The `--left-right` options does some other magic: instead of the usual circles GitX uses in the branch lines, it will now use an arrow pointing left for commits only on the right side (that is, in `origin/master`), and an arrow to the right for commits only on the right side. For example, when I issued the same command on this repository, I got:
![Showing --left-right](assets/images/left-right.png)
![Showing --left-right](images/UserManual/left-right.png)