]> Creatis software - bbtk.git/blob - packages/toolsbbtk/bbs/appli/CreatePackage.bbs
Create Black Box bbs + .bat + Bug interface Windows
[bbtk.git] / packages / toolsbbtk / bbs / appli / CreatePackage.bbs
1 description "Creates a new bbtk package file structure on disk (Graphical user interface for the script bbCreatePackage)."
2 author "laurent.guigues at creatis.insa-lyon.fr"
3 category "bbtk tool"
4
5 load wx
6 load std 
7
8 new OutputText windowTitle
9   set windowTitle.In "- - - - - - - - - - - - - -  Create Blackbox  - - - - - - - - - - - - - -"
10
11 new DirectorySelector dir
12     set dir.Title "Select the location of your new package"
13
14 new InputText name
15     set name.Title "Name         (1 word)"
16     set name.In "NEW_PACKAGE"
17
18 new InputText author
19     set author.Title "Author(s)           (caracters   '<',  '>' not accepted...)"
20     set author.In "_author_"
21
22 new InputText description
23     set description.Title "Description            (caracters   '<',  '>' not accepted...)"
24     set description.In "_description_"
25
26 new LayoutLine info
27     connect windowTitle.Widget info.Widget1
28     connect name.Widget info.Widget2
29     connect author.Widget info.Widget3
30     connect description.Widget info.Widget4
31     set info.WinDialog true
32     set info.WinWidth 400 
33     set info.WinHeight 250 
34 exec info
35
36
37 new Configuration conf
38 new ConcatStrings concatStrCommand
39     set concatStrCommand.In1 "."
40     connect conf.FileSeparator concatStrCommand.In2 
41     set concatStrCommand.In3 "bbCreatePackage "
42 new ConcatStrings concatStr
43     connect  concatStrCommand.Out concatStr.In1 
44     connect dir.Out concatStr.In2 
45     set concatStr.In3 " "
46     connect name.Out concatStr.In4 
47     set concatStr.In5 " '"
48     connect author.Out concatStr.In6 
49     set concatStr.In7 "' '"
50     connect description.Out concatStr.In8 
51     set concatStr.In9 "'"
52
53
54 new ExecSystemCommand command
55     connect concatStr.Out command.In
56     print $concatStr.Out$
57
58 exec command
59
60 #seg fault :
61 #quit