\textgreek command unknown with LuaLaTeX since last babel-greek update

Since the last babel-greek package update (around 2020-11-10), the \textgreek command is no longer defined while compiling with LuaLaTeX. The following MWE:

\documentclass{minimal}
\usepackage[greek.ancient,french]{babel}
\begin{document}
\foreignlanguage{greek}{\textgreek{da'imwn}}
\end{document}


produces, while compiling with LuaLaTeX:

! Undefined control sequence.
<argument> \textgreek
{da'imwn}


Though it worked fine before the babel-greek update (and works fine with the package reverted to the previous version) but it still compiles fine with pdfLaTeX and the latest version of babel-greek:

How can I get \textgreek to work with LuaLaTeX and the latest version of babel-greek?

greek no longer loads LGR if it detects an unicode engine. But you can do it yourself:

\documentclass{article}
\usepackage[LGR,TU]{fontenc}
\usepackage[greek.ancient,french]{babel}
\begin{document}
\foreignlanguage{greek}{\textgreek{da'imwn}}
\end{document}

• This works perfectly, thank you very much! Nov 17 '20 at 21:00

You can still load the LGR encoding with luainputenc and define \textgreek to run \fontencoding{LGR}\selectfont. This will hopelessly confuse the hyphenation patterns, however. It will only work if you declare 8-bit LGR fonts with the same family names as your Unicode fonts, for example by loading substitutefont and declaring \substitutefont{LGR}{\rmdefault}{Tempora-TLF}, or by loading \setmainfont{TeX Gyre Termes}[NFSSFamily=Tempora-TLF].

You asked about LuaLaTeX, but XeTeX gives you the option of defining a font mapping. Your question inspired me to make one up for beta code, a more standardized way to encode Greek in ASCII, which currently is supported only for PDFTeX with betababel.