Skip to content
This repository has been archived by the owner on Jan 15, 2018. It is now read-only.

Commit

Permalink
+ Some more replacements for the HTML DescFile
Browse files Browse the repository at this point in the history
git-svn-id: svn+ssh://svn.izzysoft.de/public/relman/trunk@43 aa694edc-7539-0410-8dc8-fb52a58a778e
  • Loading branch information
IzzySoft committed May 27, 2008
1 parent 4ef0a2c commit ac571a9
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 5 deletions.
1 change: 1 addition & 0 deletions Makefile
Expand Up @@ -18,6 +18,7 @@ man8dir=$(mandir)/man8

install: installdirs
$(INSTALL_DATA) -c relman.conf $(DESTDIR)$(sysconfdir)
$(INSTALL_DATA) -c relman.dr $(DESTDIR)$(sysconfdir)
$(INSTALL_DATA) -c version $(DESTDIR)$(sysconfdir)
$(INSTALL) -c relman $(DESTDIR)$(bindir)
$(INSTALL_DATA) -c doc/* $(DESTDIR)$(docdir)
Expand Down
9 changes: 5 additions & 4 deletions doc/history
Expand Up @@ -5,14 +5,15 @@ History for relman

v0.1.5
-------------------
+ added xfer via RSync
+ added xfer via sFTP
* initial output of configuration changed - it got to long, so now we only
display those variables really set
+ added xfer via RSync and sFTP
* initial output of configuration (the "confirmation screen") changed - it got
to long, so now we only display those variables really set/used
+ the descfile is now passed to pkgmake (if specified)
+ optionally, the descfile can now be converted to some basic HTML code and
be transfered via RSync or SCP to a remote server, in order to use it with
the HistView download class
+ Some more replacements for the HTML DescFile now can be defined in
~/.relman/<projectname>.dr (see man pages plus example relman.dr file for details)

v0.1.4 (17.03.2008)
-------------------
Expand Down
15 changes: 15 additions & 0 deletions man/relman.8
Expand Up @@ -292,6 +292,17 @@ itself, and then looks for ~/.relman/relman.conf - if found, this is used. If it
is not found, it looks for the /etc/relman/relman.conf and uses this file (if
found) to overwrite the default settings.

There are some additional (and optional) files if you want to use the DescFile
with the HistView download class: In either /etc/relman/ or $HOME/.relman/ you
may put files with replacement definitions. The filename must match the
project name as defined in relman.conf, and have the extension ".dr" (for
"desc replacements" (if that file exists in both locations, only the one from
$HOME/.relman will be used). In that file you define terms and their replacements,
one by line, separated by a semicolon. The first semicolon on the line will be the
separator - which means, the term-to-replace cannot contain a semicolon, while
the replacement term can.


.SH MESSAGES AND EXIT CALLS
relman uses the following exit codes:

Expand Down Expand Up @@ -332,6 +343,10 @@ you have to run the whole thing manually and watch the output on screen.

~/.relman/relman.conf

/etc/relman/*.dr

~/.relman/*.dr

.SH "SEE ALSO"
relman.conf(5)

Expand Down
11 changes: 10 additions & 1 deletion relman
Expand Up @@ -710,7 +710,7 @@ export PKGMAKE_USED="relman v${RELMANV}"
}

#------------------------------------------------------------[ Continue??? ]---
[ -z "${tarscp}${tarftp}${tarsftp}${tarrsync}${debftp}${debsftp}${debscp}${debrsync}${sdebftp}${sdebsftp}${sdebscp}${sdebrsync}${rpmftp}${rpmsftp}${rpmscp}${rpmrsync}${srpmftp}${srpmsftp}${srpmscp}${srpmrsync}" ] && finito
[ -z "${tarscp}${tarftp}${tarsftp}${tarrsync}${debftp}${debsftp}${debscp}${debrsync}${sdebftp}${sdebsftp}${sdebscp}${sdebrsync}${rpmftp}${rpmsftp}${rpmscp}${rpmrsync}${srpmftp}${srpmsftp}${srpmscp}${srpmrsync}${histscp}{$histrsync}${histsftp}${descscp}${descrsync}" ] && finito

[ $yestoall -eq 0 ] && {
echo -en "${blue}* Going to distribute. Continue (y/n)?$NC "
Expand Down Expand Up @@ -780,6 +780,15 @@ export PKGMAKE_USED="relman v${RELMANV}"
TMPFILE=/tmp/${prog}.desc
sed 's/\&/\&amp\;/g' $descfile | sed 's/</\&lt\;/g' | sed -n 's/>/\&gt\;/g;p' |\
sed 's/"/\&quot\;/g' | sed -n '1h;2,$H;${g;s/\n\n/<br>\n/g;p}' >$TMPFILE
[ -e "/etc/relman/${prog}.dr" ] && drepfile="/etc/relman/${prog}.dr"
[ -e "$HOME/.relman/${prog}.dr" ] && drepfile="$HOME/.relman/${prog}.dr"
[ -n "$drepfile" ] && {
desc=`cat "$TMPFILE"`
while read dline; do
desc="${desc//${dline%%;*}/${dline#*;}}"
done<$drepfile
echo -e "$desc">$TMPFILE
}
[ -n "$descscp" ] && scpxfer "DescFile" $TMPFILE $descscp
[ -n "$descrsync" ] && rsyncxfer "DescFile" $TMPFILE $descrsync
rm -f $TMPFILE
Expand Down
2 changes: 2 additions & 0 deletions relman.dr
@@ -0,0 +1,2 @@
relman;<a href='http://projects.izzysoft.de/trac/relman'>relman</a>
pkgmake;<a href='http://projects.izzysoft.de/trac/pkgmake'>pkgmake</a>

0 comments on commit ac571a9

Please sign in to comment.