Script is series of instructions written in plain text file. The script interpreter (i.e. shell, Python, Ruby, etc.) can read this file and act on the instructions as if they were typed at the command prompt. The interpreter also provides a variety of useful programming features to make your scripts ...

learn more… | top users | synonyms (1)

2
votes
0answers
33 views

How to correctly deploy/install scripts?

I've developed several utility scripts that solve specific problems of my team's day-to-day work. Until now what I have done to deploy the script in my co-workers' laptops is as follows: Every ...
2
votes
0answers
31 views

Where do I put a dyndns script for IPv6?

I am using: /sbin/ip -6 addr|grep -v temporary|grep 'scope global'|grep -oE '([0-9a-f]{0,4}:){1,7}[0-9a-f]{1,4}' to grep my global, non-temporary IPv6 address, that is advertised by my router using ...
2
votes
0answers
67 views

How to have a video player resume from where I last left off?

I'd like to be able to launch a video player (VLC, SMPlayer) via Terminal, using some command like resume_media and then it will automatically find the most recently played media file (.mkv, mp4 etc.) ...
2
votes
0answers
102 views

How do I force nmcli to reconnect to different uuid?

I have a bash script that checks my network environment and mounts shares accordingly. If I'm at work and have a hard-wire connection to the LAN, then I'd like to activate a hotspot connection for ...
2
votes
0answers
258 views

Port redirection for a specific (dynamic) IP using iptables script

What I want: Incoming TCP and UDP connections on port 900 from the resolving IP address of myip.dyndns.org (dynamic IP) should redirect to port 5050 on the local machine. All other IP addresses ...
2
votes
0answers
101 views

Startup script to unmount and re-mount a USB device

I have a Microsoft wireless mouse and it has a scrolling issue in Ubuntu. The scrolling is too sensitive. I've read in other threads that the solution to this is unplugging the USB receiver of the ...
2
votes
0answers
173 views

How can I run a script when I unmount a particular usb drive?

I am trying to sync between a folder and usb drive, so that a) when I plug in a particular usb drive, a script runs to copy any newer files from the usb to the folder; and b) when I unmount the ...
2
votes
0answers
1k views

How to transfer an iPhoto Library to a file based structure and how to manage them properly?

I need to export my old iPhoto Library to a file based structure similar to the format of shotwell. There are some possiblities: Just use the iPhoto Master folder Use Shotwell to import the photos ...
2
votes
0answers
195 views

Activating USB audio with /etc/pm/sleep.d script that runs pacmd commands

Ubuntu annoyingly switches the device for audio input and output from my USB headset to the built-in sound card every time I log out, hibernate, or shut down my computer. This takes place even though ...
2
votes
0answers
181 views

How do I upload pictures to picasa using Nautilus scripts?

I'm looking for a Nautilis script to upload a picture to a Picasa Album using GoogleCL Here is my script : zenity --info --title "File" --text "$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS" --height 18 ...
2
votes
0answers
155 views

Simple program like ratmenu/9menu that can use images as menu items

I'd like to be able to select an album by looking through album covers and launch any mp3 player on it or select an image album by scrolling through sample thumbnails and launch any image viewer on ...
1
vote
0answers
21 views

How do I run as bash script from a WebApp?

I currently am developing a custom Ubuntu dist. that runs a dedicated Kiosk app upon boot. I would like an easy method to shutdown from inside the Kiosk app, but I am currently at a standstill at what ...
1
vote
0answers
29 views

Run a script after every grub-update

I want to run a script automatically after every grub-update. The script itself consists of a single line sed -i 's/[\]"!Windows 2006[\]"/"!Windows 2006"/g' /boot/grub/grub.cfg For this purpose, I ...
1
vote
0answers
47 views

bash script to cd into an USB device

i am creating a simple updater for a program which will be ran on an Odroid C1 with Ubuntu 14.04 Server.. Preamble 1) i want the updater.run downloaded from my server and placed into an USB; then ...
1
vote
0answers
60 views

Running Python script in Abaqus in Ubuntu

I am running a python script through the scripting interface in Abaqus. It's a basic script that writes a value from each element from the abaqus simulation into a a text file. The text file is then ...
1
vote
0answers
49 views

Ubuntu 12.04 LTS scripts in /if-up.d not executed

