~ubuntu-branches/ubuntu/intrepid/samba/intrepid-updates

« back to all changes in this revision

Viewing changes to docs-xml/xslt/expand-smbconfdoc.xsl

  • Committer: Bazaar Package Importer
  • Author(s): Chuck Short
  • Date: 2008-06-02 09:01:46 UTC
  • mfrom: (0.25.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20080602090146-92ur4nx39ccg708r
Tags: 2:3.0.30-2ubuntu1
* Merge from debian unstable, remaining changes:
  * debian/patches/VERSION.patch
    - set SAMABA_VERSION_VENDOR_SUFFIX to Ubuntu
  * debian/smb.conf
    - add "(Samba, Ubuntu)" to server string.
    - comment out the default [homes] shares, and a comment about
      "value users = %S to show users how to restrict access to 
      \\server\useranem to only username.
    - Add map to guest = Bad user, maps bad username to guest access.
      (LP: #32067)
  * debian/samba-common.postinst:
    - Fix upgrade from a first installation done with feisty, edgy, or dapper.
      (LP: #201059)
    - When populating the new sambashare group, it's not an error if the user
      simply doesn't exist; test for this case and the install continue 
      instead of aborting. (LP: #206036)
  * debian/smba-common.config:
    - do not change priority to HIGH if dhclient3 is installed
    - used priority medium instead of hight for the workgroup question
  * debian/winbind.files
    - insclude additional files
  * debian/patches/fix-documentation.patch:
    - fix typos in net(8) and smb.conf(5) man pages
  * debian/mksambapasswd.awk:
    - Don't add user with UID less than 1000 to smbpasswd.
  * debian/samba.init:
    - add 'status' option for LSB conformance.
  * Updated control version.
  * Dropped Changes:
    - Dropped debian/patches/fix-smbprinting-os2.patch. Accepted upstream.
    - Dropped debian/patches/fix-documentation.patch. Accepted upstream.
     

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version='1.0'?>
 
2
<!-- 
 
3
        smb.conf-documentation specific stylesheets
 
4
        Published under the GNU GPL
 
5
 
 
6
        (C) Jelmer Vernooij                                     2002-2004
 
7
        (C) Alexander Bokovoy                                   2002-2004
 
8
-->
 
9
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
 
10
        xmlns:samba="http://www.samba.org/samba/DTD/samba-doc"
 
11
        version="1.1">
 
12
 
 
13
        <xsl:template match="description"><xsl:apply-templates/></xsl:template>
 
14
 
 
15
        <xsl:template match="value"><xsl:element name="literal"><xsl:apply-templates/></xsl:element></xsl:template>
 
16
        
 
17
        <xsl:template match="command"><xsl:element name="literal"><xsl:apply-templates/></xsl:element></xsl:template>
 
18
 
 
19
        <xsl:template match="synonym"><xsl:apply-templates/></xsl:template>
 
20
 
 
21
        <xsl:template match="related"><xsl:element name="para"><xsl:text>Related command</xsl:text><xsl:apply-templates/></xsl:element></xsl:template>
 
22
 
 
23
        <xsl:template match="samba:parameterlist">
 
24
                <xsl:apply-templates>
 
25
                        <xsl:sort select="samba:parameter/@name"/>
 
26
                </xsl:apply-templates>
 
27
        </xsl:template>
 
28
 
 
29
        <xsl:template match="value/comment">
 
30
                <xsl:text>&#10;# </xsl:text>
 
31
                <xsl:apply-templates/>
 
32
        </xsl:template>
 
33
 
 
34
        <xsl:template match="samba:parameter">
 
35
                <xsl:variable name="cname"><xsl:value-of select="translate(translate(string(@name),' ',''),
 
36
                                'abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ')"/>
 
37
                </xsl:variable>
 
38
 
 
39
                <xsl:variable name="name"><xsl:value-of select="@name"/></xsl:variable>
 
40
 
 
41
                <xsl:variable name="anchor">
 
42
                        <xsl:element name="anchor">
 
43
                                <xsl:attribute name="id">
 
44
                                        <xsl:value-of select="$cname"/>
 
45
                                </xsl:attribute>
 
46
                        </xsl:element>
 
47
                </xsl:variable>
 
48
 
 
49
                <xsl:variable name="context">
 
50
                        <xsl:text> (</xsl:text>
 
51
                        <xsl:value-of select="@context"/>
 
52
                        <xsl:text>)</xsl:text>
 
53
                </xsl:variable>
 
54
 
 
55
                <xsl:variable name="term">
 
56
                                <xsl:copy-of select="$anchor"/>
 
57
                                <xsl:element name="title">
 
58
                                        <xsl:text>&#10;</xsl:text>
 
59
                                        <xsl:text>&#10;</xsl:text>
 
60
                                        <xsl:value-of select="@name"/>
 
61
                                        <xsl:value-of select="$context"/>
 
62
                                        <xsl:text>&#10;</xsl:text>
 
63
                                </xsl:element>
 
64
                </xsl:variable>
 
65
 
 
66
 
 
67
                <!-- Generate list of examples -->
 
68
                <xsl:variable name="examples">
 
69
                        <xsl:for-each select="value">
 
70
                                <xsl:if test="@type = 'example'">
 
71
                                        <xsl:element name="para">
 
72
                                                <xsl:text>Example: </xsl:text>
 
73
                                                <xsl:element name="emphasis">
 
74
                                                        <xsl:element name="parameter">
 
75
                                                                <xsl:copy-of select="$name"/>
 
76
                                                        </xsl:element>
 
77
                                                        <xsl:text> = </xsl:text>
 
78
                                                        <xsl:apply-templates select="."/>
 
79
                                                        <xsl:text>&#10;</xsl:text>
 
80
                                                </xsl:element>
 
81
                                                <xsl:text>&#10;</xsl:text>
 
82
                                        </xsl:element>
 
83
                                </xsl:if>
 
84
                        </xsl:for-each>
 
85
                </xsl:variable>
 
86
 
 
87
                <xsl:variable name="tdefault">
 
88
                        <xsl:for-each select="value">
 
89
                                <xsl:if test="@type = 'default'">
 
90
                                        <xsl:element name="para">
 
91
                                                <xsl:text>Default: </xsl:text>
 
92
                                                <xsl:element name="emphasis">
 
93
                                                        <xsl:element name="parameter">
 
94
                                                                <xsl:copy-of select="$name"/>
 
95
                                                        </xsl:element>
 
96
                                                        <xsl:text> = </xsl:text>
 
97
                                                        <xsl:apply-templates select="."/>
 
98
                                                        <xsl:text>&#10;</xsl:text>
 
99
                                                </xsl:element>
 
100
                                                <xsl:text>&#10;</xsl:text>
 
101
                                        </xsl:element>
 
102
                                </xsl:if>
 
103
                        </xsl:for-each>
 
104
                </xsl:variable>
 
105
 
 
106
                <xsl:variable name="default">
 
107
                        <xsl:choose>
 
108
                                <xsl:when test="$tdefault = ''">
 
109
                                        <xsl:element name="para">
 
110
                                                <xsl:element name="emphasis">
 
111
                                                        <xsl:text>No default</xsl:text>
 
112
                                                </xsl:element>  
 
113
                                        </xsl:element>
 
114
                                </xsl:when>
 
115
                                <xsl:otherwise>
 
116
                                        <xsl:copy-of select="$tdefault"/>
 
117
                                </xsl:otherwise>
 
118
                        </xsl:choose>
 
119
                </xsl:variable>
 
120
 
 
121
                <xsl:variable name="content">
 
122
                        <xsl:apply-templates select="description"/>
 
123
                </xsl:variable>
 
124
 
 
125
                <xsl:for-each select="synonym">
 
126
                        <xsl:element name="section">
 
127
                                <xsl:element name="indexterm">
 
128
                                        <xsl:attribute name="significance">
 
129
                                                <xsl:text>preferred</xsl:text>
 
130
                                        </xsl:attribute>
 
131
                                        <xsl:element name="primary">
 
132
                                                <xsl:value-of select="."/>
 
133
                                        </xsl:element>
 
134
                                        <xsl:element name="see">
 
135
                                                <xsl:value-of select="$name"/>
 
136
                                        </xsl:element>
 
137
                                </xsl:element>
 
138
                                <xsl:element name="title">
 
139
                                        <xsl:element name="anchor">
 
140
                                                <xsl:attribute name="id">
 
141
                                                        <xsl:value-of select="translate(translate(string(.),' ',''), 'abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ')"/>
 
142
                                                </xsl:attribute>
 
143
                                        </xsl:element>
 
144
                                        <xsl:value-of select="."/>
 
145
                                </xsl:element>
 
146
                                <xsl:element name="variablelist">
 
147
                                        <xsl:element name="varlistentry">
 
148
                                                <xsl:element name="listitem">
 
149
                                                        <xsl:element name="para">
 
150
                                                                <xsl:text>This parameter is a synonym for </xsl:text>
 
151
                                                                <xsl:element name="link">
 
152
                                                                        <xsl:attribute name="linkend">
 
153
                                                                                <xsl:value-of select="translate(translate(string($name),' ',''), 'abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ')"/>
 
154
                                                                        </xsl:attribute>
 
155
                                                                        <xsl:value-of select="$name"/>
 
156
                                                                </xsl:element>
 
157
                                                                <xsl:text>.</xsl:text>
 
158
                                                        </xsl:element>
 
159
                                                </xsl:element>
 
160
                                        </xsl:element>
 
161
                                </xsl:element>
 
162
                                <xsl:text>&#10;</xsl:text>     
 
163
                        </xsl:element>
 
164
                </xsl:for-each>
 
165
 
 
166
                <xsl:element name="section">
 
167
                        <xsl:element name="indexterm">
 
168
                                <xsl:attribute name="significance">
 
169
                                        <xsl:text>preferred</xsl:text>
 
170
                                </xsl:attribute>
 
171
                                <xsl:element name="primary">
 
172
                                <xsl:value-of select="@name"/>
 
173
                                </xsl:element>
 
174
                        </xsl:element>
 
175
                        <xsl:copy-of select="$term"/>
 
176
                        <xsl:element name="variablelist">
 
177
                                <xsl:element name="varlistentry">
 
178
                                        <xsl:element name="listitem">
 
179
                                                <xsl:copy-of select="$content"/> <xsl:text>&#10;</xsl:text>
 
180
                                                <xsl:copy-of select="$default"/> <xsl:text>&#10;</xsl:text>
 
181
                                                <xsl:copy-of select="$examples"/> <xsl:text>&#10;</xsl:text>
 
182
                                        </xsl:element>
 
183
                                </xsl:element>
 
184
                        </xsl:element>
 
185
                        <xsl:text>&#10;</xsl:text>
 
186
                </xsl:element>
 
187
        </xsl:template>
 
188
</xsl:stylesheet>