unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Yuan Fu <casouri@gmail.com>
To: leungbk@posteo.net
Cc: 59471-done@debbugs.gnu.org
Subject: bug#59471: [PATCH] sh-mode: Run treesit-ready-p only when sh-shell is 'bash
Date: Tue, 22 Nov 2022 17:39:08 -0800	[thread overview]
Message-ID: <16C1E196-AD5B-4358-BCFD-BF5995EC21D0@gmail.com> (raw)
In-Reply-To: <87bkozpukg.fsf@posteo.net>


Brian Leung <leungbk@posteo.net> writes:

> Tags: patch
>
> This patch guards the treesit-ready-p check to run only when sh-shell is
> 'bash, in order to prevent an annoying warning when viewing (say) sh or
> zsh files. But maybe we also want to allow treesitter when sh-shell is
> 'sh?

Oh, thanks! Though I did it a bit differently, by separating
tree-sitter-based mode into a independent major mode (sh-ts-mode), which
is in line with other tree-sitter-based modes (python-ts-mode,
js-ts-mode, etc).

How to make bash-ts-mode fallback to sh-mode when it encounters a shell
script other than bash is still in discussion.

Yuan





      reply	other threads:[~2022-11-23  1:39 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-22  2:54 bug#59471: [PATCH] sh-mode: Run treesit-ready-p only when sh-shell is 'bash Brian Leung
2022-11-23  1:39 ` Yuan Fu [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=16C1E196-AD5B-4358-BCFD-BF5995EC21D0@gmail.com \
    --to=casouri@gmail.com \
    --cc=59471-done@debbugs.gnu.org \
    --cc=leungbk@posteo.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).