Since this morning have been trying to achieve something: System: Ubuntu 12.04 LTS, Network-Manager is not installed Goal: Every time, the eth0 network interface is started (if-up.d) we want to ...
1
vote
0answers
62 views

Requirements for KDE startup scripts

I'm running Kubuntu 14.10. I want to include the following startup script for KDE: kstart --desktop 1 firefox kstart --desktop 2 kmail kstart --desktop 3 konsole I placed these three commands in a ...
1
vote
0answers
40 views

How to run scripts on screen sleep / wake

I'm wondering how to run a script when the screen times out and when it wakes. I am not talking about hibernate or suspend, but only when the screen turns off. The reason is I have a LED keyboard and ...
1
vote
0answers
48 views

how to encode a shell script so others can run it but they can not read it

I want to encode a script, so others can run that script to get relevant result but when they run command cat it should throw output in encoded format.
1
vote
0answers
105 views

pdsh works well standalone, but doesn't work in script

I am trying to install hadoop via script on my small cluster [introduced in the book: Apache Hadoop Yarn]. I have set up ssh connect without password, and pdsh&pdcp are all fine if I use it alone. ...
1
vote
0answers
39 views

Upstart - unable to read /etc/shadow unless sudo

In the following script in Upstart, I'm unable to read /etc/shadow in pre-script phase, unless I use $(echo mypass | sudo -S cat /etc/shadow | grep myusername) The script works fine if I provide my ...
1
vote
0answers
46 views

How to autorun a script as root just after the user's encrypted home directory has become mounted on headless server?

There is a problem with ecryptfs that it heavily limits the maximal filename length. To walkaround it I link most home subfolders to the external encrypted partition. The partition gets mounted just ...
1
vote
0answers
152 views

I sudo'd a bash script, full of sudo apt-get install applicationname commands, and now my programs won't run

I sudo'd a bash script, full of sudo apt-get install applicationname commands, and now my programs won't run, unless they are ran as sudo (BAD IDEA!) How do I fix this issue?
1
vote
0answers
45 views

Script for hiding files

I recently found a script for hiding desktop files and folders. The following is the script: #!/bin/bash # cd /home/ramvignesh/Desktop for f in `ls`; do mv "$f" ".$f" done The script isn't working ...
1
vote
0answers
147 views

How do I open an URL from a bash script?

I have a simple script to start a node.js webserver and open the URL in a browser. However the last part doesn't seem to work, it wont open the URL in a browser (or anywhere else). This is the code I ...
1
vote
0answers
181 views

How can I draw selection rectangle on screen for my script?

I am trying to make a simple screencasting bash script. I want to get screen selection coordinates by drawing a red rectangle with mouse. I can use xdotools to get coordinates but how can I draw ...
1
vote
0answers
41 views

suppress all interaction while installing apt-fast

I want to ask whether there is any method to suppress any interaction while installing apt-fast using apt-get. I add the ppa source and then use the next command to install apt-fast: sudo apt-get -y ...
1
vote
0answers
314 views

Can you use gnome keyring in bash script, if yes then how?

I am developing a automated mounting script for Windows shares. I have finished the script and it works just fine, but is it possible to add Gnome Keyring to the bash so once user writes hes/hers ...
1
vote
0answers
72 views

Using a keyboard shortcut to execute a script

Hello I am a linux newbie trying to set up a keyboard shortcut to execute a script I have. The script functions as desired, and is #!/bin/bash livestreamer twitch.tv/arteezy best This opens up ...
1
vote
0answers
63 views

Automatically detecting and outputing to s-video at startup

After combing the Internet I have developed a script that is capable of checking whether I have a monitor connected to my VGA port and switching to my s-video port if not #!/bin/bash # if no vga then ...
1
vote
0answers
22 views

Detect file size decrease

I am saving streams from browser cache into my home folder. I wrote a script that takes the specific data type and saves them into disk, and names them as data.1, data.2 , data.3 and so on, creating ...
1
vote
0answers
99 views

Make right+left click emulate middle click on wireless mouse

Anybody have or know of a sweet little workaround script I can set to running at startup that would allow my dilapidated mouse to keep providing me with middleclick functionality even though the ...
1
vote
0answers
375 views

cannot execute script with sudo no password

I would like to create a batch file that will connect via ssh to my ubuntu server and run a script. My batch file works by using plink, I can see that the call to my script is ran but then I'm asked ...
1
vote
0answers
97 views

