Hi, i'm not a programmer so I have a very stupid question. I'm trying to
make a practical script. I need to run an executable program in it but i
can't get it to work. Maybe someone here can figure it out easily:
-----
#! /python
a = (recipient's e-mail address)
pgp -feat a
(sendmail to address after encryption)
------
How do I get python to open the pgp program?
Should I use an environment other than python?
thanks! 10 10960
hi,
using python to run shell commands is very easy.
all you need to do is create the command line you would want to run. in your
case:
command = "pgp -feat " + a
and then run it using os.system(), like this:
import os
os.system(command)
if you also want to get the output of the command, you can use the
'commands' module, like this:
import commands
output, rc = commands.getoutput(command)
then you get the output into the variable 'output', and the exit code of the
program into the variable 'rc'.
sagiv.
"Frog" <Fr**********@bigfoot.com> wrote in message
news:7T**********************@Gilgamesh-frog.org... Hi, i'm not a programmer so I have a very stupid question. I'm trying to make a practical script. I need to run an executable program in it but i can't get it to work. Maybe someone here can figure it out easily:
----- #! /python
a = (recipient's e-mail address)
pgp -feat a
(sendmail to address after encryption) ------
How do I get python to open the pgp program?
Should I use an environment other than python?
thanks!
Download Duplicity, there's a nice GnuPG module in it, which would also
demonstrate the technique how this can be done. http://www.nongnu.org/duplicity
To send e-mail is pretty easy by using the standard library. Have a look at
the tutorial which comes with your Python installation.
Best,
Miklós
Frog <Fr**********@bigfoot.com> wrote in message
news:7T**********************@Gilgamesh-frog.org... Hi, i'm not a programmer so I have a very stupid question. I'm trying to make a practical script. I need to run an executable program in it but i can't get it to work. Maybe someone here can figure it out easily:
----- #! /python
a = (recipient's e-mail address)
pgp -feat a
(sendmail to address after encryption) ------
How do I get python to open the pgp program?
Should I use an environment other than python?
thanks!
This is the 3rd time I've downloaded, installed and tried Boa. Each time I
meet with one frustration or another. This time I'm trying to go thru the
Getting Started, and find numerous places that the tutorial does not agree
with the reality or I try something and it does not work.
Has anyone had success with Boa Constructor? If so how did you learn it?
The tutorial clearly is not the way I can learn it.
Bob Gailer bg*****@alum.rpi.edu
303 442 2625
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system ( http://www.grisoft.com).
Version: 6.0.538 / Virus Database: 333 - Release Date: 11/10/2003
Bob Gailer <bg*****@alum.rpi.edu> wrote in message news:<ma************************************@pytho n.org>... This is the 3rd time I've downloaded, installed and tried Boa. Each time I meet with one frustration or another. This time I'm trying to go thru the Getting Started, and find numerous places that the tutorial does not agree with the reality or I try something and it does not work.
I too found that the tutorial was inaccurate (perhaps just out of
date), but I was able to guess what to do instead. Do you have any
specific examples of problems that maybe myself or others could help
with?
Has anyone had success with Boa Constructor? If so how did you learn it? The tutorial clearly is not the way I can learn it.
To be honest with you I gave up on Boa, the main reason being that it
doesn't support wxSizers, which are useful - and with which the visual
designer becomes less important anyway. But I can sympathise with your
frustration. I think that one downside of Python having such great
centralised documentation is that the other projects seem to be very
poorly documented by comparison! Tutorials tend to be out of date, and
a lot of the help I can find on various subjects seems to stop at
'hello world' and then jump directly to the tricks of the trade.
I am attempting to learn how to use wxPython from their mailing list,
from the demos that come with the package, and from the Wiki
( http://wiki.wxpython.org/index.cgi/FrontPage). However, expect to
have to do a lot of cross-referencing, as I couldn't find anything
that could stand alone as a comprehensive guide.
--
Ben Sizer
Bob Gailer <bg*****@alum.rpi.edu> wrote in message news:<ma************************************@pytho n.org>... This is the 3rd time I've downloaded, installed and tried Boa. Each time I meet with one frustration or another. This time I'm trying to go thru the Getting Started, and find numerous places that the tutorial does not agree with the reality or I try something and it does not work.
Has anyone had success with Boa Constructor? If so how did you learn it? The tutorial clearly is not the way I can learn it.
Bob Gailer bg*****@alum.rpi.edu 303 442 2625
--
I too experience your frustration with boa. I finally figured it out
and now enjoy using it. Once you get your first interface built,
there's no stopping you. Remember to create your panel first, then you
can add controls and such to it.
Richard Bird
Bob Gailer wrote: Has anyone had success with Boa Constructor? If so how did you learn it? The tutorial clearly is not the way I can learn it.
I've never tried the tutorial. I just explored the program making some
bogus projects testing all the main features. Then, as I used it, kept
learning the rest of it.
Javier
Kylotan wrote: Has anyone had success with Boa Constructor? If so how did you learn
it?The tutorial clearly is not the way I can learn it.
To be honest with you I gave up on Boa, the main reason being that it doesn't support wxSizers, which are useful - and with which the visual designer becomes less important anyway.
Boa now supports wxSizers.
Javier
Javier Ruere <ja**********@HotPOP.com> wrote in message news:<ma************************************@pytho n.org>... Boa now supports wxSizers.
Javier
The version I have is the same one that is available for download on
the website and seems to have absolutely nothing on wxSizers. In fact
I remember reading recently that there is preliminary support but it
is only in CVS. Perhaps that is what you mean?
--
Ben Sizer
Kylotan wrote: Javier Ruere <ja**********@HotPOP.com> wrote in message news:<ma************************************@pytho n.org>...
Boa now supports wxSizers.
Javier
The version I have is the same one that is available for download on the website and seems to have absolutely nothing on wxSizers. In fact I remember reading recently that there is preliminary support but it is only in CVS. Perhaps that is what you mean?
Yes, that's what I meant. Sizer were added in version 0.2.5 IIRC and
only 0.2.3 seems to be available.
I never used an application directly from CVS before Boa but, since
releases are so far apart and the quality of the code is so good, I
started using the checkout directly. I think it was a really good idea
in this particular case.
Javier
> Yes, that's what I meant. Sizer were added in version 0.2.5 IIRC and only 0.2.3 seems to be available. I never used an application directly from CVS before Boa but, since releases are so far apart and the quality of the code is so good, I started using the checkout directly. I think it was a really good idea in this particular case.
Javier
The problem is that one is not able to chackout tha project, at least it
is not posiible from the place where im sitting. Is there any other way
than cvs to take a look at say, nightly builds?
Michal. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Catalin |
last post by:
How can I make executables with python?
I found some utilities that claim they can do something like that like
Installer and py2exe but they actualy pack the code in a huge arhive!
This solves the...
|
by: Rami A. Kishek |
last post by:
Please help! Very strange installation problem.
First, let me say I successfully installed and use Python 2.2.3 and 2.3
from the EXE binaries on a win ME machine. That machine previously had...
|
by: mike420 |
last post by:
I think everyone who used Python will agree that its syntax is
the best thing going for it. It is very readable and easy
for everyone to learn. But, Python does not a have very good
macro...
|
by: Maboroshi |
last post by:
Hi I am fairly new to programming but not as such that I am a total beginner
From what I understand C and C++ are faster languages than Python. Is this
because of Pythons ability to operate on...
|
by: Michael Scarlett |
last post by:
There is an amazing article by paul graham about python, and an even
better discussion about it on slashdot. The reason I point this out,
is the more I read both articles, the more I realised how...
|
by: Maurice LING |
last post by:
This may be a dumb thing to ask, but besides the penalty for dynamic
typing, is there any other real reasons that Python is slower than Java?
maurice
|
by: Squirrel Havoc |
last post by:
Hello. I am sorry if this has been asked before,
but I am new here.
If I recall correctly, Python can be used as a
scripting language for other programs, as if
the program had a builtin Python...
|
by: Joakim Persson |
last post by:
Hello all. I am involved in a project where we have a desire to
improve our software testing tools, and I'm in charge of looking for
solutions regarding the logging of our software (originating...
|
by: Fuzzyman |
last post by:
It's finally happened, `Movable Python
<http://www.voidspace.org.uk/python/movpy/>`_ is finally released.
Versions for Python 2.3 & 2.4 are available from `The Movable Python
Shop...
|
by: Mark Dufour |
last post by:
Hi all,
I have recently released version 0.0.20 and 0.0.21 of Shed Skin, an
optimizing Python-to-C++ compiler. Shed Skin allows for translation of
pure (unmodified), implicitly statically typed...
|
by: Kemmylinns12 |
last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and efficiency. While initially associated with cryptocurrencies...
|
by: WisdomUfot |
last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific technical details, Gmail likely implements measures...
|
by: Matthew3360 |
last post by:
Hi,
I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web server and have made sure to enable curl. I get a...
|
by: Oralloy |
last post by:
Hello Folks,
I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA.
My problem (spelled failure) is with the synthesis of my design into a bitstream, not the C++...
|
by: BLUEPANDA |
last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS starter kit that's not only easy to use but also...
|
by: Rahul1995seven |
last post by:
Introduction:
In the realm of programming languages, Python has emerged as a powerhouse. With its simplicity, versatility, and robustness, Python has gained popularity among beginners and experts...
|
by: Ricardo de Mila |
last post by:
Dear people, good afternoon...
I have a form in msAccess with lots of controls and a specific routine must be triggered if the mouse_down event happens in any control.
Than I need to discover what...
|
by: jack2019x |
last post by:
hello, Is there code or static lib for hook swapchain present?
I wanna hook dxgi swapchain present for dx11 and dx9.
|
by: DizelArs |
last post by:
Hi all)
Faced with a problem, element.click() event doesn't work in Safari browser.
Tried various tricks like emulating touch event through a function:
let clickEvent = new Event('click', {...
| |