This repository has been archived by the owner on Jun 27, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 4
/
developers.html
87 lines (70 loc) · 2.87 KB
/
developers.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
<!DOCTYPE html>
<html>
<head>
<title>Caltech Library's Digital Library Development Sandbox</title>
<link rel="stylesheet" href="/css/site.css">
</head>
<body>
<header>
<a href="http://library.caltech.edu"><img src="/assets/liblogo.gif" alt="Caltech Library logo"></a>
</header>
<nav>
<ul>
<li><a href="/">Home</a></li>
<li><a href="index.html">README</a></li>
<li><a href="license.html">LICENSE</a></li>
<li><a href="install.html">INSTALL</a></li>
<li><a href="docs/">Documentation</a></li>
<li><a href="how-to/">HOW TO</a></li>
<li><a href="https://github.com/caltechlibrary/mkpage">Github</a></li>
</ul>
</nav>
<section>
<h1>Notes on compile <em>mkpage</em></h1>
<h2>Requirements</h2>
<ul>
<li>go 1.12 or better</li>
<li><em>make</em> if you want to the <em>Makefile</em> to build the project.</li>
<li><a href="https://github.com/caltechlibrary/pkgassets">pkgassets</a> for generating a new <em>assets.go</em></li>
<li>Caltech Library Go Packages
<ul>
<li>github.com/caltechlibrary/cli</li>
<li>github.com/caltechlibrary/tmplfn</li>
<li>github.com/caltechlibrary/rss2</li>
</ul></li>
<li>3rd Party Go packages used by <em>mkpage</em> project
<ul>
<li>github.com/gomarkdown/markdown</li>
<li>github.com/gomarkdown/markdown/parser</li>
<li>github.com/gomarkdown/markdown/html</li>
<li>github.com/mmarkdown/mmark</li>
</ul></li>
</ul>
<h2>Compiling from source</h2>
<p>Using <em>go get</em></p>
<pre><code class="language-shell"> go get -u github.com/caltechlibrary/pkgassets/...
go get -u github.com/caltechlibrary/mkpage/...
</code></pre>
<p>Manual using only the go command</p>
<pre><code class="language-shell"> for PNAME in byline mkpage mkrss mkslides reldocpath sitemapper titleline urldecode urlencode ws; do
go build -o "bin/${PNAME}" "cmds/${PNAME}/${PNAME}.go"
done
</code></pre>
<h3>regenerating assets.go</h3>
<p><em>assets.go</em> holds the go source code for a map containing the contents of the <em>defaults</em> directory (e.g.
templates/page.tmpl and templates/slides.tmpl). If you modify those files you’ll need to recreate
<em>assets.go</em>. You can do so with the <a href="https://github.com/caltechlibrary/pkgassets">pkgassets</a> tool.</p>
<pre><code class="language-shell"> pkgassets -o assets.go -p mkpage Defaults defaults
</code></pre>
<p>If you’re not modifying the contents of the defaults directory you do not need to regenerate <em>assets.go</em>.</p>
</section>
<footer>
<span><h1><A href="http://caltech.edu">Caltech</a></h1></span>
<span>© 2020 <a href="https://www.library.caltech.edu/copyright">Caltech library</a></span>
<address>1200 E California Blvd, Mail Code 1-32, Pasadena, CA 91125-3200</address>
<span>Phone: <a href="tel:+1-626-395-3405">(626)395-3405</a></span>
<span><a href="mailto:library@caltech.edu">Email Us</a></span>
<a class="cl-hide" href="sitemap.xml">Site Map</a>
</footer>
</body>
</html>