Hello community,

here is the log from the commit of package blogc for openSUSE:Factory checked 
in at 2018-06-19 11:58:17
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/blogc (Old)
 and      /work/SRC/openSUSE:Factory/.blogc.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "blogc"

Tue Jun 19 11:58:17 2018 rev:7 rq:616477 version:0.13.9

Changes:
--------
--- /work/SRC/openSUSE:Factory/blogc/blogc.changes      2018-05-16 
11:42:26.858433889 +0200
+++ /work/SRC/openSUSE:Factory/.blogc.new/blogc.changes 2018-06-19 
11:58:19.037942044 +0200
@@ -1,0 +2,22 @@
+Wed Jun 13 08:03:08 UTC 2018 - [email protected]
+
+- Update to 0.13.9:
+  * Fix blogc-git-receiver(1)'s git shell to reinstall its git
+    hooks symlinks if they are broken.
+
+-------------------------------------------------------------------
+Mon Jun 11 06:41:17 UTC 2018 - [email protected]
+
+- Update to 0.13.8:
+  * This is a minor release, that fixes a corner-case segmentation
+    fault in blogc-git-receiver(1)'s pre-receive hook, that was
+    introduced in the previous release.
+- Changes in 0.13.7:
+  * Users can now run blogc-git-receiver(1) in shared hosting
+    enviromnents, if they have SSH access.
+  * If atom_posts_per_page and posts_per_page settings for
+    blogc-make(1) are set to zero, index listings and Atom feeds
+    are not built, instead of producing "empty" files.
+  * Fixed some other minor issues.
+
+-------------------------------------------------------------------

Old:
----
  blogc-0.13.6.tar.xz

New:
----
  blogc-0.13.9.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ blogc.spec ++++++
--- /var/tmp/diff_new_pack.j8hjZy/_old  2018-06-19 11:58:19.617920509 +0200
+++ /var/tmp/diff_new_pack.j8hjZy/_new  2018-06-19 11:58:19.617920509 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           blogc
-Version:        0.13.6
+Version:        0.13.9
 Release:        0
 Summary:        Blog compiler
 License:        BSD-3-Clause

++++++ blogc-0.13.6.tar.xz -> blogc-0.13.9.tar.xz ++++++
++++ 1818 lines of diff (skipped)
++++    retrying with extended exclude list
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/.tarball-version new/blogc-0.13.9/.tarball-version
--- old/blogc-0.13.6/.tarball-version   2018-05-14 22:53:09.000000000 +0200
+++ new/blogc-0.13.9/.tarball-version   2018-06-13 00:21:10.000000000 +0200
@@ -1 +1 @@
-0.13.6
+0.13.9
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/.version new/blogc-0.13.9/.version
--- old/blogc-0.13.6/.version   2018-05-14 22:53:08.000000000 +0200
+++ new/blogc-0.13.9/.version   2018-06-13 00:21:10.000000000 +0200
@@ -1 +1 @@
-0.13.6
+0.13.9
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/Makefile.am new/blogc-0.13.9/Makefile.am
--- old/blogc-0.13.6/Makefile.am        2018-05-14 22:52:33.000000000 +0200
+++ new/blogc-0.13.9/Makefile.am        2018-06-13 00:20:43.000000000 +0200
@@ -49,6 +49,7 @@
        src/blogc-git-receiver/post-receive.h \
        src/blogc-git-receiver/pre-receive.h \
        src/blogc-git-receiver/pre-receive-parser.h \
+       src/blogc-git-receiver/settings.h \
        src/blogc-git-receiver/shell.h \
        src/blogc-git-receiver/shell-command-parser.h \
        src/blogc-make/atom.h \
@@ -197,6 +198,7 @@
        src/blogc-git-receiver/post-receive.c \
        src/blogc-git-receiver/pre-receive.c \
        src/blogc-git-receiver/pre-receive-parser.c \
+       src/blogc-git-receiver/settings.c \
        src/blogc-git-receiver/shell.c \
        src/blogc-git-receiver/shell-command-parser.c \
        $(NULL)
@@ -725,23 +727,23 @@
 
 if USE_LD_WRAP
 check_PROGRAMS += \
-       tests/blogc-git-receiver/check_post_receive \
+       tests/blogc-git-receiver/check_settings \
        $(NULL)
 
-tests_blogc_git_receiver_check_post_receive_SOURCES = \
-       tests/blogc-git-receiver/check_post_receive.c \
+tests_blogc_git_receiver_check_settings_SOURCES = \
+       tests/blogc-git-receiver/check_settings.c \
        $(NULL)
 
-tests_blogc_git_receiver_check_post_receive_CFLAGS = \
+tests_blogc_git_receiver_check_settings_CFLAGS = \
        $(CMOCKA_CFLAGS) \
        $(NULL)
 
-tests_blogc_git_receiver_check_post_receive_LDFLAGS = \
+tests_blogc_git_receiver_check_settings_LDFLAGS = \
        -no-install \
        -Wl,--wrap=realpath \
        $(NULL)
 
-tests_blogc_git_receiver_check_post_receive_LDADD = \
+tests_blogc_git_receiver_check_settings_LDADD = \
        $(CMOCKA_LIBS) \
        libblogc_git_receiver.la \
        libblogc_common.la \
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc-git-receiver.1 new/blogc-0.13.9/blogc-git-receiver.1
--- old/blogc-0.13.6/blogc-git-receiver.1       2018-05-14 22:53:08.000000000 
+0200
+++ new/blogc-0.13.9/blogc-git-receiver.1       2018-06-13 00:21:10.000000000 
+0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGC\-GIT\-RECEIVER" "1" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGC\-GIT\-RECEIVER" "1" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogc\-git\-receiver\fR \- a simple login shell/git hook to deploy blogc 
websites
@@ -32,7 +32,7 @@
 .IP "" 0
 .
 .P
-Now add ssh keys to \fB/home/blogc/\.ssh/authorized_keys\fR\. Every key in 
\fBauthorized_keys\fR will be allowed to push to the git repositories, and even 
create new ones\.
+Now add ssh keys to \fB/home/blogc/\.ssh/authorized_keys\fR\. Every key in 
\fBauthorized_keys\fR will be allowed to push to the git repositories, and even 
create new ones\. It is also possible to add \fBblogc\-git\-receiver\fR as a 
command in the \fBauthorized_keys\fR file for each key, but this setup is 
slightly more tricky, as you may leak shell access to an user by mystake, if 
you forget to add the command to a key that should not have shell access\. Only 
use this method if you don\'t have another option (e\.g\. in shared hosting 
environments that only provide one shell account), or if you know exactly what 
you are doing\.
 .
 .P
 Also, make sure to install all the dependencies required by the websites, 
including a web server\. \fBblogc\-git\-receiver\fR can\'t handle web server 
virtual hosts\.
@@ -54,7 +54,22 @@
 .IP "" 0
 .
 .P
-This will deploy the example to the server, creating a symlink to the built 
content in \fB/home/blogc/repos/blogs/blogc\-example\.git/htdocs\fR\. This 
symlink should be used as the document root for the web server virtual host\.
+This will deploy the example to the server, creating a symlink to the built 
content in \fB/home/blogc/repos/blogs/blogc\-example\.git/htdocs\fR\. This 
symlink should be used as the document root for the web server virtual host\. 
If this symlink can\'t be readed by your webserver for some reason, you can 
create it in some other directory by adding the full symlink path to the 
~/blogc\-git\-receiver\.ini configuration file:
+.
+.IP "" 4
+.
+.nf
+
+$ $EDITOR ~/blogc\-git\-receiver\.ini
+[repo:blogs/blogc\-example\.git]
+symlink=/path/to/my/symlink
+.
+.fi
+.
+.IP "" 0
+.
+.P
+Do not duplicate the section if it already exists, just append the symlink 
path to it\.
 .
 .SS "Rebuild last successful build"
 If for some reason you want to rebuild the last successful build of a given 
website, you can run its \fBpre\-receive\fR hook manually in the server:
@@ -121,17 +136,16 @@
 This feature just requires adding a remote called \fBmirror\fR to the bare 
repository in the server, or creating a configuration file 
(~/blogc\-git\-receiver\.ini), that is a simple INI\-style file where each 
repository is represented by a section and the value of the \fBmirror\fR 
variable is the URL that should be used to push\.
 .
 .P
