An automated series of instructions carried out in a specific order, such as a Windows script created to launch a specific program on startup.

learn more… | top users | synonyms (1)

4
votes
4answers
6k views

Setting ID3 title tag to be equal to MP3 file name

Has anyone got a bash script that will go through a media library and set the id3 title tag of each MP3 file to be equal to the file's name? I'm open to other automated methods too. It can be a GUI ...
4
votes
1answer
434 views

how to copy I/O not just redirect (Windows and Linux)

I have a simple call command call calabash -D sim.xpl >test.txt 2>&1 and this redirects into test.txt, how do I do both redirect into a file and allow it to show up in the prompt? (I ...
3
votes
2answers
2k views

Clear the TEMP folder on shutdown

I am following some instructions in More Ways To Speed Up Windows XP to help speed up my computer. One of those was to delete the temp folder on shutdown. Yet after I shutdown and then boot up, the ...
3
votes
1answer
15k views

Change NIC speed/duplex settings in script?

I have a laptop running Windows Server 2003 SP2, with PowerShell installed. Occasionally, this system has to be used in environments where it needs the NIC manually set to 100 Mbps/Full Duplex in ...
3
votes
2answers
3k views

How can I get an interface's bandwidth at any given second from the Linux command line?

I am doing a school project in which I want to get the bandwidth of a network interface at any given second, or some other small increment of time. I need this for a Perl script I am working on. ...
3
votes
7answers
3k views

UNIX find dirs that contain a particular file (pom.xml) then execute command in that dir

I want to, from a root dir, find all dirs that contain a certain file name (pom.xml), then cd to that dir and execute a command. I can do this in a script but I was hoping to do this with a single ...
3
votes
5answers
2k views

How to run a bash script outside of a terminal?

Hey All, wrote this script to confuse my girlfriend when she is using my computer. The only trouble is that if the terminal gets closed the script stops to execute. It currently executes in the ...
2
votes
1answer
76 views

Creating directory name from file name - strip out non alpha numeric characters and make lower case

I am able to create a directory based on the name of a file. I am running into a wall if the text has spaces or non alpha numeric characters. I would like to strip out those non alpha numeric ...
2
votes
2answers
6k views

How to create multiple folders and name them by reading lines from text file?

I have a plain text file named Export.txt. It contains a list of geographical places, preceeded by a 3 digit number with leading zeros. Example --START OF FILE-- 001 Aberdeen 002 Bellevue 003 Camas ...
2
votes
1answer
585 views

Copy all files in folder and subfolders to single folder - with duplicate handling

I need to copy all files in a folder and it's subfolders to a single folder, without copying the subfolders. From searching stackexchange, I've found this script: for /f "tokens=*" %a in ('dir /b /s ...
2
votes
3answers
780 views

Can I use a bash script as a Service in OS X without having to set it up trough automator?

How can I use a bash script as a Service in OS X without having to set it up trough automator? I'd basically like to write a bash script, save it in ~/Library/Services and then just have it show up ...
2
votes
2answers
1k views

Shell script to rename multiple files from their parent folders name

I have a file structure like this: 00000010 000000001.file1 000000001.file2 00000020 00000003.file1 00000003.file2 00000003.file3 ... So there are folders with 8-digit names containing one ...
2
votes
1answer
1k views

Checking VBScript for syntax errors without actually running the script

I have a script in VBScript. I'm not sure if it contains any syntax errors or other non-runtime errors. Normally I would just run the script, but I don't want the script to actually run because the ...
2
votes
3answers
1k views

how to stop bash from printing alerts?

When killing a process with kill -9 $PID &>/dev/null in a script, a message is still printed to the terminal after the next command terminates. How do you stop this behaviour? For example ...
2
votes
2answers
4k views

Is it possible to access the shell (Darwin) on an iPhone?

In order to write some little script for example.
2
votes
2answers
10k views

Starting a script on xfce login and logout?

I use xfce4 as my desktop environment, running on a Gentoo box. I want to start the pulseaudio server when I login. In general, how do I get a script to run as soon as I login to xfce, and how do I ...
1
vote
1answer
57 views

Bash quotes unescaped on command substitution

Can someone explain me why this is working (listing the contents of a directory that has a whitespace in its name): ret="$(ls "my dir")" Shouldn't it rather be interpreted as: ret="$(ls " my dir ...
1
vote
2answers
1k views

How can I write a script to count files modified within a particular month?

I use a PowerShell command to count ZIP files modified within the past 30-ish days, that goes something like this: (gci "\\servername\sharename\foldername\subfoldername\*.zip" | where ...
1
vote
1answer
2k views

How to burn a cd (files not iso) from the command line in Windows 7

I have used robocopy and a script to copy files from various resources. I now want to have my script automatically burn the files I copied to a cd. I'm looking for a command. I have tried xcopy but I ...
1
vote
2answers
3k views

How do I open a random file in a folder, and set that only files with the specified filename extension(s) should be opened?

How do I open a random file in a folder, and set that only files with the specified filename extension(s) should be opened? (While preferably, supporting Unicode filenames too.) I've already looked ...
1
vote
1answer
8k views

Batch file script for Enable & disable the “use automatic Configuration Script”

My intention is to create a .bat file that toggles the check box of "use automatic Configuration Script" in Internet Settings. The following is my script @echo OFF setlocal ENABLEEXTENSIONS set ...
1
vote
1answer
442 views

Simulate pgrep using plain grep

How can I do pgrep -U someUserName using just ps and grep? I.e. not count on pgrep being set in a system?
1
vote
1answer
3k views

outlook automated reply with unread message count

I get hundreds of daily emails and I'm looking to configure an out of office reply for outlook which will inform the recipient that I have X unread emails and that I'll get to theirs as soon as ...
1
vote
0answers
1k views

Macintosh OS X Logout Script

I am working on a project where I need to implement a logout script on some Macintosh computers. I have read the following Create a logoff script/task for Mac OS X article and found that while it is ...
1
vote
3answers
2k views

Linux get single bandwidth usage sample

What I want to do is to write a script that gathers some information (like cpu temperature and bandwidth usage) and logs it into a file. I can't figure out how to get a single sample of the current ...
1
vote
1answer
599 views

String manipulation in Grub2

One of the new features of Grub2 is scriptability. At my work we're using it to great affect. However, I recent stumbled on a terrible short coming. There isn't any string manipulation or ...
1
vote
3answers
2k views

How can I script making a backup of recently modified files in Bash?

I have written this backup script that looks in a file and copies recent files into a folder. #!/usr/bin/bash # the number of days to do the backup for. days=2; # the files to backup. ...
1
vote
3answers
1k views

RSS feed reader that supports filtering? [closed]

In the past I have been using Akregator and GoogleReader to read my RSS feeds. The latter is particularly interesting as I am not right to a single computer and that it supports social sharing. ...
1
vote
2answers
3k views

FTP script won't transfer remote files to local computer

This is a follow up to FTP BAT file - Windows Scheduled Task. I copied the FTP script, but I can't transfer the files to my local computer. All I get is this (server address omitted): 331 ...
0
votes
0answers
826 views

FireFox's NoScript equivalent for IE 11 in Windows 8.1

For my IE 11 in Windows 8, I need a tool I can use to disable/enable JavaScripts on various web pages dynamically when I open a web page - something similar to what the NoScript plugin for FireFox ...
0
votes
1answer
160 views

How to start GUI application with upstart?

I have struggled with this problem for three days and I have tried many ways to solve it but not successful yet. I hope you guys can help me... I have an GUI application. I want to start this ...
0
votes
1answer
152 views

Postgresql starup script for second instance?

I need to run my second postgresql instance when linux boots. I added this command (like in postgresql documentation) in rc.local: /usr/lib/postgresql/9.1/bin/pg_ctl start -l logfile -D ...
0
votes
1answer
308 views

running for loop - but wait for string of words in log file to continue

so far I have this: for each in {01..10} ; do ./sb0$each/tomcat_sb0$each start;done that will start my apps at once, but I want it to wait until it reads one line in a file, what's the easiest way ...
0
votes
1answer
2k views

How can I use a bash script to run nmap and capture both IP and hostname?

I want to scan my network; and return an output like this: Network Scan for 192.168.0.* 192.168.0.1 computer1 192.168.0.2 computer2 192.168.0.3 computer5 echo Network Scan nmap -sP -n ...
0
votes
3answers
500 views

Scripts shell recording playback

I hope this makes sense. I use 'scripts' to make copies of my ssh sessions for various reasons. When I access the logs via less, etc, I see this: Script started on Mon 12 Sep 2011 08:59:14 AM CDT ...
0
votes
1answer
4k views

Quickly running Outlook rules on demand?

I have a rule set up in MS Outlook 2007 that I do not want to run automatically, but I do want to run sporadically by hand. I would like to expedite that "by hand" process as much as possible. Is ...
0
votes
2answers
611 views

Linux rename using parameters and spaces?

Is it possible, in Linux, to rename a file from something without spaces to something containing spaces? I know I can create directories and files with spaces by doing: mkdir "new dir" and: touch ...