10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
please delete! (0 Replies)
Discussion started by: SkySmart
0 Replies
2. Shell Programming and Scripting
I am not a big expert in regex and have just little understanding of that language.
Could you help me to understand the regular Perl expression:
^(?!if\b|else\b|while\b|)(?:+?\s+){1,6}(+\s*)\(*\) *?(?:^*;?+){0,10}\{
------
This is regex to select functions from a C/C++ source and defined in... (2 Replies)
Discussion started by: alex_5161
2 Replies
3. Shell Programming and Scripting
Hello to all,
The Regex below is supposed to match all strings except RR45. I've tested in regex101.com and it works, butwhen I try to use it with the perl command below I get the error shown.
Regex=(?<=^|RR45)(?!RR45).+?(?=RR45|$)
How to fix this? I'm using Cygwin.
$ echo... (9 Replies)
Discussion started by: Ophiuchus
9 Replies
4. Shell Programming and Scripting
In order to clean file from html tags i used the following
sed 's/<*>//g' filename
Right now i need to do the same from php script so i have to use pcre. How to convert? (1 Reply)
Discussion started by: urello
1 Replies
5. Shell Programming and Scripting
Hello,
In one part of my shell program I need to translate many of lines in the following pattern :
/(folder1|...|folderN)/(sub1|...|subN)/.../(file1|...|fileN)
into strings :
/folder1/sub1/.../file1
/folder1/sub1/.../...
/folder1/sub1/.../fileN
...
/folderN/subN/.../fileN
the... (2 Replies)
Discussion started by: Ghadamyari
2 Replies
6. Shell Programming and Scripting
I am having trouble parsing rpm filenames in a shell script.. I found a snippet of perl code that will perform the task but I really don't have time to rewrite the entire script in perl. I cannot for the life of me convert this code into something sed-friendly:
if ($rpm =~ /(*)-(*)-(*)\.(.*)/)... (1 Reply)
Discussion started by: suntzu
1 Replies
7. Shell Programming and Scripting
Why is only hello3 being printed? There must be some kind of syntax problem because the file list definitely includes all the file extensions line by line.
#!/bin/bash
find '/home/myuser/folder/' -name '*.c' -type f | while read F
do
if ] # if the file name ends in .txt.c
then
... (6 Replies)
Discussion started by: cyler
6 Replies
8. Shell Programming and Scripting
can any body translate the follwing script into one that works in bash?
#!/usr/bin/perl
# classify_books.pl
my $csv_file = shift;
my %categories = ( 'childrens' => 'childrens_books.txt',
'horror' => 'horror_books.txt',
'sports ' =>... (3 Replies)
Discussion started by: ferrycorsten73
3 Replies
9. Shell Programming and Scripting
Hello All. I am very new to Linux and I am currently interning. I have been working on a project for 2 weeks now and I have had no success. I have to convert bash shell into perl to decrypt and store files. Here is the code in Linux and Bash. Any help would be greatly appreciated.
$... (0 Replies)
Discussion started by: freak
0 Replies
10. UNIX for Dummies Questions & Answers
Hello All. I am very new to Linux and I am currently interning. I have been working on a project for a week and I have had no success. I have to convert bash shell into perl to decrypt and store files. Here is the code in Linux and Bash. Any help would be greatly appreciated.
$... (0 Replies)
Discussion started by: freak
0 Replies