[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gNewSense-users] kgnewsense-docs progress
From: |
Matthew Flaschen |
Subject: |
[gNewSense-users] kgnewsense-docs progress |
Date: |
Mon, 23 Apr 2007 01:39:42 -0400 |
User-agent: |
Thunderbird 1.5.0.10 (X11/20070306) |
The script is still pretty simple, but I've made enough progress to see
how things will work. I have a single sed call that runs on all xml
files and does obvious things like change Ubuntu to gNewSense and
Kubuntu to gNewSense-Kde (or whatever the distro name is). Then, there
are more specific (and difficult) custom changes made to individual
files. But the point is, the package builds, and still looks
presentable. So, tell me what you think. The script is attached.
Matt Flaschen
#!/bin/bash
#
# Copyright (C) 2006 Brian Brazil
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#
set -ex
. config
rm -rf $WORKINGDIR
mkdir -p $WORKINGDIR
cd $WORKINGDIR
$APTGET source kubuntu-docs$VERSION
cd kubuntu-docs-*
sed -i "s/kubuntu-docs/${DISTRONAME_L}-kde-docs/g" debian/rules
cd kubuntu
find -name *.xml -execdir sed -i "/<para>This document is made
available/i\\\t<para>This document was modified for the ${DISTRONAME}-Kde
distribution.<\/para>
/Documentation Team/!s/Ubuntu/${DISTRONAME}/g
s/Kubuntu/${DISTRONAME}-Kde/g
s/<!ENTITY distro-rev \"6.06 LTS\">/<!ENTITY distro-rev \"${RELEASE}\">/" "{}"
"+"
sed -i "s/kubuntu-desktop/k${DISTRONAME_L}-desktop/
s/: .*Dapper Drake.*\n.*././" aboutkubuntu/*/about-kubuntu.xml
sed -i "s/http:\/\/releases.ubuntu.com\/kubuntu\//http:\/\/cdimage.${DOMAIN}\//g
/<varlistentry>/N
/<varlistentry>.*ShipIt/,/\/varlistentry/d
s/Dapper/${RELEASE}/" releasenotes/*/releasenotes.xml
sed -i "/about-kubuntu-name/,/\/sect2/d
s/- the <emphasis>\&distro-version;<\/emphasis> release././"
desktopguide/*/introduction.xml
cd ..
dch -D $RELEASE -v $(sed -n
'1s#^.*(\(.*\)).*#\1'${DISTRONAME_L}${KDE_DOCS_VERSION}'#p' debian/changelog)
"Refer to $DISTRONAME, and don't describe unfree software"
sed -i "1s/^kubuntu-docs/${DISTRONAME_L}-kde-docs/" debian/changelog
sed -i "s/kubuntu-docs/${DISTRONAME_L}-kde-docs/;
s/Ubuntu/$DISTRONAME/;
s/^\\(Package: ${DISTRONAME_L}-kde-docs.*\\)/\1\\nConflicts:
kubuntu-docs/;" debian/control
$APTGET -y build-dep kubuntu-docs
dpkg-buildpackage -rfakeroot -us -uc
cd ..
reprepro -Vb $REPODST include $RELEASE ${DISTRONAME_L}-kde-docs*.changes
- [gNewSense-users] kgnewsense-docs progress,
Matthew Flaschen <=