shithub: sirjofri_de

ref: 94e3925e156a61d7cf402cafbb0b2e991186347b
dir: /changeblog/1594885496.txt/

View raw version
lib/profile quick hack

Some smaller change that can change your life.

There are reasons why you not run ‥rio‥ in your lib/profile. For me the main reason would be: You can no longer use
[[[ms
.CW "rcpu -c commands"
]]]
[[[ebook
<code>rcpu -c commands</code>
]]]
in your shell. Rio opens and there you are, stuck in front of a gray background.

My solution:
[[[ms
.P1
case cpu
   # … lots of stuff …
   rcpucmd=`{cat /mnt/term/env/cmd >[2]/dev/null}
   if(~ $#rcpucmd 0)
      rio
   # … lots of stuff …
.P2
]]]
[[[ebook
<code><pre>
case cpu
   # … lots of stuff …
   rcpucmd=`{cat /mnt/term/env/cmd >[2]/dev/null}
   if(~ $#rcpucmd 0)
      rio
   # … lots of stuff …
</pre></code>
]]]

[[[ms
Now I can
.CW rcpu
and have my rio, or
.CW "rcpu -c command"
and run the command without leaving my shell.
]]]
[[[ebook
Now I can <code>rcpu</code> and have my rio, or
<code>rcpu -c command</code>
and run the command without leaving my shell.
]]]