10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
I would like produce
blue, green, red, yellowfrom"blue:,*green:,*red:,*yellowI can remove the colon with
echo "blue:,*green:,*red:,*yellow" | sed 's/://g'which givesblue,*green,*red,*yellowbut when I try
echo "blue:,*green:,*red:,*yellow" | sed 's/://g'; 's/*//g'I get bash: s/*//g: No such... (9 Replies)
Discussion started by: Xubuntu56
9 Replies
2. Shell Programming and Scripting
There are multiple conditions in which the user can input data.
1. >
2. del
3. ins
4. delins
The user input is saved in a specific directory using the code below:
Code:
cd 'C:'
C:/Users/cmccabe/Desktop/Python27/python.exe C:/Users/cmccabe/Desktop/Python27/run_batch_job.py... (12 Replies)
Discussion started by: cmccabe
12 Replies
3. Shell Programming and Scripting
My file has the entries like below...
/dev/sds
/dev/sdak
/dev/sdbc
/dev/sdbu
I want to make the file like below
echo 1 > /sys/block/sds/device/rescan
echo 1 > /sys/block/sdak/device/rescan
echo 1 > /sys/block/sdbc/device/rescan
echo 1 > /sys/block/sdbu/device/rescan (2 Replies)
Discussion started by: saravanapandi
2 Replies
4. UNIX for Dummies Questions & Answers
Hi I am trying to remove all the symbols in a file (testfile1) and using the below command to do that. Its not working for me. Can you help me on what is wrong with below script?
I want to retain only alphabets in a file and remove all the symbols like *:.+= etc
sed 's/^.//g' testfile1 > testfile2 (4 Replies)
Discussion started by: sandeepcm
4 Replies
5. Shell Programming and Scripting
Hi ,
I have a file myhost.txt which contains below,
127.0.0.1 localhost
1.17.1.5 atrpx958
11.17.10.11 atrpx958zone nsybhost
I need to append words only after "atrpx958" like 'myhost' and 'libhost' and not after atrpx958zone.
How to search the word atrpx958(which is hostname) only,... (5 Replies)
Discussion started by: gsreeni
5 Replies
6. Shell Programming and Scripting
Hi ,
I have a .csv file,from which I want to remove some data from each column as below.
Source Data
GT_12_AUDIT,SCHEDULED,NOZOMI2010/GT_12_AUDIT,CTSCAN/Zh_GT_6547887/GT_12_AUDIT,CTSCAN/Zh_GT_6547887... (3 Replies)
Discussion started by: gaur.deepti
3 Replies
7. Shell Programming and Scripting
Hi guys,
I have a txt file full of funny symbols like the copyright symbol and other funny ones that get in the way when trying to use sed. For example, not sure if you can read this but I have a line that looks like this:
24(9):995Â*1001 DOI: 10.1007/s11606-009-1053-2 ©
When I'm using... (1 Reply)
Discussion started by: joshdg
1 Replies
8. Shell Programming and Scripting
I have a file that needs to be cleaned up. Here is the file:
Project
Project John
Project Gary
Project Sean
Project2
Project2 Lisa
Project2 Tyler
Project2 Sam
Project3
Project3 Mike
Project3 Bran
I need the o/p to be:
Project
John
Gary
Sean
Project2 (7 Replies)
Discussion started by: leepet01
7 Replies
9. Shell Programming and Scripting
Hi All,
I have a text file with name of source files in that. source files ends with .mxml and .css. Now I want to remove the extensions of these source files.
Currently I can do so by writing 2 sed commands, as there are files with just 2 different extensions. But I want to do it in one sed... (6 Replies)
Discussion started by: mkashif
6 Replies
10. Shell Programming and Scripting
Hi
Please tell me how could i delete symbols, whitespaces, characters, words everything between two words in a line. Let my file is
aaa BB ccc ddd eee FF kkk xxx
123456 BB 44^& iop FF 999
xxx uuu rrr BB hhh nnn FF 000
I want to delete everything comes in between BB and FF( deletion... (3 Replies)
Discussion started by: rish_max
3 Replies