comparison README.md @ 91:3269c95e98d9 kai

Some more website development documentation.
author Kai T. Ohlhus <k.ohlhus@gmail.com>
date Mon, 17 Oct 2016 21:08:49 +0200
parents bc79072a8169
children
comparison
equal deleted inserted replaced
90:fbd5bca94df2 91:3269c95e98d9
18 18
19 19
20 20
21 ## Development 21 ## Development
22 22
23 ### What makes this way of development better, than the prior?
24
25 - **Official RSS feeds** are **easily** maintained now **at a single place**:
26 the `_posts` subdirectory, later accessible via
27 `https://www.gnu.org/software/octave/feed.xml` and automatically spread
28 to an arbitrary amount of readers, including almost all below mentioned.
29
30 The Octave News are currently very widespread
31 (and **individually maintained!**) at:
32 - https://www.gnu.org/software/octave/ (excerpt for the start page)
33 - https://www.gnu.org/software/octave/news.html (some archive)
34 - https://www.gnu.org/software/octave/community-news.html (excerpt for the
35 Octave GUI)
36 - https://www.gnu.org/software/octave/fixes-4.0.x.html (here are many more
37 to come!)
38 - http://wiki.octave.org/GNU_Octave_Wiki#News (some excerpt, anyone can edit)
39
40 - **Content is content**: Page content is primary written in [Markdown][5],
41 a lightweight Markup language, thus no nasty forgotten HTML tags, that
42 make content look ugly for any author of a HTML page.
43 [Jekyll][6] makes valid HTML from [Markdown][5] content.
44
45 - **Easy maintenance**: Just a single command (see below), and [Jekyll][6]
46 builds a consistent, up-to-date static page. The only maintenance burden,
47 as it is today anyway: The [Savannah CVS][3] repository.
48
49 [5]: https://daringfireball.net/projects/markdown/syntax
50 [6]: https://jekyllrb.com/
51
52
53
23 ### Getting the sources 54 ### Getting the sources
24 55
25 Anyone is free to clone this development repository, simply type 56 Anyone is free to clone this development repository, simply type
26 57
27 hg clone http://hg.octave.org/web-octave 58 hg clone http://hg.octave.org/web-octave
37 68
38 69
39 70
40 ### Building requisites 71 ### Building requisites
41 72
42 To build the static website, you need to install [Jekyll][5] and a few more 73 To build the static website, you need to install [Jekyll][6] and a few more
43 tools from [Rubygems][6]. Just type 74 tools from [Rubygems][7]. Just type
44 75
45 gem install jekyll jekyll-octicons pygments.rb 76 gem install jekyll jekyll-octicons pygments.rb
46 77
47 [5]: https://jekyllrb.com/ 78 [7]: https://rubygems.org/
48 [6]: https://rubygems.org/
49 79
50 80
51 81
52 ### Building the static website 82 ### Building the static website
53 83
68 jekyll serve 98 jekyll serve
69 99
70 and rebuilds the whole static website automatically, as it monitors any 100 and rebuilds the whole static website automatically, as it monitors any
71 file changes. 101 file changes.
72 102
103 To build the test page, that can be deployed at some subdirectory, e.g.
104 `http://www.octave.org/new`, use
105
106 jekyll build --config _config.yml,_config_test.yml
107
108
109
110 ### Typical development tasks
111
112 - **Add a new RSS post**
113
114 Duplicate another post in the subdirectory `_posts` and
115 adjust the filename, especially the date
116
117
118
73 119
74 120
75 ## Deploying 121 ## Deploying
76 122
77 After building the static website from [web-octave][2] into the 123 After building the static website from [web-octave][2] into the
83 129
84 export CVS_RSH=ssh 130 export CVS_RSH=ssh
85 cvs -z3 -d:ext:<Savannah account>@cvs.savannah.gnu.org:/web/octave checkout -P octave 131 cvs -z3 -d:ext:<Savannah account>@cvs.savannah.gnu.org:/web/octave checkout -P octave
86 132
87 Now the following steps are required for deployment 133 Now the following steps are required for deployment
88 (see [here][7] and [here][8] for some introduction to CVS): 134 (see [here][8] and [here][9] for some introduction to CVS):
89 135
90 1. Remove all previous files in the target directory, 136 1. Remove all previous files in the target directory,
91 *but no directories at all or CVS related stuff*! 137 *but no directories at all or CVS related stuff*!
92 This is due to a [limitation of CVS][9]. 138 This is due to a [limitation of CVS][10].
93 139
94 find octave -type f -not -path "*/CVS/*" -exec rm -f '{}' \; 140 find octave -type f -not -path "*/CVS/*" -exec rm -f '{}' \;
95 141
96 *Note:* `octave` in the command above is the name of the checked out 142 *Note:* `octave` in the command above is the name of the checked out
97 [Savannah CVS][3] repository. 143 [Savannah CVS][3] repository.
109 155
110 2. Add all potential new directories to CVS 156 2. Add all potential new directories to CVS
111 157
112 find . -type d -not -name "CVS" -exec cvs add '{}' \; 158 find . -type d -not -name "CVS" -exec cvs add '{}' \;
113 159
114 3. Add all potential new files to CVS (the [following command][10] 160 3. Add all potential new files to CVS (the [following command][11]
115 proved to me fast) 161 proved to me fast)
116 162
117 find . -type f | grep -v CVS | xargs cvs add 163 find . -type f | grep -v CVS | xargs cvs add
118 164
119 4. Commit the chages to get online 165 4. Commit the chages to get online
120 166
121 cvs commit 167 cvs commit
122 168
123 Now everything should be visible to the world. 169 Now everything should be visible to the world.
124 170
125 [7]: https://savannah.nongnu.org/projects/cvs 171 [8]: https://savannah.nongnu.org/projects/cvs
126 [8]: http://www.cs.umb.edu/~srevilak/cvs.html 172 [9]: http://www.cs.umb.edu/~srevilak/cvs.html
127 [9]: https://web.archive.org/web/20140629054602/http://ximbiot.com/cvs/manual/cvs-1.11.23/cvs_7.html#SEC69 173 [10]: https://web.archive.org/web/20140629054602/http://ximbiot.com/cvs/manual/cvs-1.11.23/cvs_7.html#SEC69
128 [10]: http://stackoverflow.com/questions/5071/how-to-add-cvs-directories-recursively 174 [11]: http://stackoverflow.com/questions/5071/how-to-add-cvs-directories-recursively