GNU bug report logs -
#20780
25.0.50; explain where to find skeletons in autotype info manual
Previous Next
Reported by: Nicolas Richard <youngfrog <at> members.fsf.org>
Date: Tue, 9 Jun 2015 17:33:03 UTC
Severity: wishlist
Tags: fixed
Found in version 25.0.50
Fixed in version 27.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Nicolas Richard <theonewiththeevillook <at> yahoo.fr> writes:
> I still think we should mention some workings examples in the manual,
> near the beginning of it.
>
> Now I'm grepping for '(define-skeleton' in the git repo.
> It returns results in sh-script.el, modula2.el, python.el and a few
> others. Could any of those be mentionned in section 1 ? e.g. in
> shell-script-mode, C-c C-c runs sh-case, which is a skeleton. I think
> it's a great example of all the things mentionned in section 1.
I think adding an example to the manual would be great, but I'm not sure
which. The one you mention seems a bit excessive for the manual...
(define-skeleton sh-case
"Insert a case/switch statement. See `sh-feature'."
(csh "expression: "
"switch( " str " )" \n
> "case " (read-string "pattern: ") ?: \n
> _ \n
"breaksw" \n
( "other pattern, %s: "
< "case " str ?: \n
> _ \n
"breaksw" \n)
< "default:" \n
> _ \n
resume:
< < "endsw" \n)
(es)
(rc "expression: "
> "switch( " str " ) {" \n
> "case " (read-string "pattern: ") \n
> _ \n
( "other pattern, %s: "
"case " str > \n
> _ \n)
"case *" > \n
> _ \n
resume:
?\} > \n)
(sh "expression: "
> "case " str " in" \n
( "pattern, %s: "
> str sh-non-closing-paren \n
> _ \n
";;" \n)
> "*" sh-non-closing-paren \n
> _ \n
resume:
"esac" > \n))
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
This bug report was last modified 5 years and 230 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.