about summary refs log blame commit diff stats
path: root/translate_mu_debug
blob: b6176a8290ca3d16cadaa0fb964658d85d4e058f (plain) (tree)
f2c5b053pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight .c { color: #888888 } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */
.highlight .k { color: #008800; font-weight: bold } /* Keyword */
.highlight .ch { color: #888888 } /* Comment.Hashbang */
.highlight .cm { color: #888888 } /* Comment.Multiline */
.highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */
.highlight .cpf { color: #888888 } /* Comment.PreprocFile */
.highlight .c1 { color: #888888 } /* Comment.Single */
.highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */
.highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */
#!/bin/sh
# Translate Mu programs with debug information on Linux.

set -e

cat $* [0-9]*.mu    |apps/mu    > a.subx

./translate_subx_debug init.linux [0-9]*.subx mu-init.subx a.subx
"> (Choose) Execute(aerc *widgets.Aerc, args []string) error { if len(args) < 5 || len(args)%4 != 1 { return chooseUsage(args[0]) } choices := []widgets.Choice{} for i := 0; i+4 < len(args); i += 4 { if args[i+1] != "-o" { return chooseUsage(args[0]) } choices = append(choices, widgets.Choice{ Key: args[i+2], Text: args[i+3], Command: strings.Split(args[i+4], " "), }) } aerc.RegisterChoices(choices) return nil } func chooseUsage(cmd string) error { return fmt.Errorf("Usage: %s -o <key> <text> <command> [-o <key> <text> <command>]...", cmd) }