Most voted "shell-script" questions
Shell script is a scripting language
Learn more…262 questions
Sort by count of
-
0
votes3
answers75
viewsShellscript does not run cd, calling sh via php
all right? See if anyone has been through this, I’m with this simple code in shellscript, which access folder (/home/test4toquew5824) and then confirm if I entered the directory with pwd,…
-
-1
votes2
answers541
viewsShell Script Filter and Execution
I have a problem in Shell Script, where: You need to report a file; Check if it’s a file .C, .JAVA or neither of; If you are either, compile as chosen and run; (I don’t know much about Shell)…
-
-1
votes1
answer82
viewsDelete "," in the first and last line of a CSV
I have a csv that’s exported like this: +++ Host - Begin +++,, Name,Description test1,abc2 test2, abd3 +++ Host - End +++,, How do I get this result? +++ Host - Begin +++ Name,Description test1,abc2…
-
-1
votes2
answers230
viewsUsing MKDIR via shell script
I am trying to create a directory via shell script, using the command: mkdir -m755 "/var/www/app.dominio.com/html/$1" where the folder name is passed by parameter, you are getting a question mark…
-
-1
votes1
answer110
viewsBrowse multiple Linux terminal directories
I have an algorithm that starts with a file. From that file, it generates several others. I need to get all the names of these generated files, to from them, run my algorithm again. Basically I…
-
-1
votes1
answer46
viewsSimilar command to python’s Try for shellscript?
I need to formulate a . sh to run a code if the first error: !#/bin/bash python main.py python3 main.py As if it were a python (Try/Except) exception. I thought about creating two . sh scripts, to…
-
-1
votes1
answer25
viewsFile output with YAD
Good morning, everyone, I have some problems with the use of YAD. I have a super functional and very useful shellscript. Now I’m trying to put it in a graphical interface to look really nice and…
-
-2
votes2
answers289
viewsHow to check if ip latency is greater than 0?
Code: if [ 'ping $1 -c1 |grep rtt |awk {'print$4'} |awk -F "/" {'print$2'}' -gt 0 ] then echo "OK" else echo "NO OK" fi Error: ./latencia.sh: line 1: [: ping $1 -C1 |grep rtt |awk {print} |awk -F…
shell-scriptasked 8 years, 2 months ago user55010 1 -
-2
votes2
answers128
viewsTimer for a shell script command
Good afternoon, everyone, I want to write a script with a command that captures all wireless network flow around my company and store it in a text file. Currently I do so: airmon-ng start 'nome da…
-
-2
votes1
answer54
viewsLinux Shell Script - Doubt about variable scope
Num script shell, I want to make an array containing the files of a certain folder. I tried so: declare -a array_arquivos i=0 ls -1 /caminho/minha_pasta | while read file; do…
-
-2
votes1
answer66
viewsGuys, I need to create a shell script code to discover the MTU of the local network with a loop
I’ll send the assignment. Objective: to identify the value of the MTU used in the TCP/IP network local, dynamically and with some heuristic to, in this way, minimize the number of iterations in…
-
-3
votes0
answers21
viewsShell Script: how to log into a php web application using Curl?
Good morning guys, I’m new here... actually, I just made this account for a specific question, because I didn’t find anything relevant to solve my problem. Anyway; I am trying to log into a php web…