-To create the configuration file (recommended):
+Edit configuration file (recommended, do not duplicate the section if it 
already exists, just append the mirror to it):
 .
 .IP "" 4
 .
 .nf
 
 # su \-s /bin/sh \- blogc
-$ cat > ~/blogc\-git\-receiver\.ini <<EOF
+$ $EDITOR ~/blogc\-git\-receiver\.ini
 [repo:myblog\.git]
 mirror=$YOUR_GIT_MIRROR_URL
-EOF
 .
 .fi
 .
@@ -208,8 +222,23 @@
 .P
 WARNING: If you push manually and your server\'s repository is empty, you\'ll 
clean your mirror repository\.
 .
-.SH "ENVIRONMENT VARIABLES"
-\fBblogc\-git\-receiver\fR will export an environment variable called 
\fBBLOGC_GIT_RECEIVER\fR when calling \fBgmake\fR to build websites\. This 
variable can be used to enable building of content that should only be built 
when running in production environment, for example\. This variable will not be 
added when using blogc\-make(1), whose builds are always considered to be 
"production" (blogc\-make(1) is never called with \fB\-D\fR)\.
+.SH "ENVIRONMENT"
+The following variables can be set in the SSH Server (usually in 
\fB~/\.ssh/environment\fR) to change \fBblogc\-git\-receiver\fR behaviour:
+.
+.TP
+\fBBLOGC_GIT_RECEIVER_BASE_DIR\fR
+Path to the base directory that should be used by \fBblogc\-git\-receiver\fR\. 
Defaults to user\'s home directory\. Useful for shared hosting environments 
that only provide one shell user\.
+.
+.TP
+\fBBLOGC_GIT_RECEIVER_BUILDS_DIR\fR
+Path to the directory that should be used to store the blogc builds\. Defaults 
to \fB$BLOGC_GIT_RECEIVER_BASE_DIR/builds\fR\. This directory must be readable 
by your webserver\. This variable is useful to keep your git repositories 
unreadable, while letting your webserver access the built files\. In this case, 
users need to also define custom symlinks for every repository in 
\fB$BLOGC_GIT_RECEIVER_BASE_DIR/blogc\-git\-receiver\.ini\fR, because the 
default \fBhtdocs\fR symlink inside the git repositories won\'t be acessible by 
the webserver\.
+.
+.P
+The following variable is exported by \fBblogc\-git\-receiver\fR when building 
websites with make(1):
+.
+.TP
+\fBBLOGC_GIT_RECEIVER=1\fR
+This variable can be used to enable building of content that should only be 
built when running in production environment, for example\. This variable will 
not be exported when using blogc\-make(1), whose builds are always considered 
to be "production" (blogc\-make(1) is never called with \fB\-D\fR)\.
 .
 .SH "BUGS"
 Please report any issues to: \fIhttps://github\.com/blogc/blogc\fR
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc-make.1 new/blogc-0.13.9/blogc-make.1
--- old/blogc-0.13.6/blogc-make.1       2018-05-14 22:53:08.000000000 +0200
+++ new/blogc-0.13.9/blogc-make.1       2018-06-13 00:21:10.000000000 +0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGC\-MAKE" "1" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGC\-MAKE" "1" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogc\-make\fR \- a simple build tool for blogc
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc-pagination.7 new/blogc-0.13.9/blogc-pagination.7
--- old/blogc-0.13.6/blogc-pagination.7 2018-05-14 22:53:08.000000000 +0200
+++ new/blogc-0.13.9/blogc-pagination.7 2018-06-13 00:21:10.000000000 +0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGC\-PAGINATION" "7" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGC\-PAGINATION" "7" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogc\-pagination\fR \- blogc\'s pagination support
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc-runserver.1 new/blogc-0.13.9/blogc-runserver.1
--- old/blogc-0.13.6/blogc-runserver.1  2018-05-14 22:53:09.000000000 +0200
+++ new/blogc-0.13.9/blogc-runserver.1  2018-06-13 00:21:10.000000000 +0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGC\-RUNSERVER" "1" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGC\-RUNSERVER" "1" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogc\-runserver\fR \- a simple HTTP server to test blogc websites
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc-source.7 new/blogc-0.13.9/blogc-source.7
--- old/blogc-0.13.6/blogc-source.7     2018-05-14 22:53:08.000000000 +0200
+++ new/blogc-0.13.9/blogc-source.7     2018-06-13 00:21:10.000000000 +0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGC\-SOURCE" "7" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGC\-SOURCE" "7" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogc\-source\fR \- blogc\'s source file format
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc-template.7 new/blogc-0.13.9/blogc-template.7
--- old/blogc-0.13.6/blogc-template.7   2018-05-14 22:53:08.000000000 +0200
+++ new/blogc-0.13.9/blogc-template.7   2018-06-13 00:21:10.000000000 +0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGC\-TEMPLATE" "7" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGC\-TEMPLATE" "7" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogc\-template\fR \- blogc\'s template format
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc.1 new/blogc-0.13.9/blogc.1
--- old/blogc-0.13.6/blogc.1    2018-05-14 22:53:08.000000000 +0200
+++ new/blogc-0.13.9/blogc.1    2018-06-13 00:21:10.000000000 +0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGC" "1" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGC" "1" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogc\fR \- a blog compiler
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc.spec new/blogc-0.13.9/blogc.spec
--- old/blogc-0.13.6/blogc.spec 2018-05-14 22:53:07.000000000 +0200
+++ new/blogc-0.13.9/blogc.spec 2018-06-13 00:21:09.000000000 +0200
@@ -1,11 +1,11 @@
 Name: blogc
-Version: 0.13.6
+Version: 0.13.9
 Release: 1%{?dist}
 License: BSD
 Group: Applications/Text
 Summary: A blog compiler
 URL: https://blogc.rgm.io/
-Source0: 
https://github.com/blogc/blogc/releases/download/v0.13.6/blogc-0.13.6.tar.xz
+Source0: 
https://github.com/blogc/blogc/releases/download/v0.13.9/blogc-0.13.9.tar.xz
 BuildRequires: libcmocka-devel, bash, coreutils, diffutils
 %if ! 0%{?el6}
 BuildRequires: git, tar, make
@@ -43,7 +43,7 @@
 blogc-runserver is a simple HTTP server to test blogc websites.
 
 %prep
-%setup -q -n blogc-0.13.6
+%setup -q -n blogc-0.13.9
 
 %build
 %if 0%{?el6}
@@ -88,6 +88,15 @@
 %license LICENSE
 
 %changelog
+* Tue Jun 12 2018 Rafael G. Martins <[email protected]> 0.13.9-1
+- New release.
+
+* Sun Jun 10 2018 Rafael G. Martins <[email protected]> 0.13.8-1
+- New release.
+
+* Sun Jun 10 2018 Rafael G. Martins <[email protected]> 0.13.7-1
+- New release.
+
 * Mon May 14 2018 Rafael G. Martins <[email protected]> 0.13.6-1
 - New release.
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogc.spec.in new/blogc-0.13.9/blogc.spec.in
--- old/blogc-0.13.6/blogc.spec.in      2018-05-14 22:52:33.000000000 +0200
+++ new/blogc-0.13.9/blogc.spec.in      2018-06-13 00:20:43.000000000 +0200
@@ -88,6 +88,15 @@
 %license LICENSE
 
 %changelog
+* Tue Jun 12 2018 Rafael G. Martins <[email protected]> 0.13.9-1
+- New release.
+
+* Sun Jun 10 2018 Rafael G. Martins <[email protected]> 0.13.8-1
+- New release.
+
+* Sun Jun 10 2018 Rafael G. Martins <[email protected]> 0.13.7-1
+- New release.
+
 * Mon May 14 2018 Rafael G. Martins <[email protected]> 0.13.6-1
 - New release.
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/blogcfile.5 new/blogc-0.13.9/blogcfile.5
--- old/blogc-0.13.6/blogcfile.5        2018-05-14 22:53:09.000000000 +0200
+++ new/blogc-0.13.9/blogcfile.5        2018-06-13 00:21:10.000000000 +0200
@@ -1,7 +1,7 @@
 .\" generated with Ronn/v0.7.3
 .\" http://github.com/rtomayko/ronn/tree/0.7.3
 .
