Cannot install patch because of previledges restriction

Asked by frank

I cannot overwrite/patch the gimp_xcf.py file in the extension directory of inkscape. It tells me I'm not "the owner".
How can I solve this problem?

Question information

Language:
English Edit question
Status:
Answered
For:
Inkscape Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
su_v (suv-lp) said :
#1

Which OS and Inkscape version are you using?
What patched version of 'gimp_xcf.py' are you referring to?

Revision history for this message
frank (notolose) said :
#2

my versions:

Ubuntu 10.10 - the Maverick Meerkat
Inkscape 0.48

The patch can be found here:
http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/annotate/head%3A/share/extensions/gimp_xcf.py

it is from this post:
https://bugs.launchpad.net/inkscape/+bug/285558

thx for your answer

Revision history for this message
frank (notolose) said :
#3

This is the error inkscape gives me when I try to export a xcf

Traceback (most recent call last):
  File "gimp_xcf.py", line 185, in <module>
    e.affect()
  File "/usr/share/inkscape/extensions/inkex.py", line 215, in affect
    self.effect()
  File "gimp_xcf.py", line 179, in effect
    x = open(xcf, 'r')
IOError: [Errno 2] No such file or directory: '/tmp/tmpSH2WZk/Work.xcf'

Revision history for this message
jazzynico (jazzynico) said :
#4

Hello Frank,

On Ubuntu, you need to use sudo to copy a file to a protected part of the filesystem.
Assuming the python file is on your home, the command line would be:
# sudo cp ~/gimp_xcf.py /usr/share/inkscape/extensions/

While your at patching this extension, you can also overwrite the inx file (the trunk one provides some new options).

Regards.

Revision history for this message
frank (notolose) said :
#5

@JazzyNico

I've put the new gimp_xcf.py in the home location. Then I past the code you give me in the terminal, the old gimp_xcf.py is not been replaced/overwritten by the new one though.

what could the reason be?

thx for your reply

Revision history for this message
jazzynico (jazzynico) said :
#6

Do you get a feedback from your command line (error, warning)?

# ls -l /usr/share/inkscape/extensions/gimp_xcf.* should return a recent date for the python file (and an older one for the inx one if you didn't update it).

Revision history for this message
frank (notolose) said :
#7

@JazzyNico

I past in the terminal: # ls -l /usr/share/inkscape/extensions/gimp_xcf.*
It doesn't return anything. There's something wrong...

thx for the reply

Revision history for this message
frank (notolose) said :
#8

could you guys tell me the code to make the directory "/usr/share/inkscape/extensions/" writable so I can change the file manually?

Revision history for this message
frank (notolose) said :
#9

Please guys, any help?

Revision history for this message
jazzynico (jazzynico) said :
#10

Hi Frank,

When I write to type # something, the "#" stands for the command prompt and should not be entered in the command line. Could you please retry "sudo cp ~/gimp_xcf.py /usr/share/inkscape/extensions/" (with no # and, uh, no quotes ;).
Sorry, it's my fault, I was not clear enough.

Regards.

Revision history for this message
frank (notolose-googlemail) said :
#11

@JazzyNico
File overwriting solved. Thx for your help.

The problem with the xcf export still persist anyway. I am gonna open a post dedicated to this new problem.

Thx

Can you help with this problem?

Provide an answer of your own, or ask frank for more information if necessary.

To post a message you must log in.