1

I type option+ñ and get a ~ on most applications:

when I am in Terminal, I get (arg: 1) on bash, and ? on zsh.

The results are the same for left and right option keys.

Hardware: MacBook Pro, 15 inch, 2018

Mac OSX: Ventura 13.6.6

Keyboard: native keyboard of Macbook Pro (Spanish keyboard)

How can I get a tilde (~) on terminal on a Spanish keyboard?

I have already checked the other question that is supposed to be a duplicate of my question, in fact that solution (option+ñ) does not solve my problem.


I am using ES SPANISH on keyboard layout, not Latin America or Spanish Legacy.


On bash, pushing ñ key gives (arg: 1) on terminal.

On zsh, pushing ñ key gives ñ on terminal.


locale is empty

Setting LANG=es_ES.utf-8, option+ñ gives:

-- ? on bash

-- <ffffffff> on zsh


In Terminal -> Settings.. -> Profiles -> Basic (or other) -> Advanced -> International I checked both:

Set locale environment variables at startup

and

Unicode East Asian Ambiguous characters are wide

and I get now ? or ±, depending on the chosen Western encoding

10
  • 1
    When you press option - is it on the left or right side of the keyboard? Also note that a space or / may be required
    – bmike
    Commented Jul 9 at 1:33
  • @bmike I have tried both option on the left and the right and it is the same. Can you give me some hint about / or space? I have tried adding them somewhere, but I cannot find a working combination
    – simona
    Commented Jul 9 at 1:51
  • Can you edit in the version of macOS (which number and or build) and let’s reopen this for answer. Let’s edit in also that your results are the same for left and right option key and clarify - is the keyboard USB or Bluetooth or part of a portable MacBook ?
    – bmike
    Commented Jul 9 at 2:16
  • 1
    ~ is normally made via option ñ then space on the Spanish layout, but option ñ on the layout called Latin American. Which one are you using? Commented Jul 9 at 9:24
  • What is the output from locale? The C locale has very limited character handling and might produce the symptoms you're seeing. You can change the locale with export LANG=es_ES.UTF-8; export LC_ALL=es_ES.UTF-8 (locale -a will list some other possible values).
    – Gairfowl
    Commented Jul 9 at 12:47

0

You must log in to answer this question.

Browse other questions tagged .