mirror of
https://github.com/simonmichael/hledger.git
synced 2024-12-26 20:02:27 +03:00
parent
fdd1378b4e
commit
1a29d9cc02
4
Shake.hs
4
Shake.hs
@ -244,7 +244,9 @@ main = do
|
||||
phony "releasemanual0.27" $ do
|
||||
-- XXX under doc so hakyll-std will render it
|
||||
cmd "mkdir -p site/doc/0.27" :: Action ExitCode
|
||||
cmd Shell "git show 0.27:doc/manual.md >site/doc/0.27/manual.md"
|
||||
cmd Shell "git show 0.27:doc/manual.md >site/doc/0.27/manual.md" :: Action ExitCode
|
||||
cmd Shell "patch site/doc/0.27/manual.md doc/manual0.27.diff "
|
||||
|
||||
|
||||
-- build standard hakyll script used for site rendering
|
||||
hakyllstd %> \out -> do
|
||||
|
12
doc/lib.m4
12
doc/lib.m4
@ -10,11 +10,17 @@ m4_define({{_author_}}, {{}})m4_dnl
|
||||
m4_define({{_monthyear_}}, {{May 2016}})m4_dnl
|
||||
m4_define({{_currentrelease_}}, {{0.27}})m4_dnl
|
||||
m4_define({{_version_}}, {{0.28}})m4_dnl
|
||||
m4_dnl
|
||||
m4_dnl Links to dev and recent release versions of a manual.
|
||||
m4_dnl $1 is the manual's web slug: hledger, hledger-ui, journal, csv etc.
|
||||
m4_dnl The current version is hidden (or whatever) by highlightDocVersion in site.js.
|
||||
m4_dnl
|
||||
m4_define({{_versions_}},
|
||||
<div class="versions">
|
||||
version:
|
||||
<a href="$1.html">dev</a>
|
||||
| <a href="doc/_currentrelease_()/manual.html{{#}}m4_patsubst($1,{{hledger-}})">_currentrelease_()</a>
|
||||
This doc is for version **_version_**.
|
||||
Other versions:
|
||||
<a href="$1.html">_version_</a>
|
||||
| <a href="doc/_currentrelease_()/manual.html{{#}}$1">_currentrelease_()</a>
|
||||
</div>)m4_dnl
|
||||
m4_dnl
|
||||
m4_define({{_toc_}}, {{* toc}})m4_dnl
|
||||
|
15
doc/manual0.27.diff
Normal file
15
doc/manual0.27.diff
Normal file
@ -0,0 +1,15 @@
|
||||
4a5,12
|
||||
> <div class="versions">
|
||||
> This doc is for version **0.27**.
|
||||
> Other versions:
|
||||
> <a href="manual.html">0.28dev</a>
|
||||
> </div>
|
||||
>
|
||||
> <a name="hledger" />
|
||||
>
|
||||
2198a2207,2208
|
||||
> <a name="hledger-ui" />
|
||||
>
|
||||
2316a2327,2328
|
||||
>
|
||||
> <a name="hledger-web" />
|
@ -3,11 +3,7 @@
|
||||
% _monthyear_
|
||||
|
||||
_web_({{
|
||||
m4_dnl _versions_({{hledger-api}})
|
||||
<div class="versions">
|
||||
version:
|
||||
<a href="$1.html">dev</a>
|
||||
</div>
|
||||
_versions_({{hledger-api}})
|
||||
_toc_
|
||||
}})
|
||||
|
||||
|
@ -6,7 +6,7 @@ function highlightDocVersion() {
|
||||
$('.versions').each( function() {
|
||||
var parts = window.location.pathname.split('/');
|
||||
var dir = parts.length > 1 ? parts[parts.length-2] : '';
|
||||
var ver = $.isNumeric(dir) ? dir : 'dev';
|
||||
var ver = $.isNumeric(dir) ? dir : '0.28';
|
||||
$(this).find('a').each( function() {
|
||||
if ($(this).html() == ver)
|
||||
$(this)
|
||||
@ -14,6 +14,7 @@ function highlightDocVersion() {
|
||||
.css('text-decoration', 'none')
|
||||
.css('color', 'initial')
|
||||
// .css('font-weight','bold');
|
||||
.hide()
|
||||
});
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user