I want to have an alias for the command
fold -78 filename | lp
How do I set my alias so that the argument passed is filename ??
alias lp='fold -78 | lp'
then
lp filename
wont work cuase this is
fold -78 | lp filename (1 Reply)
I've read the man on the alias command, and I am perplexed. I don't see a way to create an alias that will perform more than one command......is there a way to create an alias that is a string of a commands ? (1 Reply)
A good place to start is simple variable passing....
Passing variables from one script to another
The next level is passing a variable into a more complex command such as using a variable in a sed command. There are some simple quoting techniques that are very general. These are mentioned... (0 Replies)
Okay so I have an alias that looks like this:
ALIAS gscn {
MSG gscn Test1
MSG gscn Test2
MSG gscn Test3
MSG gscn Test4
MSG gscn Test5
}
How do I make it wait 5 seconds between each command before it executes the next one after that in order from top to bottom? I tried the TIMER... (1 Reply)
Hi, hope everyone are fine. Please find my issue below, and I request your help in the same
In a configuration file, i have a variable defined as below
TEST = 'One','Two','Three'
I am trying to pass this variable in to a sql script which is define in a pl/sql block
as follows,
In the... (1 Reply)
If one:
$ find -name 'some expression' -type f > newfile
and then subsequently wants to create an alias file from each pathname the find command retrieved and the > placed within 'newfile', how would one do this? Ideally, the newly created alias files would all be in one directory.
I am... (3 Replies)
the scenario is -
If I pass 3 three arguments( run time) , it should list all .txt files from a path to temp file
if I pass 2 arguments ( run time) , it should list all .csv files from the same path to another temp file
the above scenario should be handled in single code and also I dont know ... (2 Replies)
Hi Gurus,
Need some help with the shell scripting here.
#!/bin/ksh
ps -ef | grep -i sample.ksh | grep -v grep > abc.txt
if
then
echo "sample.ksh is executing"
else
echo "sample.ksh is not executing"
fi (1 Reply)
Hi,
I know with getopts you can pass arguments from the command line
./script -ab -c apple
But it doesn't support 2 or more arguments for ONE option. Is there any other way to do this?
Thanks (2 Replies)
Hi
I need to write a script to ssh through several hops (e.g. HostA-HostB-HostC-HostD), where Host A does not have direct assess to HostC ; HostB cannot access HostD directly.
when I ssh 3 hops and run command with arg1, arg2 and redirect the output to a file, e.g.
HostA> ssh -t HostB ssh -t... (3 Replies)
Discussion started by: chiensh
3 Replies
LEARN ABOUT DEBIAN
class::makemethods::emulator::accessorfast
MakeMethods::Emulator::AccessorFast(3pm) User Contributed Perl Documentation MakeMethods::Emulator::AccessorFast(3pm)NAME
Class::MakeMethods::Emulator::AccessorFast - Emulate Class::Accessor::Fast
SYNOPSIS
package Foo;
use base qw(Class::MakeMethods::Emulator::AccessorFast);
Foo->mk_accessors(qw(this that whatever));
# Meanwhile, in a nearby piece of code!
# Emulator::AccessorFast provides new().
my $foo = Foo->new;
my $whatever = $foo->whatever; # gets $foo->{whatever}
$foo->this('likmi'); # sets $foo->{this} = 'likmi'
DESCRIPTION
This module emulates the functionality of Class::Accessor::Fast, using Class::MakeMethods to generate similar methods.
You may use it directly, as shown in the SYNOPSIS above,
Furthermore, you may call "use Class::MakeMethods::Emulator::AccessorFast '-take_namespace';" to alias the Class::Accessor::Fast namespace
to this package, and subsequent calls to the original package will be transparently handled by this emulator. To remove the emulation
aliasing, call "use Class::MakeMethods::Emulator::AccessorFast '-release_namespace'".
Caution: This affects all subsequent uses of Class::Accessor::Fast in your program, including those in other modules, and might cause
unexpected effects.
SEE ALSO
See Class::MakeMethods for general information about this distribution.
See Class::MakeMethods::Emulator for more about this family of subclasses.
See Class::Accessor::Fast for documentation of the original module.
perl v5.10.1 2004-09-06 MakeMethods::Emulator::AccessorFast(3pm)