10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
how can i take the file names from a directory and store only the filenames in the file.
suppose i have a directory which contains the following files and subdirectories.
$ ls -ltr
-rw-rw-r-- 1 adm etc 4 Aug 6 20:37 s1.txt
-rw-rw-r-- 1 adm etc 4 Aug 6 20:37 s2.txt... (11 Replies)
Discussion started by: Little
2. Shell Programming and Scripting
i have a directory at /path/unix with the following files
I want to make another file called filenames.txt at a different location called /path/home. So, my output file would be
/path/home/filenames.txt with contents
/path/unix/1.txt... (1 Reply)
Discussion started by: jacobs.smith
3. Shell Programming and Scripting
I need to get the names of files which are starting with a string testfile. Also i want to create a XML file in the same location and write these file names into the XML.
</dir>... (4 Replies)
Discussion started by: vel4ever
4. UNIX for Dummies Questions & Answers
I need to replace all filesnames in a folder as well as its content from AK6 to AK11. Eg Folder has files AK6-Create.xml, AK6-system.py etc.. the files names as well as contents should be changes to AK9-Create.xml, AK9-system.py etc
All files are xml and python scripts.
---------- Post... (0 Replies)
Discussion started by: Candid247
5. Shell Programming and Scripting
Hi I have some script like this:
perl -i -p0e 's/"keyword1-.*?"/"keyword2"/s' file
to replace some keyword, but it replaces only the first instance of the keyword
how can i get it to replace all instances?
thanks! (2 Replies)
Discussion started by: vanessafan99
6. Shell Programming and Scripting
We have 2 file XML files - FILE1.XML and FILE2.xml - we need copy the contents of FILE1.XML and replace in FILE2.xml pattern "<assignedAttributeList></assignedAttributeList>"
2. <item type="Manufactured">
4. ... (0 Replies)
Discussion started by: balrajg
7. Shell Programming and Scripting
I've got a web access file that I want to grep (or awk or perl or whatever will work!) out the most frequent instances of unique IP entries. Meaning the file looks something like this:
I'd like to run a sort or grep (or whatever) that will only select out the lines from IP's that had the... (7 Replies)
Discussion started by: kevinmccallum
8. Shell Programming and Scripting
I'm trying to change the ramfs size in kernel .config automatically.
I have a ramfs_size file generated with du -s
I want to replace the linux .config's ramdisk size with the above value
Right now I'm doing something dumb like: ... (3 Replies)
Discussion started by: amoeba
9. Shell Programming and Scripting
I have a query on Perl. I have a text file which has 3 lines, i want to only replace the first line with my replaced text and keep the rest of the text. FOr eg
Before change -->
After change --->
echo:b:pending... (1 Reply)
Discussion started by: tosatesh
10. Shell Programming and Scripting
I know this should be simple but the periods in the string replacement are throwing me off.
What I want to do is replace 188.8.131.52 in my access.log file with 184.108.40.206
I have tried using 'tr' but its being thrown off by the periods and replacing all sorts of stuff in the file.
What do I need... (2 Replies)
Discussion started by: LordJezo