10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi - I have req to join broken lines and remove empty lines but should NOT be in one line. It has to be as is line by line. The challenge here is there is no end of line/start of line char.
thanks in advance
Source:-
2003-04-34024|04-10-2003|Claims|Claim|01-13-2003|Air Bag:Driver;... (7 Replies)
Discussion started by: Jackceasar123
7 Replies
2. UNIX for Dummies Questions & Answers
I have an amount of folders and I want to delete only the empty ones. But I have more than 200 empty folders, so I would preffer do not delete one by one... I know it is possible, but I don't know how. I've tried with the size, using 'du' command, and saving the result in a file. After that, I made... (3 Replies)
Discussion started by: saitsug
3 Replies
3. Shell Programming and Scripting
I am using following code to delete all the empty sub dirs from the inputted dir $1.
Before deleting empty dirs, I want to print those dirs which are going to be deleted.
Can this be done with little modification in following code
#!/bin/sh
if ; then
echo "Searching '$1' dir for empty... (16 Replies)
Discussion started by: ajaypatil_am
16 Replies
4. Shell Programming and Scripting
Hi
What I'm trying to do is delete every blank line upto a certain number, so for instance I only want to delete the first 4 empty lines within a file, I know how to delete every line with:
sed '/^$/d'
But I can't figure out how to limit it to only the first 4 occourances
I though it... (5 Replies)
Discussion started by: duonut
5 Replies
5. UNIX for Advanced & Expert Users
Hi,
I want to delete all empty directories in a long directore tree structure. I want to use that from a script that will run on HP-UX 11. My definition of empty directory is that there is no regular file under it and directly beneath it. To elaborate, I have below directories.
/app/dev/java... (14 Replies)
Discussion started by: asutoshch
14 Replies
6. Shell Programming and Scripting
hi,
I'd like to ask you if you can help me with such surely easy thing - I have some data and need to plot them. I have txt of data in two columns, tab separated, but some second columns are empty. like
1```` 2
1.2``
3```` 2
4.44`
5`````
6.1```1
how can I erase all the lines... (2 Replies)
Discussion started by: bsco
2 Replies
7. Homework & Coursework Questions
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:
A set of Linux shell scripts is required to allow users to ‘remove' files without them really disappearing... (1 Reply)
Discussion started by: mr100perecent
1 Replies
8. Shell Programming and Scripting
How to delete all leading empty lines in a file?
$>cat input.txt
test
Test
$>
output file should be
test
Test
$> (14 Replies)
Discussion started by: johnveslin
14 Replies
9. Shell Programming and Scripting
Hi,
Please provide shell script to Remove empty lines(space) between two lines containing strings in a file.
Input File :
A1/EXT "BAP_BSC6/07B/00" 844 090602 1605
RXOCF-465 PDTR11 1
SITE ON BATTERY
A2/EXT... (3 Replies)
Discussion started by: sudhakaryadav
3 Replies
10. Shell Programming and Scripting
Hi,
I need to delete the lines with empty name.
What is the best way to do it?
Thanks a lot for your help!
EMID MMDDYY HOURS JOB EMNAME
0241 051605 11.40 52062 someone
0520 051605 10.63 52062
0520 051605 10.66 52062
0520 051605 10.65 52062 (3 Replies)
Discussion started by: whatisthis
3 Replies