Sponsored Content
Top Forums Shell Programming and Scripting Remove single @ on line from file Post 303035215 by nezabudka on Thursday 16th of May 2019 12:24:48 PM
Old 05-16-2019
Hi
Code:
sed 's/@\w\+\.\w\+/@REDACTED/g'

or
Code:
sed 's/@\w\+\.\w\+/@REDACTED/3'

This User Gave Thanks to nezabudka For This Post:
 

10 More Discussions You Might Find Interesting

1. Programming

remove single-line comment

Does anyone knows how to write a program to remove single-line comment in C program? that means it don't read anything behind // (3 Replies)
Discussion started by: Icy002
3 Replies

2. UNIX for Dummies Questions & Answers

Trying to remove single character from a line

Here is a sample code grep '903' -i user.txt | tail -2 | awk '{print $2}' | sed 's/B//g' the input file has data as such 903-xxx-xxxxB 903-xxx-xxxxB It is a dialer file i want to remove the "B" any help thanks (5 Replies)
Discussion started by: Iz3k34l
5 Replies

3. UNIX for Dummies Questions & Answers

how to remove mutilple enrty in a single line in unix

Hi, Below is a single line output. subsD,01 02 03 04 05 00 00 00 00 07 00 05,hlr,common,00000000 subsD,01 02 03 04 05 00 00 00 00 07 00 05,hlr,01,baoc|notActive|notInduced,activeAndOperative,notActive,notActive,noneDesignated,0,notActive|00|,notActive|00|,notActive|00|,notActive|00|30|,,... (4 Replies)
Discussion started by: kaprus
4 Replies

4. Shell Programming and Scripting

Need to remove multiple text from a single file

Dear all, I have a file which have let us say records from A-Z. Now I want to remove multiple letter from this file using single command.. let us say I want to remove A,F,K,Y,U,P,B,S,D. I can use grep -v command but for this case i need to rerun the file several time i wana avoid using... (3 Replies)
Discussion started by: jojo123
3 Replies

5. Shell Programming and Scripting

awk concatenate every line of a file in a single line

I have several hundreds of tiny files which need to be concatenated into one single line and all those in a single file. Some files have several blank lines. Tried to use this script but failed on it. awk 'END { print r } r && !/^/ { print FILENAME, r; r = "" }{ r = r ? r $0 : $0 }' *.txt... (8 Replies)
Discussion started by: sdf
8 Replies

6. Shell Programming and Scripting

Formatting File having big single line into 95 Char Per Line

Hi All, I have 4 big files which contains one big line containing formatted character records, I need to format each file in such way that each File will have 95 Characters per line. Last line of each file will have newline character at end. Before:- File Name:- File1.dat 102 121340560... (10 Replies)
Discussion started by: lancesunny
10 Replies

7. UNIX for Dummies Questions & Answers

Remove multi line and single line comments

Hi, I am trying to remove multi line and single line comments like examples below I have tried this pattern. it works fine for single line comments and multi line comments in a single line only. but this fails when the comments are extended in multiple lines as shown in the comment 2 of... (3 Replies)
Discussion started by: ahmedwaseem2000
3 Replies

8. UNIX for Dummies Questions & Answers

To find and display the middle line in a file using single line command.

Hi all, How can i display the middle line of a file using a single line command? (6 Replies)
Discussion started by: Lakme Pemmaiah
6 Replies

9. UNIX for Beginners Questions & Answers

Output to file print as single line, not separate line

example of problem: when I echo "$e" >> /home/cogiz/file.txt result prints to file as:AA BB CC I need it to save to file as this:AA BB CC I know it's probably something really simple but any help would be greatly appreciated. Thank You. Cogiz (7 Replies)
Discussion started by: cogiz
7 Replies

10. Shell Programming and Scripting

Remove single-line breaks only in document

Regarding copy/pasted text of copyright-free book from archive.org (link below), in attempt to expand single-line-break paragraph text (not section headings or paragraph breaks) to wider right margin, Justify or Wrap in LIbreOffice is not working, and Find/Replace the paragraph mark ($) wraps all... (2 Replies)
Discussion started by: p1ne
2 Replies
PYTAGS(1)							  [FIXME: manual]							 PYTAGS(1)

NAME
pytags - set and remove tags on media files from filename and options SYNOPSIS
pytags [OPTIONS] file [file...] DESCRIPTION
pytags is a simple, general-purpose tool for setting and removing media file tags. With no options, pytags prints a tag summary for all files specified on the command line. Options can be used to set and remove tags on files. Using --format, it is easy to change or create tags on by parsing metadata from filenames according to an arbitrary format string. This makes it simple to tag files that are consistently named. Additionally, tags can be manipulated directly with the --add, --set, and --remove options. These options are processed in order, so options specified later on the command-line may cause values set by earlier options to be overwritten. These options must appear after the --format, if it is used. OPTIONS
--add=EXPR Append a tag value all files according to EXPR. EXPR should be an expression like "artist=Foo". May be specified multiple times to add multiple values. --format=FORMAT Tag files with metadata extrapolated from filenames using format string FORMAT; see the section called "FORMAT STRINGS". This option must be specified before --add, --set, or --remove. --set=EXPR Set a single tag on all files according to EXPR. EXPR should be an expression like "artist=Foo". May be specified multiple times to set multiple tags. --set cannot be used to specify multiple values for a single tag. To do that, use --remove followed by multiple --add options. --remove=TAG Remove tags named TAG. May be specified more than once to remove multiple tags. -h, --help Show summary of options and exit. -v, --version Show version of program and exit. FORMAT STRINGS
The format string expected by --format is the same as that for pytagsfs. See the pytagsfs manual page for more information. EXAMPLES
Remove the genre tag from all .ogg files in the current directory. $ pytags --remove genre *.ogg Set the artist and album tag on all .mp3 files, and remove the genre tag. $ pytags --set artist=Foo --set album=Bar --remove genre *.mp3 Tag all of the .flac files in the current directory. All such files are assumed to be in the format "tracknum artist - trackname [album].flac". $ pytags --format '%n %a - %t [%l].flac' *.flac BUGS
Please report bugs on launchpad at http://launchpad.net/products/pytagsfs/+bugs. pytags relies on mutagen (the underlying Python tags library) to choose an appropriate tag format for the files being tagged. This cannot currently be overridden. SEE ALSO
pytagsfs(1) AUTHOR
Forest Bond Author. COPYRIGHT
Copyright (C) 2007, 2008, 2009 [FIXME: source] 2009-12-04 PYTAGS(1)
All times are GMT -4. The time now is 01:10 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy