Home Messages Index
[Date Prev][Date Next][Thread Prev][Thread Next]
Author IndexDate IndexThread Index

Re: audio conversion

__/ [ Roy Schestowitz ] on Thursday 16 March 2006 07:06 \__

> __/ [ tomas ] on Thursday 16 March 2006 21:39 \__
>> Hi
>> Thanks for the reply.
>> The error is either command not found when entered as
>> audio_conv.py
> That's what you should expect if the command is not in your /bin PATH and
> is not exectutable.
>> And permission denied when entered as
>> ./audio_con.py
> Try 'chmod 700 ./audio_con.py' . I know it's rather obvious and I don't
> mean to offend your intelligence.
>> This happen is su mode as well as usr mode.
>> I'm happy to use other software to do the work needed
>> but I'd like also to find out why I get these errors as well.
>> thankstomas
> Let me know how it goes. In Linux, execution of files is something which is
> not treated too leniently. Again, you probably know it all too well, so
> don't take offence if I am misinterpreting your level of expertise.
> Best wishes,
> Roy

__/ [ tomas ] on Monday 20 March 2006 05:48 \__

> Hi and thanks for your reply
> I changed the permission like you suggested.
> But still I got nothing. So I tried it with the python
> script in the folder that contains the .wave files that
> I want to convert. So I run the script and it works like
> a charm, well at least it works. So how do I get it to run
> without haveing to copy it to the folder that contains the
> files that I want to convert.
> I'm useing suse 10(64bit)
> thanks tomas


my guess is that we would need to look at the script. I imagine that the
script assumes input files to be residents of the same directory as the
script or the current (working) directory.

One thing you could do is add the Python script to your path, which means it
can be run from any directory rather transparently, much like 'ls' or 'cd'.
I am not sure if copying to file to one of the binary directories, e.g.
/usr/bin/ would achieve this, but it's worth trying. This should work for
executable files, but I don't know about scripts like Perl or Python.

Here is an alternative. Create an executable (shell) file and set its
permission to executable. Have it contain the Python script with its full,
non-relative path e.g.:

,----[ convert.sh ]
| #!/bin/bash
| python /home/tomas/convert-to-mp3.py

Set the file's permissions:

        chmod 700 convert.sh

Log in as root

Now copy the file to your binaries directory (careful here as I am not
entirely sure this is possible)

        cp convert.sh /usr/bin/

Now, go to the directory with the .WAV files, e.g.:

        cd ~/music/wav

And convert


Have a play with this. I am just suggesting ideas off the top of my head.
Perhaps the Net can help further.

I am now waiting for the Gurus to join the discussion and bash me over the
head for suggesting something that may not be ideal or workable.

Best wishes,


Roy S. Schestowitz      |    make install -not war
http://Schestowitz.com  |    SuSE Linux     ¦     PGP-Key: 0x74572E8E
 12:00pm  up 11 days  4:37,  13 users,  load average: 0.35, 0.71, 0.81
      http://iuron.com - help build a non-profit search engine

[Date Prev][Date Next][Thread Prev][Thread Next]
Author IndexDate IndexThread Index