wabur 0.5.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 766bd68332d8a813dc88aa31d7f7613b60db5745
4
- data.tar.gz: 93d415a6f53328cffa67811aeaa3162aaed42791
3
+ metadata.gz: 2480f2f3ceb62d050fd7344d3470ce6db6aa17a7
4
+ data.tar.gz: dce2ae6ae85b32528f61e528964b427cd6c5c53f
5
5
  SHA512:
6
- metadata.gz: e17bab8afa9016b04379e809d7dfe87e1a016514127a7d68be1215504b6132b91d15dd4e9c405b0ef12fac8e8bf59e14954d03739c093fe155070110d43fd9c9
7
- data.tar.gz: 84a999ecc563fd1e464f13b41e451d5401a654481cfcf54c29c6c0ef28577764bc1a4c7c5c1f109f06d9ccf7e91989aa89aada2e8e18d40b0e5211a138c81b91
6
+ metadata.gz: 06ff3a888db5adfa4a74cf513ea722d2dfaefdc4fe664e6003c81caac1954d8bcc3aeb96eff98cd1a421d046010a6f4da87b027bde92dbd46a33b2e782b3e351
7
+ data.tar.gz: 36d7e6c73efa1023fc66579eb6e2f5f32180ab12fc66c3215dece9554a5f71c956214fb72fba094ea05d276e77d703c673323a9213e8b8f3d0675ea1d70cb6e7
data/bin/wabur CHANGED
@@ -27,6 +27,8 @@ require 'wab/impl'
27
27
  usage = %{
28
28
  Usage: wabur [run|new|init] [options] [types]
29
29
 
30
+ version #{WAB::VERSION}
31
+
30
32
  A pure Ruby WAB Runner and multi-purpose tool for WABuR development.
31
33
  Configured directly via command-line options or via a configuration file which
32
34
  can either be a UNIX-style conf file, or a JSON file, or a YAML file.
@@ -35,18 +37,22 @@ URL path to be handled.
35
37
 
36
38
  Modes (the first non-option) available are:
37
39
 
38
- run: Runs wabur as a runner and shell. Also the default. Any types
39
- specified will be ignored.
40
+ run: Runs wabur as a runner and shell. Also the default. Any types
41
+ specified will be ignored.
42
+
43
+ new: New project directory created and set up. The `--base` options must
44
+ be provided to specify the directory to create and initialize.
40
45
 
41
- new: New project directory created and set up. The `--base` options must be
42
- provided to specify the directory to create and initialize. Not
43
- providing the `--base` switch will revert to the `init` mode.
46
+ e.g.: wabur new Entry Article --base my_app
44
47
 
45
- e.g.: wabur new Entry Article --base my_app
48
+ init: Initialize a project into the current directory or into an existing
49
+ sub-directory.
46
50
 
47
- init: Initialize a project into the current directory.
51
+ e.g.: wabur init Entry Article
48
52
 
49
- e.g.: wabur init Entry Article
53
+ version: Displays the current version.
54
+
55
+ help: Displays this help page.
50
56
 
51
57
  }
52
58
 
@@ -114,20 +120,35 @@ options = {
114
120
  doc: 'Log level. (ERROR, WARN, INFO, DEBUG)',
115
121
  arg: 'LEVEL',
116
122
  },
123
+ site: {
124
+ val: false,
125
+ doc: 'populate site directory',
126
+ short: '-s',
127
+ },
117
128
  }
118
129
 
119
130
  config = WAB::Impl::Configuration.new(usage, options)
120
-
121
- if 'new' == config[:mode]
122
- dir = File.expand_path(config[:base] || '.')
123
- FileUtils.mkdir_p(dir) unless File.expand_path('.') == dir
131
+ mode = config[:mode]
132
+ dir = File.expand_path(config[:base] || '.')
133
+ case mode
134
+ when 'new'
135
+ if Dir.exist?(dir)
136
+ if Dir.pwd == dir
137
+ msg = "Refusing to over-write current directory. Either try again with a path to `--base` or use `wabur init` instead."
138
+ else
139
+ msg = "#{dir} already exists. Refusing to over-write. Use `wabur init` with '--base #{config[:base]}' instead."
140
+ end
141
+ abort(WAB::Impl.format_error(msg))
142
+ end
143
+ FileUtils.mkdir_p(dir)
124
144
  WAB::Impl::Init.setup(dir, config)
