This is what I came up with so far, thank you for the hints:
But I'm having a hard time understanding how I can search for one string (ex. iso name) and if found, use the same line and check for another string (hash sum).
The result of the code above is this; --- Post updated at 12:02 PM ---
I spoke too soon.
I came up with this:
It works fine from what I can see but any pointers on improvements would be welcomed!
The following find command works on the Korn Shell command line:
find . \( ! -name . -prune \) -type f -name "*.txt" -mtime +100
In the particular directory I'm in, the above find will list correctly the three text files that exist that haven't been modified in over 100 days:
... (3 Replies)
Hi all,
Iam trying to sort the contents of the file based on the position of the file.
Example:
$cat sample.txt
0101020060731 ## Header record
1c1 Berger Awc ANP20070201301 4000.50
1c2 Bose W G ANP20070201609 6000.70
1c2 Andy CK ANP20070201230 28000.00... (3 Replies)
Hi Guru's,
I need to create 3 files with the contents "ABC" using single command.
Iam using:
echo "ABC" > file1.txt file2.txt file3.txt
the above command is not working. pls help me...
With Regards / Ganapati (4 Replies)
Hi,
I don't know hot to make this command work:
ls -laR | grep "^-" | awk '{print $9}'| grep "$.txt"
It should return the list of file .txt
It's important to search .txt at the end of the line, becouse some file name have "txt" in their name but have other extensions (13 Replies)
I have many Gaussian output files, which contain a string start from "HF=" but follws the different values. I'm trying to get this exact string from these txt files.
example 1,
2.524075,-0.563322,-1.285286\H,0,-2.544438,-0.678834,1.199166\H,0,2.18
... (7 Replies)
I have a file that I ran the dos2unix utility on, it cleans up pretty well, but I noticed an occasional ^M leftover, (actual characters) these may or may not be strays from my original dos file. Either way, I want to get rid of the ^ and any character that may follow. ^M ^C or whatever.
How do I... (6 Replies)
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
Create a Shell script that looks for all text files in your home directory (including subdirectories).
List... (3 Replies)
Hi all.
I have a .txt file that I need to sort it
My file is like:
1- 88 chain0 MASTER (FF-TE) FFFF 1962510 /TCK T FD2TQHVTT1 /jtagc/jtag_instreg/updateinstr_reg_1 dff1 (TI,SO)
2- ... (10 Replies)
Discussion started by: Behrouzx77
10 Replies
LEARN ABOUT DEBIAN
browser::open
Browser::Open(3pm) User Contributed Perl Documentation Browser::Open(3pm)NAME
Browser::Open - open a browser in a given URL
VERSION
version 0.03
SYNOPSIS
use Browser::Open qw( open_browser );
### Try commands specific to the current Operating System
my $ok = open_browser($url);
# ! defined($ok): no recognized command found
# $ok == 0: command found and executed
# $ok != 0: command found, error while executing
### Try all known commands
my $ok = open_browser($url, 1);
DESCRIPTION
The functions optionaly exported by this module allows you to open URLs in the user browser.
A set of known commands per OS-name is tested for presence, and the first one found is executed. With an optional parameter, all known
commands are checked.
The "open_browser" uses the "system()" function to execute the command. If you want more control, you can get the command with the
"open_browser_cmd" or "open_browser_cmd_all" functions and then use whatever method you want to execute it.
API
All functions are not exported by default. You must ask for them explicitly.
open_browser
my $ok = open_browser($url, $all);
Find an appropriate command and executes it with your $url. If $all is false, the default, only commands that match the current OS will be
tested. If true, all known commands will be tested.
If no command was found, returns "undef".
If a command is found, returns the exit code of the execution attempt, 0 for success. See the "system()" for more information about this
exit code.
If no $url is given, an exception will be thrown: "Missing required parameter $url".
open_browser_cmd
my $cmd = open_browser_cmd();
Returns the best command found to open a URL on your system.
If no command was found, returns "undef".
open_browser_cmd_all
my $cmd = open_browser_cmd_all();
Returns the first command found to open a URL.
If no command was found, returns "undef".
AUTHOR
Pedro Melo, "<melo at cpan.org>"
COPYRIGHT & LICENSE
Copyright 2009 Pedro Melo.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.14.2 2012-03-09 Browser::Open(3pm)