Add package documentation
[sheep] / resources / success1.md
1 # Package SUCCESS1
2
3 This defines a simple successful package.
4
5 This is should all get pulled in and the markdown.md should be equal to success1.md.
6
7 ## Function **FUNC-THAT-DOES-STUFF**
8
9 #### Syntax:
10
11 **func-that-does-stuff** _path_ _x_ => _result_
12
13 ```result::= success-result | failure-result```  
14 ```success-result::= (:success filename)```  
15 ```failure-result::= (:failure filename msg)```  
16
17 #### Arguments and Values:
18
19 _path_---a pathname  
20 _x_---a random value related to _path_  
21 _filename_---the file this func was run on  
22 _msg_---a string containing the failure message  
23
24 #### Description:
25
26 _func-that-does-stuff_ runs all the things against a file and returns as soon as the first func error is found.
27
28 This second section uses _path_ and _x_ as something we should talk about, but doesn't use all the arguments (let's include _path_ here for fun)
29
30 #### Examples:
31
32 ```(func-that-does-stuff #P"path/to/file.lisp" t)``` => ```(:success "path/to/file.lisp")```  
33 ```(func-that-does-stuff #P"path/to/error.lisp" nil)``` => ```(:failure "path/to/error.lisp" "Error msg" 20 0)```  
34
35 ## Function **HAS-KEYWORDS**
36
37 #### Syntax:
38
39 **has-keywords** _path_ _&key_ _x_ => _result_
40
41 ```result::= success-result | failure-result```  
42 ```success-result::= (:success filename)```  
43 ```failure-result::= (:failure filename msg)```  
44
45 #### Arguments and Values:
46
47 _path_---a pathname  
48 _x_---a random value related to _path_  
49 _filename_---the file this func was run on  
50 _msg_---a string containing the failure message  
51
52 #### Description:
53
54 _has-keywords_ runs all the things against a file and returns as soon as the first func error is found.
55
56 This second section uses _path_ and _x_ as something we should talk about, but doesn't use all the arguments (let's include _path_ here for fun)
57
58 ## Function **HAS-NO-EXAMPLES**
59
60 #### Syntax:
61
62 **has-no-examples** => _result_
63
64 ```result::= success-result | failure-result```  
65 ```success-result::= (:success filename)```  
66 ```failure-result::= (:failure filename msg)```  
67
68 #### Arguments and Values:
69
70 _filename_---the file this func was run on  
71 _msg_---a string containing the failure message  
72
73 #### Description:
74
75 _has-no-examples_ runs all the things against a file and returns as soon as the first func error is found.
76
77 ## Function **HAS-OPTIONAL**
78
79 #### Syntax:
80
81 **has-optional** _path_ _&optional_ _x_ => _result_
82
83 ```result::= success-result | failure-result```  
84 ```success-result::= (:success filename)```  
85 ```failure-result::= (:failure filename msg)```  
86
87 #### Arguments and Values:
88
89 _path_---a pathname  
90 _x_---a random value related to _path_  
91 _filename_---the file this func was run on  
92 _msg_---a string containing the failure message  
93
94 #### Description:
95
96 _has-optional_ runs all the things against a file and returns as soon as the first func error is found.
97
98 This second section uses _path_ and _x_ as something we should talk about, but doesn't use all the arguments (let's include _path_ here for fun)
99
100 ## Function **HAS-REST**
101
102 #### Syntax:
103
104 **has-rest** _path_ _&rest_ _x_ => _result_
105
106 ```result::= success-result | failure-result```  
107 ```success-result::= (:success filename)```  
108 ```failure-result::= (:failure filename msg)```  
109
110 #### Arguments and Values:
111
112 _path_---a pathname  
113 _x_---a random value related to _path_  
114 _filename_---the file this func was run on  
115 _msg_---a string containing the failure message  
116
117 #### Description:
118
119 _has-rest_ runs all the things against a file and returns as soon as the first func error is found.
120
121 This second section uses _path_ and _x_ as something we should talk about, but doesn't use all the arguments (let's include _path_ here for fun)
122
123 ## Function **NOARGS**
124
125 #### Syntax:
126
127 **noargs** => _result_
128
129 ```result::= success-result | failure-result```  
130 ```success-result::= (:success filename)```  
131 ```failure-result::= (:failure filename msg)```  
132
133 #### Arguments and Values:
134
135 _filename_---the file this func was run on  
136 _msg_---a string containing the failure message  
137
138 #### Description:
139
140 _noargs_ runs all the things against a file and returns as soon as the first func error is found.
141
142 #### Examples:
143
144 ```(func-that-does-stuff)``` => ```(:success "path/to/file.lisp")```  
145 ```(func-that-does-stuff)``` => ```(:failure "path/to/error.lisp" "Error msg" 20 0)```  
146
147 ## Function **RESULT-LIST**
148
149 #### Syntax:
150
151 **result-list** => _result_
152
153 ```result::= failure-result*```  
154 ```failure-result::= (:failure filename msg)```  
155
156 #### Arguments and Values:
157
158 _filename_---the file this func was run on  
159 _msg_---a string containing the failure message  
160
161 #### Description:
162
163 NOARGS runs all the things against a file and returns as soon as the first func error is found.
164
165 ## Function **VALUES-RESULT**
166
167 #### Syntax:
168
169 **values-result** => _result1_, _result2_, _result3_
170
171 ```result1::= success-result | failure-result```  
172 ```success-result::= (:success filename)```  
173 ```failure-result::= (:failure filename msg)```  
174
175 #### Arguments and Values:
176
177 _result2_---second result  
178 _result3_---third result  
179 _filename_---the file this func was run on  
180 _msg_---a string containing the failure message  
181
182 #### Description:
183
184 _values-result_ runs all the things against a file and returns as soon as the first func error is found.