Hi, I am trying to do a find and replace in a text file (a nuke script).
Here are a couple excerpts from the file that demonstrate what I want to do.
I am always looking for the line " name Write1" as my starting point. In the
first example below, I want to replace the path, which is 2 lines above
Hi, the way I do this on mac os x is to use applescript like so.
--start of applescript
tell application "Terminal"
do script "python /Volumes/Seagate750/drive_01/myPythonScript.py"
end tell
--end of applescript
Where you simply point the terminal to the python script using
applescri
>
> You don't seem to understand functions. Part of the point is to *avoid*
> global variables. If everything a function uses is passed in as arguments,
> and if everything it produces is returned as return value(s), it's much
> easier to see its effect. And to make sure it doesn't have bugs.
Pete Froslie wrote:
so, I've been playing with the functions a bit-- took a little time to get
the hang of them after I started that other mess. Initially, I've done the
opposite suggested here by creating functions without the input values. I do
see the where it will pay off in re-usability that
"Rick Pasotto" wrote
using daily. Suddenly when I try to run it I get a segmentation fault.
I'm running debian testing so probably some recent update caused the
breakage. How can I find out what's gone wrong?
Have you got the core file?
If so you should be able to use gdb to examine the st
On 7/12/2009 12:01 PM Pete Froslie said...
(2)not sure why this function doesn't work:
word_count = 0 #set up variable to increment through text
def increment(x):
return x+1
increment(word_count)
You need to capture and assign the result (or possibly restructure to
work
so, I've been playing with the functions a bit-- took a little time to get
the hang of them after I started that other mess. Initially, I've done the
opposite suggested here by creating functions without the input values. I do
see the where it will pay off in re-usability that route.. Alan, I'll re
On Sunday 12 July 2009 11:09, Rick Pasotto wrote:
> I've got a script that I wrote several years ago and have been happily
> using daily. Suddenly when I try to run it I get a segmentation fault.
>
> I'm running debian testing so probably some recent update caused the
> breakage. How can I find out
On Sun, Jul 12, 2009 at 09:54:26AM -0700, Emile van Sebille wrote:
> On 7/12/2009 9:09 AM Rick Pasotto said...
>> I've got a script that I wrote several years ago and have been happily
>> using daily. Suddenly when I try to run it I get a segmentation fault.
>>
>> I'm running debian testing so prob
On 7/12/2009 9:09 AM Rick Pasotto said...
I've got a script that I wrote several years ago and have been happily
using daily. Suddenly when I try to run it I get a segmentation fault.
I'm running debian testing so probably some recent update caused the
breakage. How can I find out what's gone wr
I've got a script that I wrote several years ago and have been happily
using daily. Suddenly when I try to run it I get a segmentation fault.
I'm running debian testing so probably some recent update caused the
breakage. How can I find out what's gone wrong?
--
"Happiness is having a large, lovi
On 7/12/2009 5:52 AM Eike Welk said...
This method exploits the fact that not each character combination is a
valid English word. But there may be collisions: two different
English words that have the same Pig Latin translation.
stop -- opstay
tops -- opstay
Emile
_
Hello Eddie!
On Sunday 12 July 2009, Eddie wrote:
> Hi guys,
>
> What I have here is more of a logic problem that I can't get my
> head around than a programming problem. I am trying to program an
> English to Pig Latin translator. I've got the English to Pig Latin
> part down and its working grea
Eddie wrote:
Hi guys,
What I have here is more of a logic problem that I can't get my head around
than a programming problem. I am trying to program an English to Pig Latin
translator. I've got the English to Pig Latin part down and its working
great.
The part I am having difficulty with is the
Hi guys,
What I have here is more of a logic problem that I can't get my head around
than a programming problem. I am trying to program an English to Pig Latin
translator. I've got the English to Pig Latin part down and its working
great.
The part I am having difficulty with is the Pig Latin to E
"Pete Froslie" wrote
This seems the basic form for a function:
*def** hello*():
*print* "Hello World!"
*return*
That is a very limited form that encourages bad practice. The more
general form is:
def aFunction(inputValue1, inputValue2,...):
# do some processing here
retu
16 matches
Mail list logo