acpi-support script missing in rc.d

I've just had a look inside the directories /etc/init.d and /etc/rc.d . I have a 13.10 machine, upgraded from 13.04. Then I saw that this link was missing. S99acpi-support -> ...
1
vote
0answers
147 views

Why won't cron run my sh script?

Used gnome-schedule to create a script to set my headset as the fallback audio device because it keeps unsetting it when the headset gets disconnected or pc goes into sleep mode. Anyway, crontab is ...
1
vote
0answers
115 views

Keyboard shortcut script not working

I finally gave up on getting my Fn+up/down keys to change my screen brightness on my laptop. I took a brightnessup.sh and brightnessdown.sh script and put them in /etc/acpi and then went to keyboard ...
1
vote
0answers
38 views

Does anyone know of a Linux tool which converts hyper-v snapshots to full memory dump files?

hyper-v snapshots are comprised of a .vsv file and a .bin file, and I need to convert these in a full memory dump file. I essentially need this tool: http://archive.msdn.microsoft.com/vm2dmp ...
1
vote
0answers
395 views

xfce4 - 'Run Program' dialogue box does not appear when double clicking script

Ubuntu 12.04 > Xfce4 On my previous Ubuntu distro, when I double clicked scripts I got a little dialogue window that asked me if I wanted to run the script as a program or run it in terminal. ...
1
vote
0answers
64 views

How do you run a programme from a script.sh

What I'm Trying To Achieve I have to start somewhere, so here goes. I am trying to start two programmes at Startup and I would like to learn how to write a script.sh file at the same time. Question ...
1
vote
0answers
195 views

Continue script in terminal after pkill fullscreen program

I'm running a fullscreen program and i'm using pkill to close it by a keyboard shortcut. Killing the program works but my kill script also contains some other code. The rest of the script isn't being ...
1
vote
0answers
285 views

Is it possible to use the conditional arguments in a preseed?

I am trying to create a preseed.cfg that is usable for a CD based installation and a network based installation. I figured the easiest way to do this would be to use a bash conditional "if". As part ...
0
votes
0answers
2 views

syntax error near unexpected token newline' doctype html ' while installing zpanel

I am new to ubuntu, trying to install zpanel on my VPS server.Found some questions with same problem,but none of them was applicable in my case. I have followed this answer to install zpanel, How to ...
0
votes
0answers
20 views

sed error Bash script

So here's the deal I'm trying to do some auto editing of a file with sed in a bash script. Here's my code: systemdate=$(date) sudo mkdir "/tmp/autoupdate" sudo echo "$systemdate" > ...
0
votes
0answers
11 views

Unable to run red.cc file with my tcl script in ns2.35

This is my Tcl script set val(chan) Channel/WirelessChannel set val(prop) Propagation/TwoRayGround set val(netif) Phy/WirelessPhy set val(mac) ...
0
votes
0answers
21 views

Update dynamic IP and fail2ban

i have a script running via cron to allow ssh only through some known IP's. Since my Home-IP is dynamically associated i use this script running every 15min: #!/bin/bash ...
0
votes
0answers
34 views

*beginner* > Beowulf cluster > How to run script along with command line in my cluster

I have a Beowulf cluster system with 1 master node and 3 slave nodes having Ubuntu 14.04LTS version. Now I need to improve the cluster performance in the matter of load balancing, latency, bandwidth ...
0
votes
0answers
23 views

system actions based on keywords in logs

I've been searching for an answer for some time but haven't come up with much. I'm wondering if there is a way to monitor logs in Ubuntu and then launch scripts based on keywords and/or input lines ...
0
votes
0answers
44 views

How to execute script as root during login of specific user?

In my specific case I need to log out user using sudo pkill -KILL -u <username> command and I tried by adding it to .profile and .bash_login but it doesn't seems to work and I couldn't find a ...
0
votes
0answers
49 views

Join Ubuntu to Windows domain “automatically” not by the user!

I'm working on a project related to image cloning using a FOG solution (to clone an image of Ubuntu 12.04 to target machine using FOG server) We also have an active directory (Windows Server 2008) ...
0
votes
0answers
46 views

How to take a picture with the isight camera on mac using terminal

I have been trying to take a picture with a small script but I have no idea. All I want it to do is take a picture then show it without opening apps like photo booth. Ps I don't have sudo permission ...