Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #176602

Re: reportbug and remapped "edit"

From kamaraju kusumanchi <raju.mailinglists@gmail.com>
Newsgroups linux.debian.user
Subject Re: reportbug and remapped "edit"
Date 2017-01-12 07:10 +0100
Message-ID <sYGKd-t5-1@gated-at.bofh.it> (permalink)
References <sYs4x-7ZN-5@gated-at.bofh.it> <sYEp4-7eK-13@gated-at.bofh.it> <sYFEt-7Y4-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Wed, Jan 11, 2017 at 11:53 PM, David Wright <deblis@lionunicorn.co.uk> wrote:
> On Wed 11 Jan 2017 at 22:38:48 (-0500), kamaraju kusumanchi wrote:
>
>> Just unalias the alias corresponding to edit (the one you set up in
>> ~/.zshrc) before launching reportbug. After that set it back. IIUC
>> there is no need to launch a bash subshell to do this. You can do
>> everything while you are in zsh.
>>
>> So the sequence of commands would be
>>
>> % unalias edit
>> % reportbug &
>> % alias edit='emacsclient -c -s /tmp/emacs1000/server'
>
> If you're going to do it that way, you've really got to
> interrogate the old value and restore it afterwards, rather
> than having edit defined in two places. Otherwise, how do
> you keep them in sync.
>
> Most people wouldn't run reportbug often enough to worry
> about a subshell, would they?

There are always multiple ways to solve a problem often with different
advantages/disadvantages. I do not have a problem with subshell per
se. My point is that the previously proposed solution requires OP to
start a different shell (i.e. zsh users starting bash). What is to
assume that there is no such alias defined in ~/.bashrc?

Little bit of a side note: I work on systems where my home directory
is mounted across multiple machines. On different machines I use
different shells. To keep my aliases synced across all these machines,
I place all my aliases in a separate file and source that file in
~/.zshrc, ~/.bashrc etc.,

raju
-- 
Kamaraju S Kusumanchi | http://raju.shoutwiki.com/wiki/Blog

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

reportbug and remapped "edit" Boyan Penkov <boyan.penkov@gmail.com> - 2017-01-11 15:30 +0100
  Re: reportbug and remapped "edit" David Wright <deblis@lionunicorn.co.uk> - 2017-01-11 16:00 +0100
    Re: reportbug and remapped "edit" Hans <hans.ullrich@loop.de> - 2017-01-11 16:10 +0100
      Re: reportbug and remapped "edit" Boyan Penkov <boyan.penkov@gmail.com> - 2017-01-11 16:40 +0100
  Re: reportbug and remapped "edit" kamaraju kusumanchi <raju.mailinglists@gmail.com> - 2017-01-12 04:40 +0100
    Re: reportbug and remapped "edit" David Wright <deblis@lionunicorn.co.uk> - 2017-01-12 06:00 +0100
      Re: reportbug and remapped "edit" kamaraju kusumanchi <raju.mailinglists@gmail.com> - 2017-01-12 07:10 +0100
        Re: reportbug and remapped "edit" Boyan Penkov <boyan.penkov@gmail.com> - 2017-01-12 13:30 +0100
        Re: reportbug and remapped "edit" David Wright <deblis@lionunicorn.co.uk> - 2017-01-12 17:30 +0100
          Re: reportbug and remapped "edit" Greg Wooledge <wooledg@eeg.ccf.org> - 2017-01-12 17:30 +0100
            Re: reportbug and remapped "edit" Nicolas George <george@nsup.org> - 2017-01-12 17:40 +0100
              Re: reportbug and remapped "edit" Greg Wooledge <wooledg@eeg.ccf.org> - 2017-01-12 17:50 +0100
                Re: reportbug and remapped "edit" David Wright <deblis@lionunicorn.co.uk> - 2017-01-12 22:10 +0100
          Re: reportbug and remapped "edit" Boyan Penkov <boyan.penkov@gmail.com> - 2017-01-12 18:30 +0100
      Re: reportbug and remapped "edit" Boyan Penkov <boyan.penkov@gmail.com> - 2017-01-12 13:30 +0100
      Re: reportbug and remapped "edit" kamaraju kusumanchi <raju.mailinglists@gmail.com> - 2017-01-13 03:00 +0100
        Re: reportbug and remapped "edit" Boyan Penkov <boyan.penkov@gmail.com> - 2017-02-07 16:20 +0100
    Re: reportbug and remapped "edit" Nicolas George <george@nsup.org> - 2017-01-12 10:30 +0100
  Re: reportbug and remapped "edit" Jonathan Dowland <jmtd@debian.org> - 2017-01-12 11:10 +0100

csiph-web