PageRenderTime 9ms CodeModel.GetById 2ms app.highlight 2ms RepoModel.GetById 2ms app.codeStats 0ms

/scalate-website/src/site.page

http://github.com/scalate/scalate
Visualforce Page | 88 lines | 63 code | 25 blank | 0 comment | 0 complexity | c0da6d50e107b4926e956ba3f8bb77e1 MD5 | raw file
 1---
 2title: Building
 3--- name:overview
 4
 5# ${project_name} Site 
 6How the website works
 7
 8--- name:content pipeline:jade
 9
10.left
11  :markdown
12    # How it works
13.right
14  :&markdown
15    The *#{project_name}* documentation and site is created using Scalate and is stored in git in the same [source control system as the code](source.html)
16
17    **Note:** An [SBT build](sbt.html) is not necessary for contributions to documentation. The embedded webserver can display changes to page markup without re-compilation. An installation of [Maven](https://maven.apache.org/) is all that is required.
18
19    **Note:** For code highlighting you will need to [install](http://pygments.org/download/) [http://pygments.org/](http://pygments.org). If the website project has been built without Pygments, it will need to be rebuilt.
20    
21.left
22  :markdown
23    # Editing the source code
24.right
25  :markdown
26    If you [grab the source code](source.html), the site source is in the *scalate-website* directory.
27
28    First the complete Scalate source must be (compiled and) installed. This pulls necessary code into Maven. In the Scalate [source code](source.html) directory
29
30    {pygmentize:: text}
31    mvn install
32    {pygmentize}
33
34    Then, using the .pom inside the folder, build the website as follows
35
36    {pygmentize:: text}
37    cd scalate-website
38    mvn install
39    {pygmentize}
40
41    **Note:** Older versions of Scalate required Scalate to be [installed](documentation/installing.html). Current builds do not require this.
42
43    If you want to edit the files in your text editor, and see the site re-rendered in a browser immediately, then run the embedded Jetty webserver
44
45    {pygmentize:: text}
46    mvn jetty:run
47    {pygmentize}
48
49    You can now surf the site on
50
51    [http://0.0.0.0:8080/](http://0.0.0.0:8080/)
52
53    Any changes to documentation will be seen on this server, immediately.
54
55    If you are on OS X then we highly recommend [TextMate](http://macromates.com/) as a great editor which supports Textile and Markdown. Text editors which support either markup format are helpful. For example, EMACS has modes for  Textile and Markdown in repository ("M-x package-list-packages" on EMACS versions > 24).
56
57.left
58  :markdown
59    # Deploying the site (new patches)
60.right
61  :markdown
62    You have a GitHub account, and are following the [contribution](http://scalate.fusesource.org/contributing.html) information. When you are happy, you need, on the [Scalate Github page](https://github.com/scalate/scalate), to click on the pull request button.
63
64.left
65  :markdown
66    # Deploying the site (known committer)
67.right
68  :markdown
69
70    The site is automatically deployed by the CI builds, so you can simply wait for the changes to be automatically pushed to the project site.
71    
72    You can manually deploy the site using Maven:
73    
74    {pygmentize:: text}
75    mvn scalate:deploy
76    {pygmentize}
77
78    Though website deployment also occurs by default using the **deploy** goal in maven
79
80    You will need to add the Scalate project's Web server to your Maven configuration:
81    
82    {pygmentize:: xml}
83    <server>
84      <id>website.fusesource.org</id>
85      <username>xxxx</username>
86      <password>xxxxx</password>
87    </server>
88    {pygmentize}