Draw sequence diagrams from the terminal.
$ ./seqdia <<'EOF'
participant Alice
participant Bob
Alice->Bob: Hello
note right of Bob: OK
Alice<-Bob: Bye
note left: end note
EOF
╭─────╮ ╭───╮
│Alice│ │Bob│
╰──┬──╯ ╰─┬─╯
┆ ┆
┆ Hello ┆
├──────▶┆
┆ ┆
┆ ┆╒════╕
┆ ┆│ OK │
┆ ┆└────┘
┆ ┆
╒══════════╕┆ Bye ┆
│ end note │┆◀──────┤
└──────────┘┆ ┆
┆ ┆
┆ ┆
┆ ┆
See more examples in tests/fixtures/.
make
$ seqdia [options] [file]
$ seqdia --style ascii tests/fixtures/simple.txt
$ echo "Alice->Bob: Hello" | seqdia
Options:
-v, --versionPrint version-s, --style <ascii|utf8>Output style (default: utf8)
participant Alice
participant "Billing Service" as Billing
participant "multi
line" as MultiParticipants are optional, but defining them keeps columns aligned.
// comment
; comment
' commentComments only work when the line starts with the marker (spaces allowed).
Alice->Bob: solid
Bob<-Alice: solid-left
Alice->>Bob: open
Bob<<-Alice: open-left
Alice-->Bob: dashed
Bob<--Alice: dashed-left
Alice->xBob: x
Bob x<-Alice: x-leftnote left of Alice: left note
note right of Bob: right note
note over Alice,Bob: over both
note over Alice
multi
line
end noteMulti-line notes must end with end note.
Inline notes (attach to the most recent message):
Alice->Bob: hello
note left: inline left
note right: inline right- Installation via brew/nix
- more arrow design
- loop, alt, opt, etc.
- colors
- export to image