* Why there is an additional NOSPAM in this Yasnippet?
@ 2013-05-09 18:08 Hongxu Chen
2013-05-09 18:48 ` Óscar Fuentes
0 siblings, 1 reply; 3+ messages in thread
From: Hongxu Chen @ 2013-05-09 18:08 UTC (permalink / raw)
To: help-gnu-emacs
Hi all,
I am using yasnippet but has some problems with it.
There is a snippet file in the `snippets/text-mode' directory called
`email', with the full contents below:
# name: (user's email)
# key: email
# --
`(replace-regexp-in-string "@" "@NOSPAM." user-mail-address)`
So why there is a need to replace the `@' with `@NOSPAM'?
BTW, is there any setting that looks up ONLY the directory I customized?
I am using this one but it STILL additionally uses the snippets insides
`yasnippets/snippets' directory(I am using elpa to manage el packages so
I do not like to remove or modify the snippets directory).
(setq yas-snippet-dirs "~/emacs.d/snippets")
Many thanks.
Hongxu Chen
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Why there is an additional NOSPAM in this Yasnippet?
2013-05-09 18:08 Why there is an additional NOSPAM in this Yasnippet? Hongxu Chen
@ 2013-05-09 18:48 ` Óscar Fuentes
2013-05-09 18:55 ` Hongxu Chen
0 siblings, 1 reply; 3+ messages in thread
From: Óscar Fuentes @ 2013-05-09 18:48 UTC (permalink / raw)
To: Hongxu Chen; +Cc: help-gnu-emacs
Hongxu Chen <leftcopy.chx@gmail.com> writes:
> I am using yasnippet but has some problems with it.
>
> There is a snippet file in the `snippets/text-mode' directory called
> `email', with the full contents below:
>
> # name: (user's email)
> # key: email
> # --
> `(replace-regexp-in-string "@" "@NOSPAM." user-mail-address)`
>
> So why there is a need to replace the `@' with `@NOSPAM'?
Putting @NOSPAM in the email address is a common way of trying to
confuse spammers doing address harvesting.
In this case, if you want to use your email address as-is, possibly
there are methods provided by the email client you are using for quickly
inserting it, without the need to use yasnippet.
> BTW, is there any setting that looks up ONLY the directory I customized?
> I am using this one but it STILL additionally uses the snippets insides
> `yasnippets/snippets' directory(I am using elpa to manage el packages so
> I do not like to remove or modify the snippets directory).
>
> (setq yas-snippet-dirs "~/emacs.d/snippets")
Try moving the setq to a place before (require 'yasnippet).
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Why there is an additional NOSPAM in this Yasnippet?
2013-05-09 18:48 ` Óscar Fuentes
@ 2013-05-09 18:55 ` Hongxu Chen
0 siblings, 0 replies; 3+ messages in thread
From: Hongxu Chen @ 2013-05-09 18:55 UTC (permalink / raw)
To: Óscar Fuentes; +Cc: help-gnu-emacs
Got it, thanks so much!
Óscar Fuentes <ofv@wanadoo.es> writes:
> Hongxu Chen <leftcopy.chx@gmail.com> writes:
>
>> I am using yasnippet but has some problems with it.
>>
>> There is a snippet file in the `snippets/text-mode' directory called
>> `email', with the full contents below:
>>
>> # name: (user's email)
>> # key: email
>> # --
>> `(replace-regexp-in-string "@" "@NOSPAM." user-mail-address)`
>>
>> So why there is a need to replace the `@' with `@NOSPAM'?
>
> Putting @NOSPAM in the email address is a common way of trying to
> confuse spammers doing address harvesting.
>
> In this case, if you want to use your email address as-is, possibly
> there are methods provided by the email client you are using for quickly
> inserting it, without the need to use yasnippet.
>
>> BTW, is there any setting that looks up ONLY the directory I customized?
>> I am using this one but it STILL additionally uses the snippets insides
>> `yasnippets/snippets' directory(I am using elpa to manage el packages so
>> I do not like to remove or modify the snippets directory).
>>
>> (setq yas-snippet-dirs "~/emacs.d/snippets")
>
> Try moving the setq to a place before (require 'yasnippet).
--
Regards,
Hongxu Chen
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-05-09 18:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-09 18:08 Why there is an additional NOSPAM in this Yasnippet? Hongxu Chen
2013-05-09 18:48 ` Óscar Fuentes
2013-05-09 18:55 ` Hongxu Chen
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).