Skip to content

Tag: linux

Arithmetic in Shell script

After executing this Here $20 indicates the “S:” entry in each row (I am taking the unique count of all s values),I am getting result as so what I need is the sum of all occurrence of s values .i.e 93070+11666+230 so result be total=104966 Answer

Assigning colors to HTML table columns based on conditions

I am using a bash script to send an email in html table format. I have a command like below. Columns are: scenario: When counts are matching then count_validation column will have ‘Matching’ with green color background else red color background. Same way for amounts. What am I missing or doing wro…

Convert the output of ls in a python list [closed]

Closed. This question needs debugging details. It is not currently accepting answers. Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question. Closed 3 years ago. Improve this question I get…

Can we replace one variable with multiple variables using sed

I have a config file where i need to replace the entire line with new values. It can be either a word or a URL. I am trying to write a script to replace only this particular parameter with new values. I have tried using grep to extract the line using the parameter and divided the values separately and saved

sed: Invalid range end

I am using Lubuntu 19.04. I have a file called text which contains a mixture of upper case and lowercase characters. I am trying to replace all of these characters with ‘*’, but I’m being given an error message. This is my code : sed ‘s/[A-z]/*/g’ text I was expecting an output o…

makefile : How to link object files

I have makefile and I need to link two objects into “main” object They are -> oglinet.o and libshape.o their path in system -> home/pi/openvg/ Problem :I need to write full path and objects name(home/pi/openvg/libshapes.o) is possible to “make” them as Makefile variable for examp…