Unix script to read the file and create a file for each line

Clash Royale CLAN TAG#URR8PPP
up vote
-1
down vote
favorite
Please help me on below requirement. I am new to Unix and got this killing situation.
I have a file and my task is to read the file and generate a new file for each line. The name of newly generated file should come from the line content.
Example
Main has 2 records
- My name is hello world
- My Name is not hello world
Target 2 files
File 1 should have 1 record and name of this file is fourth field of row which hello
File 2 should have 2nd record and name of the file should be 4 field of row which is not.
Please help me
shell-script
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
up vote
-1
down vote
favorite
Please help me on below requirement. I am new to Unix and got this killing situation.
I have a file and my task is to read the file and generate a new file for each line. The name of newly generated file should come from the line content.
Example
Main has 2 records
- My name is hello world
- My Name is not hello world
Target 2 files
File 1 should have 1 record and name of this file is fourth field of row which hello
File 2 should have 2nd record and name of the file should be 4 field of row which is not.
Please help me
shell-script
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
up vote
-1
down vote
favorite
up vote
-1
down vote
favorite
Please help me on below requirement. I am new to Unix and got this killing situation.
I have a file and my task is to read the file and generate a new file for each line. The name of newly generated file should come from the line content.
Example
Main has 2 records
- My name is hello world
- My Name is not hello world
Target 2 files
File 1 should have 1 record and name of this file is fourth field of row which hello
File 2 should have 2nd record and name of the file should be 4 field of row which is not.
Please help me
shell-script
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Please help me on below requirement. I am new to Unix and got this killing situation.
I have a file and my task is to read the file and generate a new file for each line. The name of newly generated file should come from the line content.
Example
Main has 2 records
- My name is hello world
- My Name is not hello world
Target 2 files
File 1 should have 1 record and name of this file is fourth field of row which hello
File 2 should have 2nd record and name of the file should be 4 field of row which is not.
Please help me
shell-script
shell-script
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked 3 mins ago
Animesh Saxena
1
1
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Animesh Saxena is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
add a comment |Â
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Animesh Saxena is a new contributor. Be nice, and check out our Code of Conduct.
Animesh Saxena is a new contributor. Be nice, and check out our Code of Conduct.
Animesh Saxena is a new contributor. Be nice, and check out our Code of Conduct.
Animesh Saxena is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f475148%2funix-script-to-read-the-file-and-create-a-file-for-each-line%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password