Bash is a free shell for Unix-like operating systems from the GNU Project.

learn more… | top users | synonyms

0
votes
0answers
24 views

Is it possible to reuse functions I defined in .bashrc from zsh?

I am using bash on my Mac and I spent a lot of time customising functions in there. One things stops me from adopting zsh fully on Mac: I am not that proficient in zsh so I am pretty sure I can ...
0
votes
0answers
19 views

Location of commands executed in past

With HISTTIMEFORMAT="%d/%m/%y %T ", history command shows the exact time of the execution of a command. Is there a way to find from which folder the command was executed?
0
votes
0answers
119 views

exclude files when uploading via ncftp / ncftpput

i found a well working solution for my server setup thanks to this Question: Syncronizing files over FTP Now I have only NcFTP available on my Webserver http://ncftp.com/ncftp/doc/ncftpput.html and ...
0
votes
0answers
77 views

SSH .bashrc Alias for `Clear` Command Twice

Sometimes it is helpful to call clear twice to add some padding so that scrolling up or down will allow us to look at the output of previous commands easier, e.g. I can segregate compiler output by ...
0
votes
0answers
43 views

If screen's C-a A command does not work, what internal state must be wrong?

In the Linux command screen, you can type C-a A to change the name of a window. Right now I am running a screen session with six windows. The first four have custom names - great. The last two I want ...
0
votes
0answers
50 views

Piped processes in upstart shell script continue running after stopping

I have an upstart script on my CentOS box that runs a shell script. The shell script runs a netcat command whose output is piped through a couple other commands and then ends up in a file. When I ...
0
votes
0answers
37 views

programmatically configuring osx loginwindow

I wonder if one can devise a tool for system administrators to programmatically configure that the login window doesn't show user accounts' full names, but short names instead? This used to be ...
0
votes
0answers
121 views

Highlight bash output in iTerm 2?

I've followed the instructions for installing Solarized on iTerm 2, on my new OSX Yosemite machine. It looks as though the background and basic colours are being applied, and $TERM produces ...
0
votes
0answers
105 views

Unable to run script, which emails me results, as super user. (returns: send-mail: 550 5.1.0 Not our Customer)

I have been trying to debug this for 2 days now, without success. This is the script I'm trying to run: #!/bin/bash emailaddress='my_username@gmail.com' output=`sudo rsync -av --delete ...
0
votes
0answers
77 views

Theme problems with vim and terminal

everyone. Trying to figure out a weird problem I'm having with VIM, that's probably just me being a complete novice with the program. I started using it today, and was told to use Vundle to manage ...
0
votes
0answers
108 views

How to make an application accessible for ISPConfig's shell user?

