Questions tagged as 'shell'

2
answers

What does -rf after rm mean? [closed]

I have a command in SSH on the Magento platform (installed on an Apache server) to delete the contents of the rm -rf path/to/folder/* cache folder but I'm not really sure for sure what -rf means.     
asked by 13.04.2016 / 22:07
2
answers

Filter number of characters with SED or grep

I have a file with strings I need at first to filter for example only rows that have 5 characters And secondly filter only those that have at least 2 characters repeated together Example: Display aazyx or zyaax but does not display azyxa And thi...
asked by 22.11.2017 / 00:47
2
answers

How to compact directory except a specific folder via SSH with zip command?

I have to compress all files and directories from the public_html directory except var that is over 60GB. How can I perform this operation via SSH with command zip ? I saw some forms with different commands tar and others but I nee...
asked by 20.04.2016 / 13:21
2
answers

How to check if a server is in .ssh / known_hosts?

I have a script that syncs git repositories. If the repository has never been synchronized, the directories are created. Eventually, when a repository is added, the server that serves the repository is not listed in the .ssh/known_hosts...
asked by 24.09.2014 / 23:00
1
answer

MySQL Commands in Shell Script

I'm trying to do a routine to deploy an application, and I came across a problem in the shell script, the mysql-related commands I can not execute inside the same, but at the prompt they work, what should be done? > mysql -u sdesk_autoinstall -...
asked by 16.08.2018 / 13:22
3
answers

Shell: download and unzip on a line

I tried to use wget with tar as follows wget -qO- [url] | tar xvf but I can not get the expected effect. Are there other ways to do this?     
asked by 29.06.2017 / 15:37
1
answer

How to protect file upload in php against shell script

How can I protect sending files with php against shell script, knowing that I only accept one type of extension.     
asked by 28.10.2016 / 03:35
2
answers

Replace files with thirst

Hello, I have a problem that I need to solve. I have a file that should be inserted exactly one column from another file, I am trying it as follows: cat $1 | cut -d ',' -f2 | tr "/" "-" | awk -F "-" '{print $2"-"$1"-"$3}' > temp.txt c...
asked by 02.02.2017 / 14:54
1
answer

Make toast disappear when running root command

Live, I have the phone connected to the computer and when I run root commands by adb, there is always a toast in the crack, is there any way to make these toats disappear? I remind you that they are not being created by my code. I tried to...
asked by 13.04.2018 / 16:17
1
answer

PostgreSQL Download Script Shell

I am writing a code in Shell Script to download the source code of the latest updated version of PostgreSQL by checking the link to the current version automatically. So based on this I did the following: I created the variable URL_PKG...
asked by 05.03.2018 / 08:07