Utilisation de Nanoblogger

Nanoblogger est un blog basé sur la ligne de commande. Il tourne actuellement sur zorglub.

Généralités

Toute la maintenance du blog se fait avec l’unique programme nb, le core de Nanoblogger. Pour le faire le plus facilement, il faut aller dans la racine du site: /www/vhosts/rezirc/www avant de faire le reste du travail.

Ajout d'une news

L’option -a permet de rajouter une news.

/www/vhosts/rezirc/www$ nb -a
creating new entry in '/www/vhosts/rezirc/www' ...
enter author's name [RezIRC team]
: shtrom
enter a title
: exemple de news
editing body ...

L‘$EDITOR est ici lancé pour éditer le corps de la news... La “short description” m’importe peu, j’ai pas encore compris où elle avait de l’influence...

enter a short descriptive comment
: 

Il génère ensuite les pages statiques, puis propose une preview...

[snip]
would you like to preview your weblog now? [y/N]
:

Régénération des pages

L’option -u all demande à Nanoblogger de régénérer toutes les pages.

/www/vhosts/rezirc/www$ nb -u all
processing new weblog entry ...
generating atom 0.3 feed ...
/www/vhosts/rezirc/www/atom.xml
generating weblog links ...
generating weblog status ...
generating calendar ...
generating fortune ...
generating recent entries links ...
generating rss 1.0 feed ...
/www/vhosts/rezirc/www/index.xml
generating rss 2.0 feed ...
/www/vhosts/rezirc/www/rss.xml
generating articles in /www/vhosts/rezirc/www/articles ...
generating shtml pages ...
generating archive index page ...
/www/vhosts/rezirc/www/archives/index.shtml
generating archives ...
generating monthly weblog calendar ...
/www/vhosts/rezirc/www/archives/2005-11.shtml
generating main index page(s) ...
/www/vhosts/rezirc/www/index.shtml
new weblog entry added to 'RezIRC'.

CVS (sauvegarde)

Après l’ajout d’une news, il est de bon ton de jouer du CVS pour en garder une copie. Le script www-save.sh fait tout le travail. Il est aussi appelé par un cron quotidiennement.