Get value of parameter from text file using sed

zer0Id0l

I am trying to extract the value of a parameter from the text file.

Below is my text file with uri_param as parameter.

application.txt
---------------
uri_param=frontier://tenant=stripe;env=qa;[email protected]:80

command:
--------
egrep ^uri_param application.txt | sed -e 's/.*=//'

I am expecting the strign after first = as output i.e. frontier://tenant=stripe;env=qa;[email protected]:80, but the output I am getting is [email protected]:80.

How can I fix this? What I found till now is .* in sed is greedy and it will match the longest string after =.

Arjun Mathew Dan
sed -r 's/^[_0-9a-zA-Z]+=//g' File_Name

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Get value of parameter from text file using sed

From Dev

Using sed to get specific text from XML file

From Dev

extract text from file using sed

From Dev

Unable to parse text from a file using sed?

From Dev

How to get text from range of dates using grep/sed in large text file?

From Dev

How to get text from range of dates using grep/sed in large text file?

From Dev

Windows shell: get parameter value from file

From Dev

Using sed to pull a value from an XML file, and I get whitespace at the beginning. How can I avoid that?

From Dev

How get value from text file in linux

From Dev

How to Get a value from a text file

From Dev

How to get var value from a text file?

From Dev

delete first line from text file in Windows using sed

From Dev

Using sed to extract morse code from a text file

From Dev

Delete specific line number(s) from a text file using sed?

From Dev

delete first line from text file in Windows using sed

From Dev

Copy particular text from one file to other using GREP or SED

From Dev

Append text to file using sed

From Dev

Using SED to delete text in a file

From Dev

Using sed to find-and-replace in a text file using strings from another text file

From Dev

Sed removing text from a File

From Dev

How to get the output from second value using sed

From Dev

bash/sed script to get output from a file using a regex

From Dev

entering a text from a text file before the first line of another file using sed

From Dev

Get the value for a variable from file using tcl

From Dev

Get the value for a variable from file using tcl

From Dev

Grepping with sed from start of the file to given parameter

From Dev

How to get the value from rows and columns from text file in bash?

From Dev

using parameter text file in bash

From Dev

How to get output of particular text from text file using batch?

Related Related

  1. 1

    Get value of parameter from text file using sed

  2. 2

    Using sed to get specific text from XML file

  3. 3

    extract text from file using sed

  4. 4

    Unable to parse text from a file using sed?

  5. 5

    How to get text from range of dates using grep/sed in large text file?

  6. 6

    How to get text from range of dates using grep/sed in large text file?

  7. 7

    Windows shell: get parameter value from file

  8. 8

    Using sed to pull a value from an XML file, and I get whitespace at the beginning. How can I avoid that?

  9. 9

    How get value from text file in linux

  10. 10

    How to Get a value from a text file

  11. 11

    How to get var value from a text file?

  12. 12

    delete first line from text file in Windows using sed

  13. 13

    Using sed to extract morse code from a text file

  14. 14

    Delete specific line number(s) from a text file using sed?

  15. 15

    delete first line from text file in Windows using sed

  16. 16

    Copy particular text from one file to other using GREP or SED

  17. 17

    Append text to file using sed

  18. 18

    Using SED to delete text in a file

  19. 19

    Using sed to find-and-replace in a text file using strings from another text file

  20. 20

    Sed removing text from a File

  21. 21

    How to get the output from second value using sed

  22. 22

    bash/sed script to get output from a file using a regex

  23. 23

    entering a text from a text file before the first line of another file using sed

  24. 24

    Get the value for a variable from file using tcl

  25. 25

    Get the value for a variable from file using tcl

  26. 26

    Grepping with sed from start of the file to given parameter

  27. 27

    How to get the value from rows and columns from text file in bash?

  28. 28

    using parameter text file in bash

  29. 29

    How to get output of particular text from text file using batch?

HotTag

Archive