Calvin Crowley dixit:

>mksh: /etc/profile.d/PackageKit.sh[14]: syntax error: unexpected 
>operator/operand '=~'

Please report this as a bug against the PackageKit packaging in
Fedora instead. Make clear that files in /etc/profile.d/ can be
sourced by any POSIX sh-compatible shell and thus MUST NOT use
any non-POSIX-sh constructs without consulting a whitelist of
shells supporting it.

In concrete, using [[ foo =~ bar ]] can be replaced by converting
“bar” from RE to extglob and using [[ foo = *bar* ]], and this
will work in all Korn shells, all shells supporting =~ (in GNU bash
you need “shopt -s extglob” additionally), and some compatibles.

>the broken method: command_not_found_handler ()

This has nothing to do with command_not_found_handler.

>my workaround is to not use:  mksh -l
>and instead just source my ~/.mkshrc

These are also independent of each other.

${ENV:-~/.mkshrc} is *always* read.

/etc/profile is read from a login shell or with “mksh -l”.

If “mksh -l” does not work, then using mksh as login shell
is broken on that system, which I’d consider a serious bug.
I don’t know Fedora policies, though.

>that gets me by so I can work on my ed.mksh editor kit
>for my Android tablets (FireHD 10 and Samsung Tab A 8)
>running Termius local shells.

Cool! (You also get mksh from stock methods like adb shell
and vx.connectbot, no need to install a GNU chroot for it.)

Contact me once you believe it in a workable state, and I’ll
link to it as user examples or something from the mksh webpage,
if you wish.

bye,
//mirabilos
-- 
„Cool, /usr/share/doc/mksh/examples/uhr.gz ist ja ein Grund,
mksh auf jedem System zu installieren.“
        -- XTaran auf der OpenRheinRuhr, ganz begeistert
(EN: “[…]uhr.gz is a reason to install mksh on every system.”)

Reply via email to