summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Hood <0x6e6562@gmail.com>2009-08-06 16:05:10 +0100
committerBen Hood <0x6e6562@gmail.com>2009-08-06 16:05:10 +0100
commitb61cc29300ba4377f12538e107819a4d9e675b96 (patch)
treefc29387d3373a00e53948098287f5647662f0262
parente0aa3e890e5c14e2d1324e13c48942ffab94f3fa (diff)
parent91a6c79c0ef709e229f4864cfa8e7c940f66f480 (diff)
downloadrabbitmq-server-git-b61cc29300ba4377f12538e107819a4d9e675b96.tar.gz
Merged bug20602 into default
-rw-r--r--Makefile2
-rw-r--r--ebin/rabbit_app.in2
-rw-r--r--src/rabbit.erl17
3 files changed, 17 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index 9c372a28b7..5c7f629327 100644
--- a/Makefile
+++ b/Makefile
@@ -133,7 +133,7 @@ srcdist: distclean
cp README.in $(TARGET_SRC_DIR)/README
elinks -dump -no-references -no-numbering $(WEB_URL)build-server.html \
>> $(TARGET_SRC_DIR)/BUILD
- sed -i.save 's/%%VERSION%%/$(VERSION)/' $(TARGET_SRC_DIR)/ebin/rabbit_app.in && rm -f $(TARGET_SRC_DIR)/ebin/rabbit_app.in.save
+ sed -i.save 's/%%VSN%%/$(VERSION)/' $(TARGET_SRC_DIR)/ebin/rabbit_app.in && rm -f $(TARGET_SRC_DIR)/ebin/rabbit_app.in.save
cp -r $(AMQP_CODEGEN_DIR)/* $(TARGET_SRC_DIR)/codegen/
cp codegen.py Makefile generate_app $(TARGET_SRC_DIR)
diff --git a/ebin/rabbit_app.in b/ebin/rabbit_app.in
index 8e1c890eb2..0057ea0478 100644
--- a/ebin/rabbit_app.in
+++ b/ebin/rabbit_app.in
@@ -1,7 +1,7 @@
{application, rabbit, %% -*- erlang -*-
[{description, "RabbitMQ"},
{id, "RabbitMQ"},
- {vsn, "%%VERSION%%"},
+ {vsn, "%%VSN%%"},
{modules, []},
{registered, [rabbit_amqqueue_sup,
rabbit_log,
diff --git a/src/rabbit.erl b/src/rabbit.erl
index 196212eaee..088fa436aa 100644
--- a/src/rabbit.erl
+++ b/src/rabbit.erl
@@ -207,8 +207,21 @@ log_location(Type) ->
print_banner() ->
{ok, Product} = application:get_key(id),
{ok, Version} = application:get_key(vsn),
- io:format("~s ~s (AMQP ~p-~p)~n~s~n~s~n~n",
- [Product, Version,
+ ProductLen = string:len(Product),
+ io:format("~n"
+ "+---+ +---+~n"
+ "| | | |~n"
+ "| | | |~n"
+ "| | | |~n"
+ "| +---+ +-------+~n"
+ "| |~n"
+ "| ~s +---+ |~n"
+ "| | | |~n"
+ "| ~s +---+ |~n"
+ "| |~n"
+ "+-------------------+~n"
+ "AMQP ~p-~p~n~s~n~s~n~n",
+ [Product, string:right([$v|Version], ProductLen),
?PROTOCOL_VERSION_MAJOR, ?PROTOCOL_VERSION_MINOR,
?COPYRIGHT_MESSAGE, ?INFORMATION_MESSAGE]),
Settings = [{"node", node()},