-.TH "BLOGCFILE" "5" "May 2018" "Rafael G. Martins" "blogc Manual"
+.TH "BLOGCFILE" "5" "June 2018" "Rafael G. Martins" "blogc Manual"
 .
 .SH "NAME"
 \fBblogcfile\fR \- blogc\-make\'s configuration file
@@ -53,7 +53,7 @@
 .
 .TP
 \fBatom_posts_per_page\fR (default: \fB10\fR)
-Number of posts per page in the Atom feeds\. If negative, all the posts are 
included\. If \fB0\fR, no posts are include\.
+Number of posts per page in the Atom feeds\. If negative, all the posts are 
included\. If \fB0\fR, no Atom feeds are generated\.
 .
 .TP
 \fBatom_prefix\fR (default: \fBatom\fR)
@@ -97,7 +97,7 @@
 .
 .TP
 \fBposts_per_page\fR (default: \fB10\fR)
-Number of posts per page in the pagination pages\. If negative, all the posts 
are included\. If \fB0\fR, no posts are included\. Also, if negative or 
\fB0\fR, the \fBpagination\fR build rule is disabled\.
+Number of posts per page in the pagination pages\. If negative, all the posts 
are included\. If \fB0\fR, no post listing pages are generated\. Also, if 
negative or \fB0\fR, the \fBpagination\fR build rule is disabled\.
 .
 .TP
 \fBsource_ext\fR (default: \fB\.txt\fR)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/man/blogc-git-receiver.1.ronn 
new/blogc-0.13.9/man/blogc-git-receiver.1.ronn
--- old/blogc-0.13.6/man/blogc-git-receiver.1.ronn      2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/man/blogc-git-receiver.1.ronn      2018-06-13 
00:20:43.000000000 +0200
@@ -29,7 +29,12 @@
 
 Now add ssh keys to `/home/blogc/.ssh/authorized_keys`. Every key in
 `authorized_keys` will be allowed to push to the git repositories, and even
-create new ones.
+create new ones. It is also possible to add `blogc-git-receiver` as a command 
in
+the `authorized_keys` file for each key, but this setup is slightly more 
tricky,
+as you may leak shell access to an user by mystake, if you forget to add the 
command
+to a key that should not have shell access. Only use this method if you don't 
have
+another option (e.g. in shared hosting environments that only provide one shell
+account), or if you know exactly what you are doing.
 
 Also, make sure to install all the dependencies required by the websites,
 including a web server. `blogc-git-receiver` can't handle web server virtual 
hosts.
@@ -43,7 +48,16 @@
 
 This will deploy the example to the server, creating a symlink to the built 
content
 in `/home/blogc/repos/blogs/blogc-example.git/htdocs`. This symlink should be 
used
-as the document root for the web server virtual host.
+as the document root for the web server virtual host. If this symlink can't be
+readed by your webserver for some reason, you can create it in some other 
directory
+by adding the full symlink path to the ~/blogc-git-receiver.ini configuration 
file:
+
+    $ $EDITOR ~/blogc-git-receiver.ini
+    [repo:blogs/blogc-example.git]
+    symlink=/path/to/my/symlink
+
+Do not duplicate the section if it already exists, just append the symlink 
path to
+it.
 
 ### Rebuild last successful build
 
@@ -97,13 +111,13 @@
 a simple INI-style file where each repository is represented by a section and 
the
 value of the `mirror` variable is the URL that should be used to push.
 
-To create the configuration file (recommended):
+Edit configuration file (recommended, do not duplicate the section if it 
already
+exists, just append the mirror to it):
 
     # su -s /bin/sh - blogc
-    $ cat > ~/blogc-git-receiver.ini <<EOF
+    $ $EDITOR ~/blogc-git-receiver.ini
     [repo:myblog.git]
     mirror=$YOUR_GIT_MIRROR_URL
-    EOF
 
 Or to add the `mirror` remote:
 
@@ -145,13 +159,32 @@
 WARNING: If you push manually and your server's repository is empty, you'll 
clean
 your mirror repository.
 
-## ENVIRONMENT VARIABLES
+## ENVIRONMENT
+
+The following variables can be set in the SSH Server (usually in 
`~/.ssh/environment`)
+to change `blogc-git-receiver` behaviour:
 
-`blogc-git-receiver` will export an environment variable called 
`BLOGC_GIT_RECEIVER`
-when calling `gmake` to build websites. This variable can be used to enable 
building
-of content that should only be built when running in production environment, 
for
-example. This variable will not be added when using blogc-make(1), whose 
builds are
-always considered to be "production" (blogc-make(1) is never called with `-D`).
+  * `BLOGC_GIT_RECEIVER_BASE_DIR`:
+    Path to the base directory that should be used by `blogc-git-receiver`. 
Defaults
+    to user's home directory. Useful for shared hosting environments that only 
provide
+    one shell user.
+  * `BLOGC_GIT_RECEIVER_BUILDS_DIR`:
+    Path to the directory that should be used to store the blogc builds. 
Defaults
+    to `$BLOGC_GIT_RECEIVER_BASE_DIR/builds`. This directory must be readable 
by
+    your webserver. This variable is useful to keep your git repositories 
unreadable,
+    while letting your webserver access the built files. In this case, users 
need to
+    also define custom symlinks for every repository in
+    `$BLOGC_GIT_RECEIVER_BASE_DIR/blogc-git-receiver.ini`, because the default
+    `htdocs` symlink inside the git repositories won't be acessible by the 
webserver.
+
+The following variable is exported by `blogc-git-receiver` when building 
websites
+with make(1):
+
+  * `BLOGC_GIT_RECEIVER=1`:
+    This variable can be used to enable building of content that should only be
+    built when running in production environment, for example. This variable 
will
+    not be exported when using blogc-make(1), whose builds are always 
considered to
+    be "production" (blogc-make(1) is never called with `-D`).
 
 ## BUGS
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/man/blogcfile.5.ronn new/blogc-0.13.9/man/blogcfile.5.ronn
--- old/blogc-0.13.6/man/blogcfile.5.ronn       2018-05-14 22:52:33.000000000 
+0200
+++ new/blogc-0.13.9/man/blogcfile.5.ronn       2018-06-13 00:20:43.000000000 
+0200
@@ -50,7 +50,7 @@
 
   * `atom_posts_per_page` (default: `10`):
     Number of posts per page in the Atom feeds. If negative, all the posts are
-    included. If `0`, no posts are include.
+    included. If `0`, no Atom feeds are generated.
 
   * `atom_prefix` (default: `atom`):
     The prefix of the generated Atom feeds. It is relative to the output
@@ -100,8 +100,8 @@
 
   * `posts_per_page` (default: `10`):
     Number of posts per page in the pagination pages. If negative, all the 
posts
-    are included. If `0`, no posts are included. Also, if negative or `0`, the
-    `pagination` build rule is disabled.
+    are included. If `0`, no post listing pages are generated. Also, if 
negative or
+    `0`, the `pagination` build rule is disabled.
 
   * `source_ext` (default: `.txt`):
     The extension of the source files.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-git-receiver/main.c 
new/blogc-0.13.9/src/blogc-git-receiver/main.c
--- old/blogc-0.13.6/src/blogc-git-receiver/main.c      2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/src/blogc-git-receiver/main.c      2018-06-13 
00:20:43.000000000 +0200
@@ -7,6 +7,7 @@
  */
 
 #include <stdio.h>
+#include <stdlib.h>
 #include <string.h>
 #include <libgen.h>
 #include "shell.h"
@@ -24,8 +25,19 @@
             return bgr_post_receive_hook(argc, argv);
     }
 
-    if (argc == 3 && (0 == strcmp(argv[1], "-c")))
+    if (argc == 3 && (0 == strcmp(argv[1], "-c"))) {
         return bgr_shell(argc, argv);
+    }
+
+    // this is a hack to make blogc-git-receiver work out-of-the-box as a
+    // `command=` in authorized_keys file. it will only work if the command
+    // path is absolute.
+    char *ssh_orig = getenv("SSH_ORIGINAL_COMMAND");
+    if (argc == 1 && ssh_orig != NULL && argv[0][0] == '/') {
+        setenv("SHELL", argv[0], 1);
+        char* _argv[3] = {argv[0], "-c", ssh_orig};
+        return bgr_shell(3, _argv);
+    }
 
     fprintf(stderr, "error: this is a special shell, go away!\n");
     return 3;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-git-receiver/post-receive.c 
