Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Problem with user function
- X-seq: zsh-users 29702
- From: Duke Normandin <dukeofpurl@xxxxxxx>
- To: zsh-users list <zsh-users@xxxxxxx>
- Subject: Re: Problem with user function
- Date: Fri, 23 Feb 2024 11:50:13 -0700
- Archived-at: <https://zsh.org/users/29702>
- In-reply-to: <20240223113550.3e60e168b4bbbed3e3104c7d@gmx.com>
- List-id: <zsh-users.zsh.org>
- References: <20240223104901.35a540adb685459cdfe3c2a5@gmx.com> <CAN=4vMr5iEcRAudk5RAjkxVt8ruf-qnz+A63efLxR=Lya0JyZg@mail.gmail.com> <20240223113550.3e60e168b4bbbed3e3104c7d@gmx.com>
- Ui-outboundreport: notjunk:1;M01:P0:a8RlFQRVKPA=;YOWR4nEjExZ0SCZM3sOM3RzPuwi hMci/173hQ902mea39Un2GYgMbK6cGVpv5SVpCpMJ0+wHWFL2QIhS7sbc5kuTlomZFoX2DwAY qc/Pbx8Wmawui06kVZmuO5FvkakvI7OVq6CKlBT974tsZ57N9ixyJQ4o2OIGzrbeCVdQwIBzT qLpYntf5HRWF2FlgdarYFViDPhbfaYnP0dyrXvRNnfRbZ6b7OTAdjmy77pq8ZAVZk5xKM/T6H +UdJEH2dXEzO2y1m1pgsvINGx6sY0R/ja4/VklH1+H/lsOB5zkYrISJqKHCBlDvp4/dqjgKv1 b+q6EWjuK/aGPFgQWf1jjS9Mu+s59YcRhZP529LeOzNLRYKZsFEHPXAc6Rb5p1Z/3PszU1Nrl ock5RF6RqKY6pd1z8K7xhtnXrQbsAK6ZgxjcEaGQNrByJSuyHLRanJE8ERMqgrvW2sFHp9kF2 GwLC1tfFotm5LzlWinuce3isOKxTmOUtzC4YpL0cWvdONfldB+s4N7lYwc4bgKOpOzAOSAkSy 5GoPxog+uWz3vRKs5VpydhK7trbl+3wbbm5JuQvgG3pfXOr5dWl+HbWpA39NzaqVq8bY+zvbE Z7mSWC/P+qiNOBQXFkHZUeTdJwvSGdbIoN4cWnMvcuR5WCa3dJE0z8gUZ3dZcWIEorHIR0Cxr rNPfwsVZsMJ8TLdJzyVt1JnuKKaerOKJrpeW6HjhmrHOz71PpMQjtmedkFqLdq0Ret/euYj4D FczIDqimx9NY2sri/vvYhdD9jAHWNoT92a9ojtNdk3H239s1sdAt9f1NHb0AqBHRopUQRhURa 38FynJaTdqtndaIigo49GNmf9jEKtULTL63bofQ90OJL8=
On Fri, 23 Feb 2024 11:35:50 -0700
Duke Normandin <dukeofpurl@xxxxxxx> wrote:
> On Fri, 23 Feb 2024 19:30:15 +0100
> Roman Perepelitsa <roman.perepelitsa@xxxxxxxxx> wrote:
>
> > On Fri, Feb 23, 2024 at 6:49 PM Duke Normandin
> > <dukeofpurl@xxxxxxx> wrote:
> > >
> > > After installing .oh-my-zsh, I get this error msg, which I
> > > didn't while running plain zsh.
> > >
> > > .zshrc:92: defining function based on alias `ls'
> > > .zshrc:92: parse error near `()'
> > >
> > > The errors refer to a few functions that I use to take notes:
> > >
> > > n() {$EDITOR ~/notes/${1}.txt}
> > > l() {$PAGER ~/notes/${1}.txt}
> > > nls() {ls --group-directories-first -c --color ~/notes/${1} }
> >
> > I don't see anything wrong with this code. The error you've got
> > happens when you do this:
> >
> > alias ls='ls -A'
> > ls() { whatever; }
>
> No! It happens when I launch a terminal and my .zshrc file is
> read.
>
> > Does your .zshrc attempt to define a function called "ls" on
> > line 92? What does that line look like?
>
> It looks like what I included in my original message. See above in
> the quotes!
> --
> Duke
I fixed the problem by appending `function' before the function
names. The problem went away!
--
Duke
Messages sorted by:
Reverse Date,
Date,
Thread,
Author