Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
kazoo
Commits
1255b189
Commit
1255b189
authored
Nov 28, 2017
by
Maxime Perrotin
Browse files
Use colored output
parent
d48c71d2
Changes
5
Hide whitespace changes
Inline
Side-by-side
src/aadl_parser.adb
View file @
1255b189
...
...
@@ -965,8 +965,8 @@ begin
Ocarina
.
Reset
;
exception
when
Error
:
AADL_Parser_Error
=>
Put
(
"[ERROR] "
);
Put_Line
(
Exception_Message
(
Error
));
Put
(
Red_Bold
&
"[ERROR] "
&
White
);
Put_Line
(
Exception_Message
(
Error
)
&
No_Color
);
OS_Exit
(
1
);
when
E
:
others
=>
Errors
.
Display_Bug_Box
(
E
);
...
...
src/parser_utils.adb
View file @
1255b189
...
...
@@ -21,11 +21,13 @@ package body Parser_Utils is
procedure
Banner
is
The_Banner
:
constant
String
:=
"TASTE AADL Parser (Version "
Yellow_Bold
&
"TASTE AADL Parser
"
&
No_Color
&
"
(Version "
&
Parser_Version
.
Parser_Release
&
") "
&
ASCII
.
LF
&
ASCII
.
CR
&
"Contact: Maxime.Perrotin@esa.int or Thanassis.Tsiodras@esa.int"
&
ASCII
.
LF
&
ASCII
.
CR
&
ASCII
.
LF
&
ASCII
.
CR
&
No_Color
&
"Contact: "
&
Underscore
&
"Maxime.Perrotin@esa.int"
&
No_Color
&
" or "
&
Underscore
&
"Thanassis.Tsiodras@esa.int"
&
ASCII
.
LF
&
ASCII
.
CR
&
No_Color
&
"Based on "
&
Parser_Version
.
Ocarina_Version
;
begin
Put_Line
(
The_Banner
);
...
...
src/parser_utils.ads
View file @
1255b189
...
...
@@ -28,6 +28,12 @@ package Parser_Utils is
function
US
(
Source
:
String
)
return
Unbounded_String
renames
To_Unbounded_String
;
Yellow_Bold
:
constant
String
:=
ASCII
.
ESC
&
"[33m"
&
ASCII
.
ESC
&
"[1m"
;
White
:
constant
String
:=
ASCII
.
ESC
&
"[37m"
;
Red_Bold
:
constant
String
:=
ASCII
.
ESC
&
"[31m"
&
ASCII
.
ESC
&
"[1m"
;
Underscore
:
constant
String
:=
ASCII
.
ESC
&
"[4m"
;
No_Color
:
constant
String
:=
ASCII
.
ESC
&
"[0m"
;
procedure
Banner
;
procedure
Usage
;
...
...
src/parser_version.ads
View file @
1255b189
package
Parser_Version
is
Parser_Release
:
constant
String
:=
"
26af2bc
; Commit Date: Tue Nov 28 1
0:15:49
2017 "
;
"
d48c71d
; Commit Date: Tue Nov 28 1
3:54:14
2017 "
;
Ocarina_Version
:
constant
String
:=
"Ocarina 2017.x (Working Copy from r0b92ed3)"
;
end
Parser_Version
;
\ No newline at end of file
test/test1/Makefile
View file @
1255b189
...
...
@@ -3,7 +3,12 @@ AADL_PARSER=../../aadl_parser
all
:
test-parse
test-parse
:
$(AADL_PARSER)
-glue
-i
interfaceview.aadl
-c
deploymentview.aadl
-d
dataview.aadl ../common/ocarina_components.aadl ../common/TASTE_DV_Properties.aadl 2>&1 |
tail
-2
| diff expected -
$(AADL_PARSER)
-glue
-i
interfaceview.aadl
\
-c
deploymentview.aadl
\
-d
dataview.aadl
\
../common/ocarina_components.aadl
\
../common/TASTE_DV_Properties.aadl
\
2>&1 |
tail
-2
|
sed
"s,
\x
1B
\[
[0-9;]*[a-zA-Z],,g"
|
tail
-2
| diff expected -
clean
:
rm
-rf
obj
$(exec)
*
~
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment