From owner-freebsd-questions@FreeBSD.ORG Thu Dec 21 20:13:57 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id F3FBB16A407 for ; Thu, 21 Dec 2006 20:13:56 +0000 (UTC) (envelope-from a@zeos.net) Received: from mail4.ukrpost.ua (mail4.ukrpost.ua [195.5.6.45]) by mx1.freebsd.org (Postfix) with ESMTP id 9F82713C45E for ; Thu, 21 Dec 2006 20:13:56 +0000 (UTC) (envelope-from a@zeos.net) Received: from 9-16-207-82.pool.ukrtel.net ([82.207.16.9] helo=host.my.domain) by mail4.ukrpost.ua with esmtpa (Exim 4.63) (envelope-from ) id 1GxTpy-0004Gt-0z for freebsd-questions@freebsd.org; Thu, 21 Dec 2006 21:45:08 +0200 Received: from host.my.domain (localhost [127.0.0.1]) by host.my.domain (8.13.7/8.13.6) with ESMTP id kBLJi9K0001587 for ; Thu, 21 Dec 2006 21:44:09 +0200 (EET) (envelope-from a@zeos.net) Received: (from elisej@localhost) by host.my.domain (8.13.7/8.13.6/Submit) id kBLJi9ss001586 for freebsd-questions@freebsd.org; Thu, 21 Dec 2006 21:44:09 +0200 (EET) (envelope-from a@zeos.net) Date: Thu, 21 Dec 2006 21:44:09 +0200 From: a@zeos.net To: freebsd-questions@freebsd.org Message-ID: <20061221194409.GA1515@host.my.domain> Mail-Followup-To: freebsd-questions@freebsd.org References: <20061219195359.GA34750@host.my.domain> <20061221184535.GB40028@dan.emsphone.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20061221184535.GB40028@dan.emsphone.com> User-Agent: mutt-ng/devel-r804 (FreeBSD) Subject: Re: Is there UNIX analog of ftp command pls? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Dec 2006 20:13:57 -0000 On Thu, Dec 21, 2006 at 12:45:35PM -0600, Dan Nelson wrote: > In the last episode (Dec 19), a@zeos.net said: > > Is there UNIX analog of ftp command pls, i. e. ls | less ? > > Yes, "ls | less" is the way to do it. You can add a shell alias to > make it easier to type: > > alias pls="ls -l | less" > > That's for bourne-style shells (sh,bash,zsh). for csh, you would use > > alias pls "ls | less" > > Another way to do it would be to write a script named pls and put it in > your path: > > #! /bin/sh > ls "$@" | less > > -- > Dan Nelson > dnelson@allantgroup.com Thank you for response, but I know how to write aliases and bash scripts. I just thought, I don't know the standard way. Apropos, alias pls="ls -l | less" is not a proper way, because of the command pls directory will give ls -l | less directory which is not what one want.