new/blogc-0.13.9/src/blogc-git-receiver/post-receive.c
--- old/blogc-0.13.6/src/blogc-git-receiver/post-receive.c      2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/src/blogc-git-receiver/post-receive.c      2018-06-13 
00:20:43.000000000 +0200
@@ -10,38 +10,10 @@
 #include <libgen.h>
 #include <unistd.h>
 #include <stdlib.h>
-#include <string.h>
-#include <stdbool.h>
 #include "../common/utils.h"
 #include "../common/config-parser.h"
-#include "../common/error.h"
-#include "../common/file.h"
-
-
-char*
-bgr_post_receive_get_config_section(bc_config_t *config, const char *repo_path,
-    const char *home)
-{
-    char *rv = NULL;
-    char** sections = bc_config_list_sections(config);
-    for (size_t i = 0; sections[i] != NULL; i++) {
-        if (bc_str_starts_with(sections[i], "repo:")) {
-            char *tmp_repo = bc_strdup_printf("%s/repos/%s", home, sections[i] 
+ 5);
-            char *real_tmp_repo = realpath(tmp_repo, NULL);  // maybe not 
needed
-            free(tmp_repo);
-            if (real_tmp_repo == NULL)
-                continue;
-            if (0 == strcmp(real_tmp_repo, repo_path)) {
-                rv = bc_strdup(sections[i]);
-                free(real_tmp_repo);
-                break;
-            }
-            free(real_tmp_repo);
-        }
-    }
-    bc_strv_free(sections);
-    return rv;
-}
+#include "settings.h"
+#include "post-receive.h"
 
 
 int
@@ -76,53 +48,21 @@
         goto push;
     }
 
