Skip to content

Tag: linux

linux find command: exclude path from result

I used the find command to find all python files in a folder, and exlude some folder. find . -type d ( -path ./venv -o -path ./virtualenv -o -path ./lib ) -prune -o -iname ‘*.py’ It’s give the following output: How can I tweak the find command to exclude ./venv in the resultset? Answer If yo…

I want to extract any text between two symbol

I need to execute the file (a.out) and at the same time, I just need specific parts of the output, not everything. which is either located between these two string [[….]] or ((…..)). and I don’t have any idea where the other text is located (there is no specific pattern) and how the output l…

Can’t Install Jenkins even though I have JAVA 8

Ubuntut 14.04 LTS According to this I need JAVA 8 and so I downloaded both the JDK and JRE. Unfortunately when attempting to install jenkins again I still get the error message Checking my $PATH and it shows the following The java that should be used is 8. Even running Gives me what I expect Why do I get the

“Cache” credentials on a bash script

I have created a bash script to run a few js scripts into MongoDB. Basically, what I am doing is, running the bash script and passing a parameter in this case called version, example: That will go and execute all scripts for the version 1.0. Now, it is possible that MongoDB requires authentication user/pass, …

How to include path inside bashrc in linux for envirnment

Im testing my code for automation of the installation of a software In bashrc file below: Here im trying to add $SCALA_HOME/bin to PATH. this is the required output: the above code worked to append SCALA_HOME above path but for appending in the same line im not able to do please help me get the correct sed co…