We are using ISPConfig to manage our VPS. We have created a domain with a shell user assigned to that domain. There is an application installed on the VPS that is called Drush (shell application for ...
0
votes
0answers
104 views

PHP - Exec on user's GUI session

I am trying to get a PHP script to execute an Applescript which opens an application.* PHP is running under the _www user. And while it can execute Applescripts with the osascript command, it can't ...
0
votes
0answers
31 views

Linux file “.bash_eternal_history” truncated?

I wanted to save all of my terminal activity on my linux system (ubuntu 14.04 LTS), so I read about the existence of the ".bash_history" and ".bash_eternal_history files". I read from here an ...
0
votes
0answers
21 views

Staret managed server using Jenkins

I am trying to start web-logic managed server from Linux system. for that I have one shell script start_wls_managed4_btwnpmd01.sh with following code. ...
0
votes
0answers
37 views

How to close a GUI window from BASH

I can open a GUI window from BASH with the following command: gnome-open /media/UPDATES How do I close it from BASH? (There is no "gnome-close" command.)
0
votes
0answers
50 views

Shell command shortcut using input filename as output filename

Hi could someone help me with a little command shortcut please? Im trying to run an ffmpeg command and was wondering if there was a shorter way to type it, Ive been reading up on parameter expansion ...
0
votes
0answers
15 views

Defining git commands on windows

I have a script that I use to add some functionality to git. For this particular case I cannot do it with an alias. The name of the script is git-cim. In linux if I place this script in my path and ...
0
votes
0answers
33 views

Is it possible to modify .bash_logout?

I am trying to modify .bash_logout to append the shell history to a txt file. I am also trying to figure to make some restrictions on that file. I have tried a bunch of commands while searching about ...
0
votes
0answers
37 views

ddclient updating to public IP instead of private IP

This is the antithesis to question 389125 I have private services (apache, ssh, synergys for example) accessible on a desktop on the local network. This is not with centralised login (ldap/AD for ...
0
votes
0answers
96 views

file RELATIVE_PATH must be passed a full path to the file

Everytime I want to build smth using: cmake -DCMAKE_INSTALL_PREFIX" I'm getting errors like this: CMake Error at /usr/share/cmake-2.8/Modules/CMakePackageConfigHelpers.cmake:177 (file): ...
0
votes
0answers
15 views

In-browser bash

I'm thinking over possible improvement of bash console. As for me, I'm not very happy with terminal shortcuts, which conflict with OS hotkeys. These days I work much with IPython, which has ability ...
0
votes
0answers
17 views

How to check a range of zipped files

I am looking for any ideas how to check for particular entry in given range of time in logs. If I am checking logs just from one day, I can do the following: more /var/logs/log.08.12.log | grep ...
0
votes
0answers
63 views

Pulling a repo on Raspberry PI boot?

I'm getting stuck on this : I try to make a git pull on a repo on Raspberry boot. What I've done so far : In /etc/rc.local : su pi -c bash /home/pi/boot.sh My boot.sh script : #!/bin/sh set -e ...
0
votes
0answers
36 views

Find files containing a specified string

I should do this exercise, someone would be so kind to help me? Write a script that shows the list of files containing a string supplied as input in content The user must be able to ...
0
votes
0answers
13 views

Restrict shell (sh/bash) to a list of allowed parents?

Does anybody know whether is it possible, without modifying the source code, to restrict shell execution to a list of "white-listed" parent processes (in practice getty, x-term, sshd, /sbin/init or ...
0
votes
0answers
31 views

Need help fixing Pathway on Mac OS X 10.6.8(Snow Leopard)

Whats up folks, i have posted this question on other forums but got no reply, just note before you read, my terminology is not the greatest, im only studying IT this year, so my knowledge be still a ...
0
votes
0answers
23 views

ddclient: Script to change hostname in ddclient.conf

I need to change the hostname in /etc/ddclient.conf based on data stored in a MySQL table. I tried reading ddclient usage documentation, but couldn't find a way to do this. I wanted to avoid parsing ...
0
votes
0answers
57 views

Close terminal if exit code is not 0 for command after login

For security, I'm trying to set up double authentication for a CentOS server. The way it works is you log into a user with SSH keys then once you log in it executes su to change to the root user, ...
0
votes
0answers
58 views

Looking for a Batch script or Jenkins plugin

I have a two Jenkins jobs. First one do the build and copy the special version number in a property file. In my second Jenkins job, I read that property file in parameterized variable setup and ...
0
votes
0answers
27 views

Bash script monitor file modification after its closed

It has already been asked here and I have found the solution for the first part of my question. So for the moment I have a bash script (script1) where I evaluate the sha1sum of a specific file ...
0
votes
0answers
149 views

how to bring network up at boot time in ubuntu 14.0.4

I am write one shell script which execute on every boot, Script is as below. service lsyncd stop /etc/init.d/networking force-reload ifconfig eth0 > /home/sachin/status.txt old="0.0.0.0"; ...
0
votes
0answers
52 views

Monitoring a log file and send a notification (mail) when string is triggered

I want a nofitication (email) when the user-foobar is triggerd in the apache log like this 10.10.55.171 - userfoobar [21/Nov/2014:12:06:01 +0100] "GET /download/2719/test.jpg HTTP/1.1" 200 ...
0
votes
0answers
37 views

Add credits to the end of the video

Is it possible to use ffmpeg to make credit titles at the end of the video ? I have a very long string of authors separated by comma as input. Managed to create 1 frame and append all the string to ...
0
votes
0answers
15 views

rename using perl eval can mmv do this

Linux Mint 17 64-bit The following works to rename the numbering of files. # rename -n 's/(\d+)(.*)/($1+99).$2/e' *.txt 1-file.txt renamed as 100-file.txt 3-file.txt renamed as 102-file.txt ...
0
votes
0answers
87 views

Not able to open crontab -l

I am running crontab -l to view the crons on a RHEL server(v5.10) and getting the below error: crontab: error while loading shared libraries: libaudit.so.1: cannot open shared object file: No such ...
0
votes
0answers
22 views

Recursively create/update tarballs of old files inside directories

I have an archive directory of ftp files. I want to schedule a job to zip up any files that are older than 6mo into an tarball in each directory. I've started writing the script, but I feel like ...
0
votes
0answers
75 views

linux bash/terminal emulator: key “q” not work

i am on debian, Xfce desktop env. When i press the "q" Key, there is no output on the terminal emulator screen/ bash standard output. The capital "Q" works. In vim the "q" works like every other ...
0
votes
0answers
9 views

Tab complete setsid

I regularly use setsid to open a program as a separate process, however it doesn't use tab completion so I end up writing the full program name. Is it possible to add tab completion to setsid? Has to ...
0
votes
0answers
67 views

How can I get the current song of a shoutcast server?

I have a Shoutcast radio station and I want to get the current song and artist into my bash script. What's the best way to do that?
0
votes
0answers
44 views

How is a basic daemon made on OSX?

I have an OSX system that I'd love to have some daemons set up on that will automate the updating of all of my console utilities. How would I go about creating and running such daemons? I'd also like ...
0
votes
0answers
24 views

Is “Lynx: can't access startfile” normal when I'm looking for broken links? I'm kinda desperate

I'm doing a script in bash for checking broken links, is it normal that the dialogue "Lynx: Can't access startfile" appears when I run the script? This is my code so far: #!/bin/bash ...
0
votes
0answers
62 views

Linux bash - Add alias from script without source(-ing) the script

Is it possible to write a script like #!/bin/bash alias foo="bar -options" and get the alias added to the running shell without source(-ing) the script source myscript will work, but just ...
0
votes
0answers
34 views

Run xdg-open on mouseclick in a linux terminal emulator

I'd like the following functionality in a terminal emulator: after typing ls and pulling up a list of files, I'd like to be able to click on the file. This should runxdg-open on the file. This action ...
0
votes
0answers
28 views

openSUSE server terminal showing missing .} after pressing enter without any command input

My openSUSE server terminal is showing a missing .} after pressing enter without any actual command input. I think it might be a bash version issue but how to confirm & solve as I searched and I ...
0
votes
0answers
253 views

Shell Script automatically exits from SSH section after switching of user (through pbrun command)

I have the below piece of code.. ssh some_user@server << EOF echo 'Successfully connected to the server' pbrun previlige -u user ls pwd id ...few more commands EOF if [ $? -eq 0 ] then echo ...
0
votes
0answers
20 views

OSX 10.9 network up triggers browser launch with router configuration page

I have installed a MIFI tool a while ago on an OSX 10.9 and since then every time the network connection is up, a browser window pointing to 192.168.1.1 is opened. I uninstalled the MIFI tool and ...
0
votes
0answers
236 views

bash: git-receive-pack: command not found

I've just changed the git remote for my server, and now when I try to use git push web master, (after staging and committing the changes), I get this: bash: git-receive-pack: command not found fatal: ...
0
votes
0answers
65 views

Send stdout and stderr to file, and store the pid in another file using nohup

I am modifying a script to use my jar as a service. I am stuck with this line here: nohup java -jar $PATH_TO_JAR /tmp 2>> /dev/null >> /dev/null & echo $! > $PID_PATH_NAME I want ...
0
votes
0answers
49 views

Bash Script - Find “ERROR” and output to file

I'm writing my first bash script and could use some help / advice. I cannot test the script at the moment - just want to know if I have it setup correctly. I have a file $A_HOME/bin/nohup.out and I'm ...
0
votes
0answers
40 views

How to use bash to open several terminal instances

My current setup involves starting my computer up, loading several terminal instances, resizing them to fit in a grid, then loading a command on each to watch output Is there a way where I can set up ...