I have a text file like below
iv_destination_code_10
TAP310_mapping_RATERUSG_iv_destination_code_10
RATERUSG.iv_destination_code_10 = WORK.maf_feature_info[53,6]
iv_destination_code_2
TAP310_mapping_RATERUSG_iv_destination_code_2
RATERUSG.iv_destination_code_2 = WORK.maf_feature_info[1,6]
iv_destination_code_3
TAP310_mapping_RATERUSG_iv...
I have a text file which is:
ABC 50
DEF 70
XYZ 20
DEF 100
MNP 60
ABC 30
I want an output which sums up individual values and shows them as a result. For example, total of all ABC values in the file are (50 + 30 = 80) and DEF is (100 + 70 = 170). So the output should sum up all unique 1st column names as -
ABC 80
DEF 170
XYZ 20
MNP 60...
Do you use newlisp? What have you used it for?
...
I currently have a script that ssh's into another server and runs a command. When the ssh command runs though in prompts if I would like to connect (yes/no) and for the password. Is there a way that when the ssh call is made that I could automatically supply the input for the prompt?
Also, I do realize that using a public key with the...
I want to learn how to write the Javascript/CSS/HTML side of my applications but I want to skip the CSS kludges, bad Javascript, and non-semanitic HTML of the past and jump directly to HTML 5, CSS 3, clean Javascript libraries. I've been reading Mark Pilgrim's Dive In HTML 5 which I think is awesome and now I'd like the equivilent books ...
My hosting company requires me to put #!/usr/local/bin/ruby at the top of every RB file. Is there an easy way to use sed recursively or something that can go through and append this to the top of every rb file?
...
Hi Guys,
I need a script that can gather folders/files information from large drives (600GB to 1TB). The info that I will need are:
Full name/path of the file
File Size
Date Created
Date Modified
Date last accessed.
So far I have the code below:
dir 'e:\' -recurse |
select FullName,Length,CreationTime,LastWriteTime,LastAcces...
I'm using the scripting bridge to query iTunes from my cocoa application. Sometimes iTunes pops up a window (like if an ipod needs updating etc.) and while that popup window is open I can't get any information from iTunes. So if I request information from iTunes when it's in this state my application completely locks-up until that popup ...
My website already runs PHP for it's UI. I now need to code some scripts which will fetch data from certain URL's on a daily basis and populate the database.
If PHP 5, with its enhanced object oriented features and rich libraries is on par with Python on the command line, then wouldn't it make better sense for me to use PHP for both web...
I have a bash script that depends on a group of folders existing, but dont want to create the folders by hand every time I use the script on a new machine.
Right now I have the following for directory detection and creation (taken from here):
for i in {7..0}
do
if [ ! -d "backup.${i}" ]; then
mkdir backup.${i}
fi
done
This d...
I know it's not really a question. But this is bothering me like hell. ASP.net adds so many inline scripts to my pages. Postback scripts, Ajax scripts(many of them), Scroll position script, default button/field script, etc etc etc.
Why on earth would they not just include all this mess in several files. All ajax into its file, all postb...
Hi,
I am using the Google visualization for drawing graphs into my website. This involves a lod of java script.
<script type="text/javascript" src="http://www.google.com/jsapi"></script>
<script type="text/javascript">
google.load('visualization', '1', {packages: ['annotatedtimeline']});
</script>
These two lines of scr...
I have a script set up where someone picks a comic to go to out of the list by appending it to the URL. However, I can't for the life of me get it to accept an enter stroke while inside the text box and still maintain script functionality. Any solutions would be very very much appreciated.
Script/Form looks like this:
function Go...
How can I get my PHP script to only answer requests if the requesting script is on the same domain?
** Edit:
The PHP file is being accessed by an ajax request and is proxy, so I don't want others directly requesting it to come up, is this possible?
...
Hi all,
I'm trying to script a 'git pull' at $dir. It should be the equivilent of 'svn update $dir'.
Does any one know any easy way to do this?
...
I have this PHP script which i'm grabbing images from a directory and displaying them. The directory only has 4 image files in it and yet there are 6 li's. In firebug the images just have the paths 'Images/uploaded/.' and 'Images/uploaded/..'
Are there hidden files that this script is grabbing but not displaying correctly?
<?php
...
I'm trying to write a bash script and I needed to do some floating point math. Basically I want to do something like this:
NUM=$(echo "scale=25;$1/10" | bc)
if [ $? -ne 0 ]
then
echo bad
fi
The problem I'm running into is $? tends to hold the output from the echo program and not the bc call. Is there a way I save the output from the...
I've got this script that runs on a SQL Server Express 2008 machine.
/* BUD501T */
declare @ErrMsg nvarchar(4000)
declare @ErrLine nvarchar(100)
declare @currentFY nvarchar(1000)
declare @programName nvarchar(1000)
set @ErrMsg = ''
set @ErrLine = ''
set @programName = 'BUDPROD - GL_Exp.sql'
select @currentFY = value from Budget...
I've got a file that contains a list of key=value pairs, each on its own line. What's the best way to fetch the value for a specified key using shell commands?
...
Seems like this should be simple, but powershell is winning another battle with me. Simply wanting to output the name of all the services running on a system, and their executable path, and pipe that into something I can use to search through it like Less.
So far I have:
$services = get-WmiObject -query 'select * from win32_service...