02-02-2010
hi frank ,
Could get clear info on your requirement .
Its advisable that you attach a sample file.
what i have understood from your description is you have a file like this :
ipadreees path
ipadress path
and you want to isolate and put ip_addr and paths to variables.
Is this correct ?
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I have couple of shell scripts.
Each shell script accepts command line argument as inputfilename.
Each shell script creates a summary file, status file.
All these files are stored in a particular directory...Eg
InputFile is to be picked from /home/ProjectName/ftp_inputfiles/
Outputs are to... (1 Reply)
Discussion started by: Amruta Pitkar
1 Replies
2. Shell Programming and Scripting
Hi,
I have a file paths.txt with all the file paths. I want to tar everything in those paths to a file.
for example paths.txt contains
/data/extention
/logs/extension
/code/extenstion
Now I want to tar using command
tar cvf extention.tar path1 path2
where
path1 -> /data/extention... (2 Replies)
Discussion started by: muaz
2 Replies
3. Shell Programming and Scripting
There is a file paths.txt with paths containing data for example
E:/<BUILD_NAME>/data/common
E:/<BUILD_NAME>/log/common
E:/<BUILD_NAME>/temp/common
E:/<BUILD_NAME>/code/common
While reading this file I want to replace the <BUILD_NAME> from a variable $BUILD in the following command:
tar... (1 Reply)
Discussion started by: muaz
1 Replies
4. Shell Programming and Scripting
Hi everyone! I'm pretty bad at shell scripting and I am trying to create a java launcher. The idea is to store in a configuration file different paths (each for a different java version) and then, run a .sh file that would read the specified java path and execute the .jar file. This is what i have... (7 Replies)
Discussion started by: mostacholoco
7 Replies
5. UNIX for Dummies Questions & Answers
Hi!
I would like to funnel a series of directories and subdirectories into a text file. This is the output I would like to see from a find command:
/mypath/ABC_01/VISIT_01
/mypath/ABC_01/VISIT_02
/mypath/ABC_01/VISIT_03
/mypath/ABC_02/VISIT_01
/mypath/ABC_03/VISIT_01
I've tried:
find... (2 Replies)
Discussion started by: goodbenito
2 Replies
6. Shell Programming and Scripting
Hi guys,
I'm working on a large set of scripts to move files around several servers and manipulate them for our staff. Basically we're shooting things, the videos hit a server and then need organised due to the language they've been shot in. Our XML (designed for Apple's Final Cut Pro) is right... (6 Replies)
Discussion started by: omfgbunnies
6 Replies
7. Shell Programming and Scripting
Hello all,
I am new to scripting and here is what I want to get done.
I need to run some processing on many files. I have a whole bunch of files among which there are a few that I am interested in. What I need to do is to write a script which reads the file paths from a text file. line by... (1 Reply)
Discussion started by: pavo-cristatus
1 Replies
8. OS X (Apple)
Hi all my very first post so go easy on me!!
I am trying to build a very simple script to list a file path with spaces in. But I can't get around this problem. My script is as follows:
#!/bin/bash
X="/Library/Users/Application\ Support/"
LS="ls"
AL="-al"
$LS $AL $X
The response I... (5 Replies)
Discussion started by: tillett22
5 Replies
9. Shell Programming and Scripting
I am working on a script for Mac OS X that, among many other things, gets a list of all the installed Applications. I am pulling the list from the system_profiler command and formatting it using grep and awk. The problem is that I want to be able to use each result individually later in the script.... (3 Replies)
Discussion started by: cranfordio
3 Replies
10. Shell Programming and Scripting
Hi I want to know how to handle the spaces in the below scenario.
I have a file (CON_zip_path_1.txt) which has some directory paths with spaces in directory names . My requirement is to unzip these zip files to
another path. Please see the code below and the error.
CON_zip_path_1.txt... (4 Replies)
Discussion started by: paul1234
4 Replies
LEARN ABOUT DEBIAN
graphics::primitive::canvas
Graphics::Primitive::Canvas(3pm) User Contributed Perl Documentation Graphics::Primitive::Canvas(3pm)
NAME
Graphics::Primitive::Canvas - Component composed of paths
DESCRIPTION
Graphics::Primitive::Canvas is a component for drawing arbitrary things. It holds Paths and Operations.
SYNOPSIS
use Graphics::Primitive::Canvas;
my $canvas = Graphics::Primitive::Canvas->new;
$canvas->move_to($point); # or just $x, $y
$canvas->do($op);
DESCRIPTION
The Canvas is a container for multiple Paths. It has a path that is the operative path for all path-related methods. You can treat the
Canvas as if it was a path, calling methods like line_to or move_to.
When you are ready to perform an operation on the path, call the do method with the operation you want to call as an argument. Drawing a
line and stroking it would look like:
$canvas->move_to(0, 0);
$canvas->line_to(10, 10);
my $op = Graphics::Primitive::Operation::Stroke->new;
$stroke->brush->color(
Graphics::Color::RGB->new(red => 0, blue => 1, green => 1)
);
$canvas->do($op);
When you instantiate a Canvas a newly instantiated path resides in path. After you call do that current path is moved to the paths list
and new path is placed in current_path. If you want to keep the path around you can call save before do then call restore to put a saved
copy of the path back into path.
METHODS
Constructor
new Creates a new Graphics::Primitive::Canvas
Instance Methods
do Given an operation, pushes the current path onto the path stack.
FIXME: Example
path
The current path this canvas is using.
path_count
Count of paths in paths.
paths
Arrayref of hashrefs representing paths combined with their operations:
[
{
path => $path,
op => $op
},
]
restore
Replace the current path by popping the top path from the saved path list.
save
Copy the current path and push it onto the stack of saved paths.
saved_paths
List of saved paths. Add to the list with save and pop from it using restore.
saved_path_count
Count of paths saved in saved_paths.
AUTHOR
Cory Watson <gphat@cpan.org>
COPYRIGHT & LICENSE
Copyright 2008-2010 by Cory G Watson.
You can redistribute and/or modify this code under the same terms as Perl itself.
perl v5.12.3 2010-08-21 Graphics::Primitive::Canvas(3pm)