forked from galan/plunger
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtty-plunger-script.txt
60 lines (41 loc) · 1.42 KB
/
tty-plunger-script.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# Instructions
# terminator size: 88x26
export PS1='\n\[\033[01;33m\]\$ \[\033[00m\]'
ttyrec <file>
ttygif <file>
./convert.sh
# Plunger is a commandline tool to interact with message-providers
# https://github.com/galan/plunger
# This demo shows some example of the basic usage (v1.0)
# Listing all destinations
pls hornetq
# hornetq is a predefined target, see how my targets are defined
cat ~/.plunger
# Adding a message to a queue
# One-line notation is "properties-as-json<tab>body-as-string"
echo -e "{}\tHello, plunger" > mymessage.msg
pput hornetq/queue.foo -f mymessage.msg
# Listing the messages in a queue (pretty)
pcat hornetq/queue.foo
# Listing the messages in a queue (one line - one message, for further piping)
pcat hornetq/queue.foo -e
# Listing all destinations with messages
pls hornetq -m
# Moving messages to a different destination, and modifying the content
pcat hornetq/queue.foo -e | sed -e "s/plunger/world/g" | pput hornetq/queue.bar
# Showing all queues
pls hornetq
# Printing modified message
pcat hornetq/queue.bar
# Moving a message from HornetQ to ActiveMQ
# First list destinations on ActiveMQ
pls activemq
# move messages
pcat hornetq/queue.bar -er | pput activemq/queue.here
# List messages on HornetQ
pls hornetq
# List messages on ActiveMQ
pls activemq
# Print messages in target destination
pcat activemq/queue.here
# Thanks for watching