3

I don't have a |-key.

is there an alternative to it?

say, can I execute an equivalent to dmesg | less if I can't type |?


System

# uname -a  
Linux devuan-droid4 5.4.0 #1 SMP PREEMPT Sun Jan 12 19:38:25 UTC 2020 armv7l GNU/Linux

Hardware enter image description here Droid 4


Update based on comments

# setxkbmap -query   
rules:     evdev     
model:     pc105    
layout:    us
# setxkbmap -print    
xkb_keymap {
     xkb_keycodes  { include "evdev+aliases(querty)" };    
     xkb_types     { include "complete" };    
     xkb_compat    { include "complete" };    
     xkb_symbols   { include "pc+us+inet(evdev)" };    
     xkb_geometry  { include "pc(pc105" };
};    

Update 2024
The issue went away by the developers. Here is their wiki

16
  • 3
    I recently had to return a keyboard because it didn't come with a | key, if you plan to code things I suggest you do the same. You can remap it to another key but the company that made your keyboard should not go unpunished. This aggression against the pipe key will not stand man.
    – jesse_b
    Mar 24, 2020 at 16:21
  • 2
    I'm sure it's on some other key. On my keyboard, the | can be found on a key with the two symbols ~ and # (with Shift depressed; without shift I get a backslash). Also, in it's current form, this question is hardly Unix related, but more a question for SuperUser, IMHO.
    – Kusalananda
    Mar 24, 2020 at 16:23
  • 2
    On my similarly looking old Nokia N810, I've bound it to FN+Z (the yen symbol, ~ the same position as SYM-Z on your device) via a file in /usr/share/X11/xkb/symbols. You have to decide on key combo, that's certainly possible in Debian/Devuan, too.
    – user313992
    Mar 24, 2020 at 17:05
  • 1
    Please show the output of setxkbmap -query, and post somewhere the output of setxkbmap -print.
    – user313992
    Mar 24, 2020 at 17:26
  • 1
    @Kusalananda that's not android
    – user313992
    Mar 24, 2020 at 17:31

2 Answers 2

2

Alternative 1:

It is not a general substitute for | but will work in some cases:

less <(dmesg)

Alternative 2 (requires \):

perl -e 'print "I=\"".chr(124)."\"\n"' >> .bashrc

Alternative 3:

perl -e 'print "I=".'"'"'"'"'"'.chr(124).'"'"'"'"'"'.'"'                                               
'"  >> .bashrc

Alternative 4: Edit .bashrc and type (e.g. by doing cat >> .bashrc):

I=$(perl -e 'print chr(124)')

Start a new bash, and then you can run:

eval dmesg $I grep Linux $I less
3
  • nice option! I don't have an internet connection working on this device... but there might be a | somewhere in the system files, right?
    – scjorge
    Mar 24, 2020 at 17:42
  • oh, I unfortunately also don't have a backslash...
    – scjorge
    Mar 29, 2020 at 11:23
  • wow, so many options!.. ehm.. alternative 2 requires __ what?
    – scjorge
    Mar 29, 2020 at 13:50
1

If you have the > key, you could try :

dmesg > dmesg.txt
less dmesg.txt
1
  • I have that key, it is a workaround :) ... but is there a replacement?
    – scjorge
    Mar 24, 2020 at 16:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .