Sponsored Content
Top Forums Shell Programming and Scripting need to remove a range of files Post 302303970 by ghostdog74 on Saturday 4th of April 2009 05:41:03 AM
Old 04-04-2009
Quote:
Originally Posted by jim mcnamara
Code:
for file in update.0001* update.0002*
do
    rm -f $file
done

would this be easier?
Code:
rm -f update.0001* update.0002*

 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

cp only files in certain date range

hi all, I'm trying to do a cp only on files I created on a given day or within a certain date range. What's the best way to do this? Cheers, KL (1 Reply)
Discussion started by: ee7klt
1 Replies

2. Shell Programming and Scripting

remove range part of a file with sed

Hello, I would like to remove a range from a file with sed or any script command that is appropriate The section start by and finish by and I would like to keep line Could you tell me which command I should type ? Thanks a lot, Franck My input file is like this... (1 Reply)
Discussion started by: mfranck
1 Replies

3. Shell Programming and Scripting

Remove strings within range using sed

Hey folks I have a big file that contains junk data between the tags <point> and </point> and I need to delete it (including `<point>' and `</point>'). i.e. a = 1 <point> 123123 2342352 234231 234256 </point> print a needs to become a = 1 print a I'm certain that this is a... (10 Replies)
Discussion started by: ksk
10 Replies

4. Shell Programming and Scripting

remove unwanted specific line range

Hello everyone...I have large txt file and I would like to remove unwanted specific line. My data is like this: So I would like to remove from line below No. until line reassambled like this: Thanks... (4 Replies)
Discussion started by: taxi
4 Replies

5. Shell Programming and Scripting

Remove a range of lines from a file using sed

Hi I am having some issue editing a file in sed. What I want to do is, in a loop pass a variable to a sed command. Sed should then search a file for a line that matches that variable, then remove all lines below until it reaches a line starting with a constant. I have managed to write a... (14 Replies)
Discussion started by: Andy82
14 Replies

6. Shell Programming and Scripting

Remove duplicate entries based on the range

I have file like this: chr start end chr15 99874874 99875874 chr15 99875173 99876173 aa1 chr15 99874923 99875923 chr15 99875173 99876173 aa1 chr15 99874962 99875962 chr15 99875173 99876173 aa1 chr1 ... (7 Replies)
Discussion started by: raj_k
7 Replies

7. UNIX for Advanced & Expert Users

Vi remove line range containing a string

In vi I would like to remove a line containing a string. I thought after reading this I could do this. https://www.unix.com/302297288-post3.html :'3560,3572/gcc/d' It keeps complaining vi mark not set. And sometimes it complains E488: Trailing characters. I don't understand what mark... (5 Replies)
Discussion started by: cokedude
5 Replies

8. Shell Programming and Scripting

awk to remove range of fields

I am trying to cut a range of fields in awk. The below seems to work for removing field 50, but what is the correct syntax for removing a range ($50-$62). Thank you :). awk awk 'BEGIN{FS=OFS="\t"}{$50=""; gsub(/\t\t/,"\t")}1' test.vcf.hg19_multianno.txt > output.csv Maybe: awk... (6 Replies)
Discussion started by: cmccabe
6 Replies

9. Shell Programming and Scripting

Check/print missing number in a consecutive range and remove duplicate numbers

Hi, In an ideal scenario, I will have a listing of db transaction log that gets copied to a DR site and if I have them all, they will be numbered consecutively like below. 1_79811_01234567.arc 1_79812_01234567.arc 1_79813_01234567.arc 1_79814_01234567.arc 1_79815_01234567.arc... (3 Replies)
Discussion started by: newbie_01
3 Replies

10. Shell Programming and Scripting

sed or awk to remove specific column to one range

I need to remove specific column to one range source file 3 1 000123456 2 2 000123569 3 3 000123564 12 000123156 15 000125648 128 000125648 Output required 3 000123456 2 000123569 3 000123564 12 000123156 15 000125648 128 000125648 (6 Replies)
Discussion started by: ranjancom2000
6 Replies
UPDATE-INETD(8) 						      rlinetd							   UPDATE-INETD(8)

NAME
update-inetd - manage rlinetd (and inetd) configuration entries SYNOPSIS
update-inetd [options] --add ENTRY update-inetd [options] --remove SERVICE update-inetd [options] --enable SERVICE update-inetd [options] --disable SERVICE DESCRIPTION
update-inetd is a rlinetd's compatibility script, which can be used to by various Debian post-installation scripts to manage services in rlinetd configuration files directory /etc/rlinetd.d. update-inetd will spawn update-inetd.real(8) for managing entries in /etc/inetd.conf file. Please see update-inetd.real(8) for details. ACTIONS
--add ENTRY Adds an entry, which should be a line in a inetd.conf(5) format. --remove SERVICE Removes a service. --enable SERVICE Enables a service. --disable SERVICE Disables a service. OPTIONS
--version Prints version information on standard output and exit successfully. --debug Enables debugging mode. Note the option is also passed to update-inetd.real(8). Any other option is passed directly to update-inetd.real(8). FILES
/etc/rlinetd.conf, /etc/rlinetd.d/*, /etc/inetd.conf SEE ALSO
update-inetd.real(8), inetd.conf(5), rlinetd.conf(5), inetd2rlinetd(8) AUTHOR
Robert Luberda <robert@debian.org> Debian January 3rd, 2009 UPDATE-INETD(8)
All times are GMT -4. The time now is 11:11 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy