From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Xah Lee Newsgroups: gmane.emacs.help Subject: Re: yasnippet to expand abbreviation in dired/fileopen command? Date: Thu, 10 May 2012 04:31:46 -0700 (PDT) Organization: http://groups.google.com Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1337034470 16143 80.91.229.3 (14 May 2012 22:27:50 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 14 May 2012 22:27:50 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue May 15 00:27:50 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SU3k2-0007hD-Pv for geh-help-gnu-emacs@m.gmane.org; Tue, 15 May 2012 00:27:46 +0200 Original-Received: from localhost ([::1]:41993 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SU3TN-0000op-Bj for geh-help-gnu-emacs@m.gmane.org; Mon, 14 May 2012 18:10:33 -0400 Original-Path: usenet.stanford.edu!news.kjsl.com!news.glorb.com!border3.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!postnews.google.com!h10g2000pbi.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 35 Original-NNTP-Posting-Host: 76.126.112.84 Original-X-Trace: posting.google.com 1336649909 19602 127.0.0.1 (10 May 2012 11:38:29 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Thu, 10 May 2012 11:38:29 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: h10g2000pbi.googlegroups.com; posting-host=76.126.112.84; posting-account=bRPKjQoAAACxZsR8_VPXCX27T2YcsyMA User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.168 Safari/535.19,gzip(gfe) Original-Xref: usenet.stanford.edu gnu.emacs.help:192415 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:84826 Archived-At: On May 10, 1:44=C2=A0am, David Belohrad wrote: > Hi there, > any help would be appreciated: > > I want to open a file on the remote machine. I've setup tramp to use > abbrev to expand an abbreviation to full path, e.g.: > > xhs -> //ssh:xxx@xxxx#1222:/mnt/mp3/ > > As I'm using already yasnippet for something else, using abbrev for this > seems to be just a duplication of what yasnippet does in more generic > way. > > However, as yasnippet is using set of directories to identify major mode > and select appropriate snippet 'set', I'm not sure into what directory I > should put my snippets so they get expanded only when I have to specify > directory or file.... > > any comments? > > thanks > d. it looks like your expansion is static, so you don't really need yasnippet for that. emacs abbrev feature will do. here's examples of how =E3=80=88Using Emacs's Abbrev Mode for Abbreviation=E3=80=89 http://xahlee.org/emacs/emacs_abbrev_mode.html as to your specific question about yasnippet, i don't know the answer but someone probably will answer. Xah