Skip to content
Advertisement

Tag: bash

bash scripting, handling spaces in filesnames in a for loop strange behaviour

help. everything i’ve tried has failed. I’m trying to fix up my video collection and lots of them have spaces in the names/etc I want to transcode them and I’ve written the script below, but its failing. 2 of the filenames I’m using for testing are “13 Eerie (2013).avi” and “Ace.Ventura.When.Nature.Calls.1995.720p.WEB-DL.x264-mSD.mkv” i have tried several things from using print0 on

script for deleting queues using a certain prefix

i have a file named “Output_File.txt” containing a list of local queues and i want to write a script to delete those queues. what i wrote is: the problem is that the script does delete the queues but prints for every deleted queue the following output: how can i alter the code to delete the queues without printing the output

what does a if mean during variable assignment

I am going through a couple of BASH scripts. And I came across something like this Apparently the Variable VAR_S should not be empty and I am trying to wrap my head around this statement. What does if=${MY_FILE} mean here. I am trying to figure out why VAR_S is returning empty when I echo it.It seems to me like if

unexpected behaviour of ACL linux [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers. This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question

Convert number from text file

I have a file: id name date 1 paul 23.07 2 john 43.54 3 marie 23.4 4 alan 32.54 5 patrick 32.1 I want to print names that start with “p” and have an odd numbered id My command: grep “^p” filename | cut -d ‘ ‘ -f 2 | …. result: paul patrick Answer Awk can do it all:

Get specific column from CSV in Bash script

I have a csv with nearly a hundred of column. I am writing a bash script to get only few of those column. CSV: I did some research and found this: But it requires to put ALL the column (92 in my case…) I can’t select want I want. So I try another solution: It cannot work because of the

Advertisement