125
- puts "Successfully created a new WAB workspace at #{dir}"
126
- elsif 'init' == config[:mode]
127
- dir = File.expand_path('.')
145
+ when 'init'
128
146
  WAB::Impl::Init.setup(dir, config)
129
- puts "Successfully initialized a new WAB workspace at #{dir}"
130
- else
147
+ when 'version'
148
+ puts "wabur version #{WAB::VERSION}"
149
+ when 'help'
150
+ config.usage
151
+ when 'run'
131
152
  # The Configuration object can be modified before initializing the Shell. By
132
153
  # setting the +config[:logger]+ the Shell will use that as the logger. The
133
154
  # +config[:handler]+ array can also be modified by setting path values along
@@ -137,4 +158,8 @@ else
137
158
 
138
159
  # Start a shell initialized with the final configuration.
139
160
  WAB::Impl::Shell.new(config).start
161
+ else
162
+ puts WAB::Impl.format_error("unknown mode: #{mode}.")
163
+ config.usage
164
+ Process.exit!(-1)
140
165
  end
@@ -1,2 +1,366 @@
1
- /*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */button,hr,input{overflow:visible}audio,canvas,progress,video{display:inline-block}progress,sub,sup{vertical-align:baseline}[type=checkbox],[type=radio],legend{box-sizing:border-box;padding:0}html{line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,main,menu,nav,section{display:block}h1{font-size:2em;margin:.67em 0}figure{margin:1em 40px}hr{box-sizing:content-box;height:0}code,kbd,pre,samp{font-family:monospace,monospace;font-size:1em}a{background-color:transparent;-webkit-text-decoration-skip:objects}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:bolder}dfn{font-style:italic}mark{background-color:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}audio:not([controls]){display:none;height:0}img{border-style:none}svg:not(:root){overflow:hidden}button,input,optgroup,select,textarea{font-family:sans-serif;font-size:100%;line-height:1.15;margin:0}button,select{text-transform:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring,button:-moz-focusring{outline:ButtonText dotted 1px}fieldset{padding:.35em .75em .625em}legend{color:inherit;display:table;max-width:100%;white-space:normal}textarea{overflow:auto}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}[hidden],template{display:none}*{margin:0;padding:0;font-kerning:none;box-sizing:border-box}html{height:100%}body{display:flex;height:100%;flex-direction:column;font-family:sans-serif;line-height:1.5}a{text-decoration:none}ul{list-style:none}table{width:100%}tr,table,th,td{border:0;border-collapse:collapse}textarea[readonly]:focus{outline:none}.container{margin:0 auto;width:100%;max-width:1180px}.content{flex:1 0 auto}.view-content{width:calc(100% - 60px);margin:auto;padding:100px 15px 50px}.sidebar{position:fixed;width:200px;min-height:100%;padding:90px 0 30px;color:#ededed;background:#212121}.sidebar li{padding:10px;padding-left:20px;color:#3eb1c1;border-top:1px solid #383838;border-bottom:1px solid #0d0d0d}.sidebar li:first-of-type{border-top-color:transparent}.sidebar li:last-of-type{border-bottom-color:transparent}.sidebar_selected,.sidebar_item:hover{color:#ededed !important;background:#171717}.header{position:fixed;width:100%;height:50px;padding:0 15px;color:#ebebeb;background:#333;z-index:2}.header a:hover{color:#fafafa}.header .logo{float:left;padding:15px}.header .logo .brand,.header .logo .subtitle{display:table-cell;vertical-align:middle}.header .logo .brand{padding-right:15px;color:#fafafa;font-size:18px;font-weight:900;line-height:1}.header .logo .subtitle{padding-left:15px;font-size:13px;color:#dedede;border-left:1px solid #999}.header nav{float:right;padding:0 15px}.header nav li{float:left}.header nav li a{display:block;padding:13px 0 0 15px;color:#aeaeae}.footer a:hover{color:#328e9a}.footer{width:100%;margin-left:0px;background:#ededed;color:#999;text-align:center}.footer .attribution{padding:15px 0 12px}.footer .brand{color:#3eb1c1;font-weight:bold}.table-wrapper{overflow-x:auto}.list-items{display:block;max-height:361px;overflow:auto}.obj-list-table{width:100%;font-size:14px;background:#fafafa;border:0;border-collapse:collapse}.obj-list-table tr:hover,.obj-list-table table:hover{background:#f5f5f5}.obj-list-table th,.obj-list-table td{padding:8px 15px;border:1px solid #bbb}.obj-list-table th{text-align:left;color:#ffffff;background:#454545;border:1px solid #777}.obj-list-table th:first-of-type{width:269px;border-left-color:#454545}.obj-list-table th:last-of-type{text-align:center;border-right-color:#454545}.obj-list-table th.list-actions{min-width:162px;width:180px}.obj-list-table td:first-of-type{width:278px}.obj-list-table td.actions{width:60px;color:#757575;text-align:center;cursor:pointer;opacity:0.9}.obj-list-table td.actions:hover{color:#2186c1;background:#fff;opacity:1}.obj-list-table td.actions.delete:hover{color:#da0b0b}.obj-list-table td.actions .icon{font-size:24px}.obj-form-frame{display:table;width:100%;padding:15px;background:#fafafa;border:1px solid #dedede}.obj-form-frame.readonly{background:none;border-color:#ededed}.obj-form td{padding:8px 15px}.obj-form-lock{font-size:24px}.form-field{padding:12px;width:100%;font-family:inherit;border:1px solid #dedede}.readonly .form-field{color:#545454;border-color:#ededed}.field-label{width:80px;text-align:right;font-weight:bold}.field-label:after{content:":"}.btn{float:left;margin-right:12px;margin-bottom:5px;padding:8px 15px;min-width:80px;color:#fff;text-align:center;cursor:pointer;background:#2186c1;border-radius:3px}.btn:hover{color:#fff;background:#3caab9}.table-wrapper>.btn{margin-left:30px;margin-bottom:18px}.create-btn{margin-bottom:15px}.lock-btn{width:35px;padding:8px 8px 5px}.lock-btn:hover{color:#444;background:#fff}.delete-btn:hover{background:#c20a0a}
1
+ /*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */
2
+ button, hr, input {
3
+ overflow: visible; }
4
+
5
+ audio, canvas, progress, video {
6
+ display: inline-block; }
7
+
8
+ progress, sub, sup {
9
+ vertical-align: baseline; }
10
+
11
+ [type=checkbox], [type=radio], legend {
12
+ box-sizing: border-box;
13
+ padding: 0; }
14
+
15
+ html {
16
+ line-height: 1.15;
17
+ -ms-text-size-adjust: 100%;
18
+ -webkit-text-size-adjust: 100%; }
19
+
20
+ body {
21
+ margin: 0; }
22
+
23
+ article, aside, details, figcaption, figure, footer, header, main, menu, nav, section {
24
+ display: block; }
25
+
26
+ h1 {
27
+ font-size: 2em;
28
+ margin: .67em 0; }
29
+
30
+ figure {
31
+ margin: 1em 40px; }
32
+
33
+ hr {
34
+ box-sizing: content-box;
35
+ height: 0; }
36
+
37
+ code, kbd, pre, samp {
38
+ font-family: monospace,monospace;
39
+ font-size: 1em; }
40
+
41
+ a {
42
+ background-color: transparent;
43
+ -webkit-text-decoration-skip: objects; }
44
+
45
+ abbr[title] {
46
+ border-bottom: none;
47
+ text-decoration: underline;
48
+ text-decoration: underline dotted; }
49
+
50
+ b, strong {
51
+ font-weight: bolder; }
52
+
53
+ dfn {
54
+ font-style: italic; }
55
+
56
+ mark {
57
+ background-color: #ff0;
58
+ color: #000; }
59
+
60
+ small {
61
+ font-size: 80%; }
62
+
63
+ sub, sup {
64
+ font-size: 75%;
65
+ line-height: 0;
66
+ position: relative; }
67
+
68
+ sub {
69
+ bottom: -.25em; }
70
+
71
+ sup {
72
+ top: -.5em; }
73
+
74
+ audio:not([controls]) {
75
+ display: none;
76
+ height: 0; }
77
+
78
+ img {
79
+ border-style: none; }
80
+
81
+ svg:not(:root) {
82
+ overflow: hidden; }
83
+
84
+ button, input, optgroup, select, textarea {
85
+ font-family: sans-serif;
86
+ font-size: 100%;
87
+ line-height: 1.15;
88
+ margin: 0; }
89
+
90
+ button, select {
91
+ text-transform: none; }
92
+
93
+ [type=reset], [type=submit], button, html [type=button] {
94
+ -webkit-appearance: button; }
95
+
96
+ [type=button]::-moz-focus-inner, [type=reset]::-moz-focus-inner, [type=submit]::-moz-focus-inner, button::-moz-focus-inner {
97
+ border-style: none;
98
+ padding: 0; }
99
+
100
+ [type=button]:-moz-focusring, [type=reset]:-moz-focusring, [type=submit]:-moz-focusring, button:-moz-focusring {
101
+ outline: ButtonText dotted 1px; }
102
+
103
+ fieldset {
104
+ padding: .35em .75em .625em; }
105
+
106
+ legend {
107
+ color: inherit;
108
+ display: table;
109
+ max-width: 100%;
110
+ white-space: normal; }
111
+
112
+ textarea {
113
+ overflow: auto; }
114
+
115
+ [type=number]::-webkit-inner-spin-button, [type=number]::-webkit-outer-spin-button {
116
+ height: auto; }
117
+
118
+ [type=search] {
119
+ -webkit-appearance: textfield;
120
+ outline-offset: -2px; }
121
+ [type=search]::-webkit-search-cancel-button, [type=search]::-webkit-search-decoration {
122
+ -webkit-appearance: none; }
123
+
124
+ ::-webkit-file-upload-button {
125
+ -webkit-appearance: button;
126
+ font: inherit; }
127
+
128
+ summary {
129
+ display: list-item; }
130
+
131
+ [hidden], template {
132
+ display: none; }
133
+
134
+ * {
135
+ margin: 0;
136
+ padding: 0;
137
+ font-kerning: none;
138
+ box-sizing: border-box; }
139
+
140
+ html {
141
+ height: 100%; }
142
+
143
+ body {
144
+ display: flex;
145
+ height: 100%;
146
+ flex-direction: column;
147
+ font-family: sans-serif;
148
+ line-height: 1.5; }
149
+
150
+ a {
151
+ text-decoration: none; }
152
+
153
+ ul {
154
+ list-style: none; }
155
+
156
+ table {
157
+ width: 100%; }
158
+
159
+ tr, table, th, td {
160
+ border: 0;
161
+ border-collapse: collapse; }
162
+
163
+ textarea[readonly]:focus {
164
+ outline: none; }
165
+
166
+ .container {
167
+ margin: 0 auto;
168
+ width: 100%;
169
+ max-width: 1180px; }
170
+
171
+ .content {
172
+ flex: 1 0 auto; }
173
+
174
+ .view-content {
175
+ width: calc(100% - 60px);
176
+ margin: auto;
177
+ padding: 100px 15px 50px; }
178
+
179
+ .sidebar {
180
+ position: fixed;
181
+ width: 200px;
182
+ min-height: 100%;
183
+ padding: 90px 0 30px;
184
+ color: #ededed;
185
+ background: #212121; }
186
+ .sidebar li {
187
+ padding: 10px;
188
+ padding-left: 20px;
189
+ color: #3eb1c1;
190
+ border-top: 1px solid #383838;
191
+ border-bottom: 1px solid #0d0d0d; }
192
+ .sidebar li:first-of-type {
193
+ border-top-color: transparent; }
194
+ .sidebar li:last-of-type {
195
+ border-bottom-color: transparent; }
196
+
197
+ .sidebar_selected, .sidebar_item:hover {
198
+ color: #ededed !important;
199
+ background: #171717; }
200
+
201
+ .header {
202
+ position: fixed;
203
+ width: 100%;
204
+ height: 50px;
205
+ padding: 0 15px;
206
+ color: #ebebeb;
207
+ background: #333;
208
+ z-index: 2; }
209
+ .header a:hover {
210
+ color: #fafafa; }
211
+ .header .logo {
212
+ float: left;
213
+ padding: 15px; }
214
+ .header .logo .brand, .header .logo .subtitle {
215
+ display: table-cell;
216
+ vertical-align: middle; }
217
+ .header .logo .brand {
218
+ padding-right: 15px;
219
+ color: #fafafa;
220
+ font-size: 18px;
221
+ font-weight: 900;
222
+ line-height: 1; }
223
+ .header .logo .subtitle {
224
+ padding-left: 15px;
225
+ font-size: 13px;
226
+ color: #dedede;
227
+ border-left: 1px solid #999; }
228
+ .header nav {
229
+ float: right;
230
+ padding: 0 15px; }
231
+ .header nav li {
232
+ float: left; }
233
+ .header nav li a {
234
+ display: block;
235
+ padding: 13px 0 0 15px;
236
+ color: #aeaeae; }
237
+
238
+ .footer a:hover {
239
+ color: #328e9a; }
240
+
241
+ .footer {
242
+ width: 100%;
243
+ margin-left: 0px;
244
+ background: #ededed;
245
+ color: #999;
246
+ text-align: center; }
247
+ .footer .attribution {
248
+ padding: 15px 0 12px; }
249
+ .footer .brand {
250
+ color: #3eb1c1;
251
+ font-weight: bold; }
252
+
253
+ .table-wrapper {
254
+ overflow-x: auto; }
255
+
256
+ .list-items {
257
+ display: block;
258
+ max-height: 361px;
259
+ overflow: auto; }
260
+
261
+ .obj-list-table {
262
+ width: 100%;
263
+ font-size: 14px;
264
+ background: #fafafa;
265
+ border: 0;
266
+ border-collapse: collapse; }
267
+ .obj-list-table tr:hover, .obj-list-table table:hover {
268
+ background: #f5f5f5; }
269
+ .obj-list-table th, .obj-list-table td {
270
+ padding: 8px 15px;
271
+ border: 1px solid #bbb; }
272
+ .obj-list-table th {
273
+ text-align: left;
274
+ color: #ffffff;
275
+ background: #454545;
276
+ border: 1px solid #777; }
277
+ .obj-list-table th:first-of-type {
278
+ width: 269px;
279
+ border-left-color: #454545; }
280
+ .obj-list-table th:last-of-type {
281
+ text-align: center;
282
+ border-right-color: #454545; }
283
+ .obj-list-table th.list-actions {
284
+ min-width: 162px;
285
+ width: 180px; }
286
+ .obj-list-table td:first-of-type {
287
+ width: 278px; }
288
+ .obj-list-table td.actions {
289
+ width: 60px;
290
+ color: #757575;
291
+ text-align: center;
292
+ cursor: pointer;
293
+ opacity: 0.9; }
294
+ .obj-list-table td.actions:hover {
295
+ color: #2186c1;
296
+ background: #fff;
297
+ opacity: 1; }
298
+ .obj-list-table td.actions.delete:hover {
299
+ color: #da0b0b; }
300
+ .obj-list-table td.actions .icon {
301
+ font-size: 24px; }
302
+
303
+ .obj-form-frame {
304
+ display: table;
305
+ width: 100%;
306
+ padding: 15px;
307
+ background: #fafafa;
308
+ border: 1px solid #dedede; }
309
+ .obj-form-frame.readonly {
310
+ background: none;
311
+ border-color: #ededed; }
312
+
313
+ .obj-form td {
314
+ padding: 8px 15px; }
315
+
316
+ .obj-form-lock {
317
+ font-size: 24px; }
318
+
319
+ .form-field {
320
+ padding: 12px;
321
+ width: 100%;
322
+ font-family: inherit;
323
+ border: 1px solid #dedede; }
324
+ .readonly .form-field {
325
+ color: #545454;
326
+ border-color: #ededed; }
327
+
328
+ .field-label {
329
+ width: 80px;
330
+ text-align: right;
331
+ font-weight: bold; }
332
+ .field-label:after {
333
+ content: ":"; }
334
+
335
+ .btn {
336
+ float: left;
337
+ margin-right: 12px;
338
+ margin-bottom: 5px;
339
+ padding: 8px 15px;
340
+ min-width: 80px;
341
+ color: #fff;
342
+ text-align: center;
343
+ cursor: pointer;
344
+ background: #2186c1;
345
+ border-radius: 3px; }
346
+ .btn:hover {
347
+ color: #fff;
348
+ background: #3caab9; }
349
+ .table-wrapper > .btn {
350
+ margin-left: 30px;
351
+ margin-bottom: 18px; }
352
+
353
+ .create-btn {
354
+ margin-bottom: 15px; }
355
+
356
+ .lock-btn {
357
+ width: 35px;
358
+ padding: 8px 8px 5px; }
359
+ .lock-btn:hover {
360
+ color: #444;
361
+ background: #fff; }
362
+
363
+ .delete-btn:hover {
364
+ background: #c20a0a; }
365
+
2
366
  /*# sourceMappingURL=wab.css.map */