Am Samstag, dem 09.12.2023 um 10:24 +0100 schrieb Ludovic Courtès:
> Hi Liliana,
> 
> Liliana Marie Prikler <liliana.prik...@gmail.com> skribis:
> 
> > > > Maybe we can check for a guix_editor shell function and invoke
> > > > that
> > > > rather than EDITOR if defined?
> > > 
> > > ‘guix edit’ cannot “invoke” a shell function though.
> > > 
> > > I was thinking of something more gross, like checking whether the
> > > basename of $EDITOR is ‘kate’ or ‘vscode’ and in that case do
> > > whatever is relevant for those editors.
> > > 
> > > WDYT?
> > I see your gross "checking whether the basename of $EDITOR is
> > ‘kate’…" and I raise my "use $GUIX_EDITOR which uses substring
> > replacements for ${LINE} and ${FILE} implemented in pure Guile
> > code"
> 
> I’m not sure I understand your proposal.  Are you suggesting that
> ‘GUIX_EDITOR’ would contain arbitrary Scheme code that ‘guix edit’
> would evaluate?
No, it'd contain the shell-esque "${LINE}" and "${FILE}" that would get
replaced by Scheme code looking for those strings.

Cheers

Reply via email to