-    char *home = getenv("HOME");
-    if (home == NULL) {
-        fprintf(stderr, "warning: failed to find user home path, "
-            "mirroring disabled\n");
-        goto cleanup;
-    }
-
-    char *config_file = bc_strdup_printf("%s/blogc-git-receiver.ini", home);
-    if ((0 != access(config_file, F_OK))) {
+    bc_config_t *config = bgr_settings_parse();
+    if (config == NULL) {
         fprintf(stderr, "warning: repository mirroring disabled\n");
-        free(config_file);
-        goto cleanup;
-    }
-
-    size_t len;
-    bc_error_t *err = NULL;
-    char* config_content = bc_file_get_contents(config_file, true, &len, &err);
-    if (err != NULL) {
-        fprintf(stderr, "warning: failed to read configuration file (%s), "
-            "mirroring disabled: %s\n", config_file, err->msg);
-        bc_error_free(err);
-        free(config_file);
-        free(config_content);
-        goto cleanup;
-    }
-
-    bc_config_t *config = bc_config_parse(config_content, len, NULL, &err);
-    free(config_content);
-    if (err != NULL) {
-        fprintf(stderr, "warning: failed to parse configuration file (%s), "
-            "mirroring disabled: %s\n", config_file, err->msg);
-        bc_error_free(err);
-        free(config_file);
         goto cleanup;
     }
-    free(config_file);
 
-    char *config_section = bgr_post_receive_get_config_section(config, 
repo_path,
-        home);
-    if (config_section == NULL) {
+    char *section = bgr_settings_get_section(config, repo_path);
+    if (section == NULL) {
         fprintf(stderr, "warning: repository mirroring disabled\n");
         bc_config_free(config);
         goto cleanup;
     }
 
-    mirror = bc_strdup(bc_config_get(config, config_section, "mirror"));
-    free(config_section);
+    mirror = bc_strdup(bc_config_get(config, section, "mirror"));
+    free(section);
     bc_config_free(config);
 
     if (mirror == NULL) {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-git-receiver/post-receive.h 
new/blogc-0.13.9/src/blogc-git-receiver/post-receive.h
--- old/blogc-0.13.6/src/blogc-git-receiver/post-receive.h      2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/src/blogc-git-receiver/post-receive.h      2018-06-13 
00:20:43.000000000 +0200
@@ -9,10 +9,6 @@
 #ifndef _POST_RECEIVE_H
 #define _POST_RECEIVE_H
 
-#include "../common/config-parser.h"
-
-char* bgr_post_receive_get_config_section(bc_config_t *config,
-    const char *repo_path, const char *home);
 int bgr_post_receive_hook(int argc, char *argv[]);
 
 #endif /* _POST_RECEIVE_H */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-git-receiver/pre-receive.c 
new/blogc-0.13.9/src/blogc-git-receiver/pre-receive.c
--- old/blogc-0.13.6/src/blogc-git-receiver/pre-receive.c       2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/src/blogc-git-receiver/pre-receive.c       2018-06-13 
00:20:43.000000000 +0200
@@ -18,6 +18,7 @@
 #include "../common/compat.h"
 #include "../common/utils.h"
 #include "../common/stdin.h"
+#include "settings.h"
 #include "pre-receive-parser.h"
 #include "pre-receive.h"
 
@@ -95,6 +96,7 @@
     char *master = NULL;
     char *output_dir = NULL;
     char *tmpdir = NULL;
+    char *sym = NULL;
 
     char *hooks_dir = dirname(argv[0]);  // this was validated by main()
     char *real_hooks_dir = realpath(hooks_dir, NULL);
@@ -111,17 +113,43 @@
         goto cleanup;
     }
 
+    bc_config_t *config = bgr_settings_parse();
+    if (config == NULL) {
+        goto default_sym;
+    }
+
+    char *section = bgr_settings_get_section(config, repo_dir);
+    if (section == NULL) {
+        bc_config_free(config);
+        goto default_sym;
+    }
+
+    const char *sym_tmp = bc_config_get(config, section, "symlink");
+    if (sym_tmp == NULL) {
+        free(section);
+        bc_config_free(config);
+        goto default_sym;
+    }
+
+    sym = bc_str_starts_with(sym_tmp, "/") ? bc_strdup(sym_tmp) :
+            bc_strdup_printf("%s/%s", repo_dir, sym_tmp);
+    free(section);
+    bc_config_free(config);
+
+default_sym:
+
+    if (sym == NULL) {
+        sym = bc_strdup_printf("%s/htdocs", repo_dir);
+    }
+
     if (NULL == getenv("GIT_DIR")) {
-        char *htdocs_sym = bc_strdup_printf("%s/htdocs", repo_dir);
-        if (0 != access(htdocs_sym, R_OK)) {
+        if (0 != access(sym, R_OK)) {
             fprintf(stderr, "error: no previous build found. nothing to "
                 "rebuild.\n");
-            free(htdocs_sym);
             rv = 3;
             goto cleanup;
         }
-        char *build_dir = realpath(htdocs_sym, NULL);
-        free(htdocs_sym);
+        char *build_dir = realpath(sym, NULL);
         if (build_dir == NULL) {
             fprintf(stderr, "error: failed to get the hash of last built "
                 "commit.\n");
@@ -177,15 +205,16 @@
         goto cleanup;
     }
 
-    char *home = getenv("HOME");
-    if (home == NULL) {
-        fprintf(stderr, "error: failed to find user home path\n");
+    char *buildsd = bgr_settings_get_builds_dir();
+    if (buildsd == NULL) {
+        fprintf(stderr, "error: failed to find builds directory path\n");
         rv = 3;
         goto cleanup;
     }
 
     unsigned long epoch = time(NULL);
-    output_dir = bc_strdup_printf("%s/builds/%s-%lu", home, master, epoch);
+    output_dir = bc_strdup_printf("%s/%s-%lu", buildsd, master, epoch);
+    free(buildsd);
 
     if (0 == access(output_dir, F_OK)) {
         char *tmp = output_dir;
@@ -245,26 +274,18 @@
     }
     free(build_cmd);
 
-    if (0 != chdir(repo_dir)) {
-        fprintf(stderr, "error: failed to chdir (%s): %s\n", repo_dir,
+    char *htdocs_sym = realpath(sym, NULL);
+    if ((htdocs_sym != NULL) && (0 != unlink(sym))) {
+        fprintf(stderr, "error: failed to remove symlink (%s): %s\n", sym,
             strerror(errno));
         rmdir_recursive(output_dir);
         rv = 3;
-        goto cleanup;
-    }
-
-    char *htdocs_sym = realpath("htdocs", NULL);
-    if ((htdocs_sym != NULL) && (0 != unlink("htdocs"))) {
-        fprintf(stderr, "error: failed to remove symlink (%s/htdocs): %s\n",
-            repo_dir, strerror(errno));
-        rmdir_recursive(output_dir);
-        rv = 3;
         goto cleanup2;
     }
 
-    if (0 != symlink(output_dir, "htdocs")) {
-        fprintf(stderr, "error: failed to create symlink (%s/htdocs): %s\n",
-            repo_dir, strerror(errno));
+    if (0 != symlink(output_dir, sym)) {
+        fprintf(stderr, "error: failed to create symlink (%s): %s\n", sym,
+            strerror(errno));
         rmdir_recursive(output_dir);
         rv = 3;
         goto cleanup2;
@@ -277,6 +298,7 @@
     free(htdocs_sym);
 
 cleanup:
+    free(sym);
     free(master);
     free(output_dir);
     rmdir_recursive(tmpdir);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-git-receiver/settings.c 
new/blogc-0.13.9/src/blogc-git-receiver/settings.c
--- old/blogc-0.13.6/src/blogc-git-receiver/settings.c  1970-01-01 
01:00:00.000000000 +0100
+++ new/blogc-0.13.9/src/blogc-git-receiver/settings.c  2018-06-13 
00:20:43.000000000 +0200
@@ -0,0 +1,110 @@
+/*
+ * blogc: A blog compiler.
+ * Copyright (C) 2014-2017 Rafael G. Martins <[email protected]>
+ *
+ * This program can be distributed under the terms of the BSD License.
+ * See the file LICENSE.
+ */
+
+#include <stdio.h>
+#include <libgen.h>
+#include <unistd.h>
+#include <stdlib.h>
+#include <string.h>
+#include <stdbool.h>
+#include "../common/utils.h"
+#include "../common/config-parser.h"
+#include "../common/error.h"
+#include "../common/file.h"
+#include "settings.h"
+
+
+const char*
+bgr_settings_get_base_dir(void)
+{
+    char *rv = getenv("BLOGC_GIT_RECEIVER_BASE_DIR");
+    if (rv != NULL) {
+        return rv;
+    }
+    return getenv("HOME");
+}
+
+
+char*
+bgr_settings_get_builds_dir(void)
+{
+    char *rv = getenv("BLOGC_GIT_RECEIVER_BUILDS_DIR");
+    if (rv != NULL) {
+        return bc_strdup(rv);
+    }
+    return bc_strdup_printf("%s/builds", bgr_settings_get_base_dir());
+}
+
+
+char*
+bgr_settings_get_section(bc_config_t *config, const char *repo_path)
+{
+    const char *bd = bgr_settings_get_base_dir();
+    if (bd == NULL) {
+        return NULL;
+    }
+    char *rv = NULL;
+    char** sections = bc_config_list_sections(config);
+    for (size_t i = 0; sections[i] != NULL; i++) {
+        if (bc_str_starts_with(sections[i], "repo:")) {
+            char *tmp_repo = bc_strdup_printf("%s/repos/%s", bd, sections[i] + 
5);
+            char *real_tmp_repo = realpath(tmp_repo, NULL);  // maybe not 
needed
+            free(tmp_repo);
+            if (real_tmp_repo == NULL)
+                continue;
+            if (0 == strcmp(real_tmp_repo, repo_path)) {
+                rv = bc_strdup(sections[i]);
+                free(real_tmp_repo);
+                break;
+            }
+            free(real_tmp_repo);
+        }
+    }
+    bc_strv_free(sections);
+    return rv;
+}
+
+
+bc_config_t*
+bgr_settings_parse(void)
+{
+    const char *bd = bgr_settings_get_base_dir();
+    if (bd == NULL) {
+        return NULL;
+    }
+    char *config_file = bc_strdup_printf("%s/blogc-git-receiver.ini", bd);
+    if ((0 != access(config_file, F_OK))) {
+        free(config_file);
+        return NULL;
+    }
+
+    size_t len;
+    bc_error_t *err = NULL;
+    char* config_content = bc_file_get_contents(config_file, true, &len, &err);
+    if (err != NULL) {
+        fprintf(stderr, "warning: failed to read configuration file (%s): 
%s\n",
+            config_file, err->msg);
+        bc_error_free(err);
+        free(config_file);
+        free(config_content);
+        return NULL;
+    }
+
+    bc_config_t *config = bc_config_parse(config_content, len, NULL, &err);
+    free(config_content);
+    if (err != NULL) {
+        fprintf(stderr, "warning: failed to parse configuration file (%s): 
%s\n",
+            config_file, err->msg);
+        bc_error_free(err);
+        free(config_file);
+        return NULL;
+    }
+    free(config_file);
+
+    return config;
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-git-receiver/settings.h 
new/blogc-0.13.9/src/blogc-git-receiver/settings.h
--- old/blogc-0.13.6/src/blogc-git-receiver/settings.h  1970-01-01 
01:00:00.000000000 +0100
+++ new/blogc-0.13.9/src/blogc-git-receiver/settings.h  2018-06-13 
00:20:43.000000000 +0200
@@ -0,0 +1,19 @@
+/*
+ * blogc: A blog compiler.
+ * Copyright (C) 2014-2017 Rafael G. Martins <[email protected]>
+ *
+ * This program can be distributed under the terms of the BSD License.
+ * See the file LICENSE.
+ */
+
+#ifndef _SETTINGS_H
+#define _SETTINGS_H
+
+#include "../common/config-parser.h"
+
+const char* bgr_settings_get_base_dir(void);
+char* bgr_settings_get_builds_dir(void);
+char* bgr_settings_get_section(bc_config_t *config, const char *repo_path);
+bc_config_t* bgr_settings_parse(void);
+
+#endif /* _SETTINGS_H */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-git-receiver/shell.c 
new/blogc-0.13.9/src/blogc-git-receiver/shell.c
--- old/blogc-0.13.6/src/blogc-git-receiver/shell.c     2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/src/blogc-git-receiver/shell.c     2018-06-13 
00:20:43.000000000 +0200
@@ -14,10 +14,22 @@
 #include <errno.h>
 #include <sys/stat.h>
 #include "../common/utils.h"
+#include "settings.h"
 #include "shell-command-parser.h"
 #include "shell.h"
 
 
+static bool
+lexists(const char *pathname)
+{
+    struct stat b;
+    int tmp_errno = errno;
+    bool rv = lstat(pathname, &b) == 0;
+    errno = tmp_errno;
+    return rv;
+}
+
+
 int
 bgr_shell(int argc, char *argv[])
 {
@@ -34,10 +46,10 @@
         goto cleanup;
     }
 
-    // get home path
-    char *home = getenv("HOME");
-    if (home == NULL) {
-        fprintf(stderr, "error: failed to find user home path\n");
+    // get base dir path
+    const char *bd = bgr_settings_get_base_dir();
+    if (bd == NULL) {
+        fprintf(stderr, "error: failed to find base directory path\n");
         rv = 3;
         goto cleanup;
     }
@@ -50,7 +62,7 @@
         goto cleanup;
     }
 
-    repo = bc_strdup_printf("%s/repos/%s", home, tmp_repo);
+    repo = bc_strdup_printf("%s/repos/%s", bd, tmp_repo);
     quoted_repo = bc_shell_quote(repo);
     free(tmp_repo);
 
@@ -95,7 +107,7 @@
         goto cleanup;
     }
 
-    if (0 == access("pre-receive", F_OK)) {
+    if (lexists("pre-receive")) {
         if (0 != unlink("pre-receive")) {
             fprintf(stderr, "error: failed to remove old symlink "
                 "(%s/hooks/pre-receive): %s\n", repo, strerror(errno));
@@ -111,7 +123,7 @@
         goto cleanup;
     }
 
-    if (0 == access("post-receive", F_OK)) {
+    if (lexists("post-receive")) {
         if (0 != unlink("post-receive")) {
             fprintf(stderr, "error: failed to remove old symlink "
                 "(%s/hooks/post-receive): %s\n", repo, strerror(errno));
@@ -129,9 +141,8 @@
 
 git_exec:
 
-    if (0 != chdir(home)) {
-        fprintf(stderr, "error: failed to chdir (%s): %s\n", home,
-            strerror(errno));
+    if (0 != chdir(bd)) {
+        fprintf(stderr, "error: failed to chdir (%s): %s\n", bd, 
strerror(errno));
         rv = 3;
         goto cleanup;
     }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/src/blogc-make/rules.c new/blogc-0.13.9/src/blogc-make/rules.c
--- old/blogc-0.13.6/src/blogc-make/rules.c     2018-05-14 22:52:33.000000000 
+0200
+++ new/blogc-0.13.9/src/blogc-make/rules.c     2018-06-13 00:20:43.000000000 
+0200
@@ -53,6 +53,19 @@
 }
 
 
+static bool
+posts_pagination_enabled(bm_ctx_t *ctx, const  char *variable)
+{
+    if (ctx == NULL || ctx->settings == NULL || ctx->settings->settings == 
NULL)
+        return false;
+
+    long posts_per_page = strtol(
+        bc_trie_lookup(ctx->settings->settings, variable),
+        NULL, 10);  // FIXME: improve
+    return posts_per_page != 0;
+}
+
+
 // INDEX RULE
 
 static bc_slist_t*
@@ -61,6 +74,9 @@
     if (ctx == NULL || ctx->settings->posts == NULL)
         return NULL;
 
+    if (!posts_pagination_enabled(ctx, "posts_per_page"))
+        return NULL;
+
     bc_slist_t *rv = NULL;
     const char *html_ext = bc_trie_lookup(ctx->settings->settings,
         "html_ext");
@@ -119,6 +135,9 @@
     if (ctx == NULL || ctx->settings->posts == NULL)
         return NULL;
 
+    if (!posts_pagination_enabled(ctx, "atom_posts_per_page"))
+        return NULL;
+
     bc_slist_t *rv = NULL;
     const char *atom_prefix = bc_trie_lookup(ctx->settings->settings,
         "atom_prefix");
@@ -173,6 +192,9 @@
     if (ctx == NULL || ctx->settings->posts == NULL || ctx->settings->tags == 
NULL)
         return NULL;
 
+    if (!posts_pagination_enabled(ctx, "atom_posts_per_page"))
+        return NULL;
+
     bc_slist_t *rv = NULL;
     const char *atom_prefix = bc_trie_lookup(ctx->settings->settings,
         "atom_prefix");
@@ -234,13 +256,15 @@
     if (ctx == NULL || ctx->settings->posts == NULL)
         return NULL;
 
-    long num_posts = bc_slist_length(ctx->posts_fctx);
+    // not using posts_pagination_enabled() here because we need to calculate
+    // posts per page here anyway, and the condition is different.
     long posts_per_page = strtol(
         bc_trie_lookup(ctx->settings->settings, "posts_per_page"),
         NULL, 10);  // FIXME: improve
     if (posts_per_page <= 0)
         return NULL;
 
+    long num_posts = bc_slist_length(ctx->posts_fctx);
     size_t pages = ceilf(((float) num_posts) / posts_per_page);
 
     const char *pagination_prefix = bc_trie_lookup(ctx->settings->settings,
@@ -374,6 +398,9 @@
     if (ctx == NULL || ctx->settings->posts == NULL || ctx->settings->tags == 
NULL)
         return NULL;
 
+    if (!posts_pagination_enabled(ctx, "posts_per_page"))
+        return NULL;
+
     bc_slist_t *rv = NULL;
     const char *tag_prefix = bc_trie_lookup(ctx->settings->settings,
         "tag_prefix");
@@ -397,7 +424,7 @@
     size_t i = 0;
 
     bc_trie_t *variables = bc_trie_new(free);
-    posts_pagination(ctx, variables, "atom_posts_per_page");
+    posts_pagination(ctx, variables, "posts_per_page");
     posts_ordering(ctx, variables, "html_order");
     bc_trie_insert(variables, "DATE_FORMAT",
         bc_strdup(bc_trie_lookup(ctx->settings->settings, "date_format")));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/tests/blogc-git-receiver/check_post_receive.c 
new/blogc-0.13.9/tests/blogc-git-receiver/check_post_receive.c
--- old/blogc-0.13.6/tests/blogc-git-receiver/check_post_receive.c      
2018-05-14 22:52:33.000000000 +0200
+++ new/blogc-0.13.9/tests/blogc-git-receiver/check_post_receive.c      
1970-01-01 01:00:00.000000000 +0100
@@ -1,91 +0,0 @@
-/*
- * blogc: A blog compiler.
- * Copyright (C) 2014-2017 Rafael G. Martins <[email protected]>
- *
- * This program can be distributed under the terms of the BSD License.
- * See the file LICENSE.
- */
-
-#include <stdarg.h>
-#include <stddef.h>
-#include <setjmp.h>
-#include <cmocka.h>
-#include <string.h>
-#include <stdlib.h>
-#include "../../src/common/config-parser.h"
-#include "../../src/common/utils.h"
-#include "../../src/blogc-git-receiver/post-receive.h"
-
-
-char*
-__wrap_realpath(const char *path, char *resolved_path)
-{
-    const char *real_path = mock_type(const char*);
-    if (real_path == NULL)
-        return NULL;
-    assert_string_equal(path, real_path);
-    return bc_strdup(real_path);
-}
-
-
-static void
-test_post_receive_get_config_section(void **state)
-{
-    bc_error_t *err = NULL;
-
-    bc_config_t *config = bc_config_parse("", 0, NULL, &err);
-    assert_null(err);
-    assert_null(bgr_post_receive_get_config_section(config,
-        "/home/blogc/repos/foo.git", "/home/blogc"));
-    bc_config_free(config);
-
-    will_return(__wrap_realpath, NULL);
-    will_return(__wrap_realpath, "/home/blogc/repos/bar.git");
-    const char *conf =
-        "[repo:foo.git]\n"
-        "mirror = foo\n"
-        "\n"
-        "[repo:bar.git]\n"
-        "mirror = bar\n"
-        "\n"
-        "[repo:baz.git]\n"
-        "mirror = baz\n"
-        "\n";
-    config = bc_config_parse(conf, strlen(conf), NULL, &err);
-    assert_null(err);
-    char *s = bgr_post_receive_get_config_section(config,
-        "/home/blogc/repos/bar.git", "/home/blogc");
-    assert_string_equal(s, "repo:bar.git");
-    free(s);
-    bc_config_free(config);
-
-    will_return(__wrap_realpath, NULL);
-    will_return(__wrap_realpath, "/home/blogc/repos/asd/bar.git");
-    conf =
-        "[repo:asd/foo.git]\n"
-        "mirror = foo\n"
-        "\n"
-        "[repo:asd/bar.git]\n"
-        "mirror = bar\n"
-        "\n"
-        "[repo:asd/baz.git]\n"
-        "mirror = baz\n"
-        "\n";
-    config = bc_config_parse(conf, strlen(conf), NULL, &err);
-    assert_null(err);
-    s = bgr_post_receive_get_config_section(config,
-        "/home/blogc/repos/asd/bar.git", "/home/blogc");
-    assert_string_equal(s, "repo:asd/bar.git");
-    free(s);
-    bc_config_free(config);
-}
-
-
-int
-main(void)
-{
-    const UnitTest tests[] = {
-        unit_test(test_post_receive_get_config_section),
-    };
-    return run_tests(tests);
-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/tests/blogc-git-receiver/check_post_receive.sh.in 
new/blogc-0.13.9/tests/blogc-git-receiver/check_post_receive.sh.in
--- old/blogc-0.13.6/tests/blogc-git-receiver/check_post_receive.sh.in  
2018-05-14 22:52:33.000000000 +0200
+++ new/blogc-0.13.9/tests/blogc-git-receiver/check_post_receive.sh.in  
2018-06-13 00:20:43.000000000 +0200
@@ -110,7 +110,7 @@
 mirror = lol
 EOF
 git init --bare "${TEMP}/repos/bar6.git" &> /dev/null
-HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./repos/foo.git/hooks/post-receive 2>&1 | 
tee "${TEMP}/output.txt"
+BLOGC_GIT_RECEIVER_BASE_DIR="${TEMP}" ${TESTS_ENVIRONMENT} 
./repos/foo.git/hooks/post-receive 2>&1 | tee "${TEMP}/output.txt"
 grep "[new branch] *master" "${TEMP}/output.txt" &> /dev/null
 
 rm "${TEMP}/output.txt"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/tests/blogc-git-receiver/check_pre_receive.sh.in 
new/blogc-0.13.9/tests/blogc-git-receiver/check_pre_receive.sh.in
--- old/blogc-0.13.6/tests/blogc-git-receiver/check_pre_receive.sh.in   
2018-05-14 22:52:33.000000000 +0200
+++ new/blogc-0.13.9/tests/blogc-git-receiver/check_pre_receive.sh.in   
2018-06-13 00:20:43.000000000 +0200
@@ -93,13 +93,111 @@
 0000000000000000000000000000000000000000 
0000000000000000000000000000000000000000 refs/heads/bar
 EOF
 
-SHELL="${SELF}" HOME="${TEMP}" GIT_DIR=. ${TESTS_ENVIRONMENT} 
./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt"
+cat > "${TEMP}/blogc-git-receiver.ini" <<EOF
+[repo:foo2a.git]
+symlink = ${TEMP}/guda
+EOF
+
+SHELL="${SELF}" HOME="${TEMP}" GIT_DIR=. 
BLOGC_GIT_RECEIVER_BUILDS_DIR="${TEMP}/foooo" ${TESTS_ENVIRONMENT} 
./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt"
 grep "echo lol" "${TEMP}/output.txt" &> /dev/null
 
 [[ -h htdocs ]]
 [[ "$(cat htdocs/foo.txt)" == "lol" ]]
 
-DEST="$(readlink htdocs)"
+cat >> "${TEMP}/blogc-git-receiver.ini" <<EOF
+[repo:foo2.git]
+EOF
+
+SHELL="${SELF}" HOME="${TEMP}" GIT_DIR=. 
BLOGC_GIT_RECEIVER_BUILDS_DIR="${TEMP}/foooo" ${TESTS_ENVIRONMENT} 
./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt"
+grep "echo lol" "${TEMP}/output.txt" &> /dev/null
+
+[[ -h htdocs ]]
+[[ "$(cat htdocs/foo.txt)" == "lol" ]]
+
+cat >> "${TEMP}/blogc-git-receiver.ini" <<EOF
+symlink = ${TEMP}/chunda
+EOF
+
+SHELL="${SELF}" HOME="${TEMP}" GIT_DIR=. 
BLOGC_GIT_RECEIVER_BUILDS_DIR="${TEMP}/foooo" ${TESTS_ENVIRONMENT} 
./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt"
+grep "echo lol" "${TEMP}/output.txt" &> /dev/null
+
+[[ -h "${TEMP}/chunda" ]]
+[[ "$(cat "${TEMP}/chunda/foo.txt")" == "lol" ]]
+
+DEST="$(readlink "${TEMP}/chunda")"
+[[ -e "${DEST}" ]]
+[[ "${DEST}" == "${TEMP}/foooo/"* ]]
+
+cd "${TEMP}"
+git init --bare "${TEMP}/repos/foo2a.git" &> /dev/null
+ln -s "${SELF}" "${TEMP}/repos/foo2a.git/hooks/pre-receive"
+
+cat > "${TEMP}/tmp.txt" <<EOF
+blob
+mark :1
+data 64
+all:
+       mkdir -p \$(OUTPUT_DIR)
+       echo lol > \$(OUTPUT_DIR)/foo.txt
+
+
+commit refs/heads/master
+mark :2
+author Rafael G. Martins <[email protected]> 1476142917 +0200
+committer Rafael G. Martins <[email protected]> 1476142917 +0200
+data 12
+testing2...
+M 100644 :1 Makefile
+
+EOF
+
+cd "${TEMP}/repos/foo2a.git"
+ln -s "${DEST}" "${TEMP}/guda"
+git fast-import < "${TEMP}/tmp.txt" &> /dev/null
+
+cat > "${TEMP}/payload.txt" <<EOF
+0000000000000000000000000000000000000000 
0000000000000000000000000000000000000000 refs/heads/foo
+0000000000000000000000000000000000000000 $(git rev-parse HEAD) 
refs/heads/master
+0000000000000000000000000000000000000000 
0000000000000000000000000000000000000000 refs/heads/bar
+EOF
+
+SHELL="${SELF}" HOME="${TEMP}" GIT_DIR=. ${TESTS_ENVIRONMENT} 
./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt"
+grep "echo lol" "${TEMP}/output.txt" &> /dev/null
+
+[[ -h "${TEMP}/guda" ]]
+[[ "$(cat "${TEMP}/guda/foo.txt")" == "lol" ]]
+[[ "${DEST}" != "$(readlink "${TEMP}/guda")" ]]
+[[ ! -e "${DEST}" ]]
+
+DEST="$(readlink "${TEMP}/guda")"
+HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./hooks/pre-receive 2>&1 | tee 
"${TEMP}/output.txt"
+
+[[ -h "${TEMP}/guda" ]]
+[[ "$(cat "${TEMP}/guda/foo.txt")" == "lol" ]]
+[[ "${DEST}" != "$(readlink "${TEMP}/guda")" ]]
+[[ ! -e "${DEST}" ]]
+
+cd ..
+
+DEST="$(readlink "${TEMP}/guda")"
+HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./foo2a.git/hooks/pre-receive 2>&1 | tee 
"${TEMP}/output.txt"
+
+[[ -h "${TEMP}/guda" ]]
+[[ "$(cat "${TEMP}/guda/foo.txt")" == "lol" ]]
+[[ "${DEST}" != "$(readlink "${TEMP}/guda")" ]]
+[[ ! -e "${DEST}" ]]
+
+cd ..
+
+DEST="$(readlink "${TEMP}/guda")"
+HOME="${TEMP}" ${TESTS_ENVIRONMENT} ./repos/foo2a.git/hooks/pre-receive 2>&1 | 
tee "${TEMP}/output.txt"
+
+[[ -h "${TEMP}/guda" ]]
+[[ "$(cat "${TEMP}/guda/foo.txt")" == "lol" ]]
+[[ "${DEST}" != "$(readlink "${TEMP}/guda")" ]]
+[[ ! -e "${DEST}" ]]
+
+DEST="$(readlink "${TEMP}/guda")"
 [[ -e "${DEST}" ]]
 
 cd "${TEMP}"
@@ -199,7 +297,7 @@
 0000000000000000000000000000000000000000 $(git rev-parse HEAD) 
refs/heads/master
 EOF
 
-    SHELL="${SELF}" HOME="${TEMP}" PATH="@abs_top_builddir@:${PATH}" GIT_DIR=. 
${TESTS_ENVIRONMENT} ./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee 
"${TEMP}/output.txt" || true
+    SHELL="${SELF}" BLOGC_GIT_RECEIVER_BASE_DIR="${TEMP}" 
PATH="@abs_top_builddir@:${PATH}" GIT_DIR=. ${TESTS_ENVIRONMENT} 
./hooks/pre-receive < "${TEMP}/payload.txt" 2>&1 | tee "${TEMP}/output.txt" || 
true
     grep "blogc-make: error: settings: " "${TEMP}/output.txt" &> /dev/null
 fi
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/tests/blogc-git-receiver/check_settings.c 
new/blogc-0.13.9/tests/blogc-git-receiver/check_settings.c
--- old/blogc-0.13.6/tests/blogc-git-receiver/check_settings.c  1970-01-01 
01:00:00.000000000 +0100
+++ new/blogc-0.13.9/tests/blogc-git-receiver/check_settings.c  2018-06-13 
00:20:43.000000000 +0200
@@ -0,0 +1,91 @@
+/*
+ * blogc: A blog compiler.
+ * Copyright (C) 2014-2017 Rafael G. Martins <[email protected]>
+ *
+ * This program can be distributed under the terms of the BSD License.
+ * See the file LICENSE.
+ */
+
+#include <stdarg.h>
+#include <stddef.h>
+#include <setjmp.h>
+#include <cmocka.h>
+#include <string.h>
+#include <stdlib.h>
+#include "../../src/common/config-parser.h"
+#include "../../src/common/utils.h"
+#include "../../src/blogc-git-receiver/settings.h"
+
+
+char*
+__wrap_realpath(const char *path, char *resolved_path)
+{
+    const char *real_path = mock_type(const char*);
+    if (real_path == NULL)
+        return NULL;
+    assert_string_equal(path, real_path);
+    return bc_strdup(real_path);
+}
+
+
+static void
+test_settings_get_section(void **state)
+{
+    bc_error_t *err = NULL;
+
+    setenv("HOME", "/home/blogc", 1);
+
+    bc_config_t *config = bc_config_parse("", 0, NULL, &err);
+    assert_null(err);
+    assert_null(bgr_settings_get_section(config, "/home/blogc/repos/foo.git"));
+    bc_config_free(config);
+
+    will_return(__wrap_realpath, NULL);
+    will_return(__wrap_realpath, "/home/blogc/repos/bar.git");
+    const char *conf =
+        "[repo:foo.git]\n"
+        "mirror = foo\n"
+        "\n"
+        "[repo:bar.git]\n"
+        "mirror = bar\n"
+        "\n"
+        "[repo:baz.git]\n"
+        "mirror = baz\n"
+        "\n";
+    config = bc_config_parse(conf, strlen(conf), NULL, &err);
+    assert_null(err);
+    char *s = bgr_settings_get_section(config, "/home/blogc/repos/bar.git");
+    assert_string_equal(s, "repo:bar.git");
+    free(s);
+    bc_config_free(config);
+
+    setenv("BLOGC_GIT_RECEIVER_BASE_DIR", "/home/bola", 1);
+    will_return(__wrap_realpath, NULL);
+    will_return(__wrap_realpath, "/home/bola/repos/asd/bar.git");
+    conf =
+        "[repo:asd/foo.git]\n"
+        "mirror = foo\n"
+        "\n"
+        "[repo:asd/bar.git]\n"
+        "mirror = bar\n"
+        "\n"
+        "[repo:asd/baz.git]\n"
+        "mirror = baz\n"
+        "\n";
+    config = bc_config_parse(conf, strlen(conf), NULL, &err);
+    assert_null(err);
+    s = bgr_settings_get_section(config, "/home/bola/repos/asd/bar.git");
+    assert_string_equal(s, "repo:asd/bar.git");
+    free(s);
+    bc_config_free(config);
+}
+
+
+int
+main(void)
+{
+    const UnitTest tests[] = {
+        unit_test(test_settings_get_section),
+    };
+    return run_tests(tests);
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/tests/blogc-git-receiver/check_shell.sh.in 
new/blogc-0.13.9/tests/blogc-git-receiver/check_shell.sh.in
--- old/blogc-0.13.6/tests/blogc-git-receiver/check_shell.sh.in 2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/tests/blogc-git-receiver/check_shell.sh.in 2018-06-13 
00:20:43.000000000 +0200
@@ -36,6 +36,21 @@
 [[ -h "${TEMP}/repos/lol.git/hooks/post-receive" ]]
 [[ "$(readlink "${TEMP}/repos/lol.git/hooks/post-receive")" == "${SELF}" ]]
 
+rm "${TEMP}/repos/lol.git/hooks/pre-receive"
+ln -s /lolheheasdxd "${TEMP}/repos/lol.git/hooks/pre-receive"
+
+echo 0000 | call_bgr -c "git-receive-pack 'lol.git'" 2>&1 > 
"${TEMP}/output.txt"
+if [[ -n "${VALGRIND}" ]]; then
+    grep "git-shell -c \"git-receive-pack '.*repos/lol.git'\"" 
"${TEMP}/output.txt" &> /dev/null
+else
+    grep "agent=" "${TEMP}/output.txt" &> /dev/null
+fi
+[[ -d "${TEMP}/repos/lol.git" ]]
+[[ -h "${TEMP}/repos/lol.git/hooks/pre-receive" ]]
+[[ "$(readlink "${TEMP}/repos/lol.git/hooks/pre-receive")" == "${SELF}" ]]
+[[ -h "${TEMP}/repos/lol.git/hooks/post-receive" ]]
+[[ "$(readlink "${TEMP}/repos/lol.git/hooks/post-receive")" == "${SELF}" ]]
+
 cat > "${TEMP}/tmp.txt" <<EOF
 blob
 mark :1
@@ -60,6 +75,13 @@
 if [[ -n "${VALGRIND}" ]]; then
     grep "git-shell -c \"git-upload-pack '.*repos/lol.git'\"" 
"${TEMP}/output.txt" &> /dev/null
 else
+    grep "agent=" "${TEMP}/output.txt" &> /dev/null
+fi
+
+echo 0000 | SSH_ORIGINAL_COMMAND="git-upload-pack 'lol.git'" call_bgr 2>&1 > 
"${TEMP}/output.txt"
+if [[ -n "${VALGRIND}" ]]; then
+    grep "git-shell -c \"git-upload-pack '.*repos/lol.git'\"" 
"${TEMP}/output.txt" &> /dev/null
+else
     grep "agent=" "${TEMP}/output.txt" &> /dev/null
 fi
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/blogc-0.13.6/tests/blogc-make/check_blogc_make.sh.in 
new/blogc-0.13.9/tests/blogc-make/check_blogc_make.sh.in
--- old/blogc-0.13.6/tests/blogc-make/check_blogc_make.sh.in    2018-05-14 
22:52:33.000000000 +0200
+++ new/blogc-0.13.9/tests/blogc-make/check_blogc_make.sh.in    2018-06-13 
00:20:43.000000000 +0200
@@ -178,6 +178,7 @@
 
 [settings]
 posts_per_page = -1
+atom_posts_per_page = -1
 
 [posts]
 post01
@@ -392,6 +393,20 @@
 ]]></content>
   </entry>
   
+  <entry>
+    <title type="text">Post 01</title>
+    <id>/post/post01/</id>
+    <updated>2016-09-01T00:00:00Z</updated>
+    <published>2016-09-01T00:00:00Z</published>
+    <link href="http://example.org/post/post01/"; />
+    <author>
+      <name>Lol</name>
+      <email>[email protected]</email>
+    </author>
+    <content type="html"><![CDATA[<p>This is Post 01.</p>
+]]></content>
+  </entry>
+  
 </feed>
 EOF
 diff -uN "${TEMP}/proj/_build/atom.xml" "${TEMP}/expected-atom.xml"
@@ -433,6 +448,7 @@
 
 [settings]
 atom_posts_per_page = 0
+posts_per_page = 0
 
 [posts]
 post01
@@ -449,8 +465,6 @@
 EOF
 
 ${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 
2>&1 | tee "${TEMP}/output.txt"
-grep "_build/index\\.html" "${TEMP}/output.txt"
-grep "_build/atom\\.xml" "${TEMP}/output.txt"
 grep "_build/post/post01/index\\.html" "${TEMP}/output.txt"
 grep "_build/post/post02/index\\.html" "${TEMP}/output.txt"
 grep "_build/post/post03/index\\.html" "${TEMP}/output.txt"
@@ -465,50 +479,6 @@
 
 rm "${TEMP}/output.txt"
 
-cat > "${TEMP}/expected-index.html" <<EOF
-
-Listing: Post 11 - Sep 11, 2016, 12:00 AM GMT
-
-Listing: Post 10 - Sep 10, 2016, 12:00 AM GMT
-
-Listing: Post 09 - Sep 09, 2016, 12:00 AM GMT
-
-Listing: Post 08 - Sep 08, 2016, 12:00 AM GMT
-
-Listing: Post 07 - Sep 07, 2016, 12:00 AM GMT
-
-Listing: Post 06 - Sep 06, 2016, 12:00 AM GMT
-
-Listing: Post 05 - Sep 05, 2016, 12:00 AM GMT
-
-Listing: Post 04 - Sep 04, 2016, 12:00 AM GMT
-
-Listing: Post 03 - Sep 03, 2016, 12:00 AM GMT
-
-Listing: Post 02 - Sep 02, 2016, 12:00 AM GMT
-
-
-EOF
-diff -uN "${TEMP}/proj/_build/index.html" "${TEMP}/expected-index.html"
-
-cat > "${TEMP}/expected-atom.xml" <<EOF
-<?xml version="1.0" encoding="utf-8"?>
-<feed xmlns="http://www.w3.org/2005/Atom";>
-  <title type="text">Lol's Website</title>
-  <id>/atom.xml</id>
-  <updated></updated>
-  <link href="http://example.org/"; />
-  <link href="http://example.org/atom.xml"; rel="self" />
-  <author>
-    <name>Lol</name>
-    <email>[email protected]</email>
-  </author>
-  <subtitle type="text">WAT?!</subtitle>
-  
-</feed>
-EOF
-diff -uN "${TEMP}/proj/_build/atom.xml" "${TEMP}/expected-atom.xml"
-
 cat > "${TEMP}/expected-post-post01.html" <<EOF
 
 


Reply via email to