Bug 984211 - fpaste -l doesn't work with the new paste.fedoraproject.org
Summary: fpaste -l doesn't work with the new paste.fedoraproject.org
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: fpaste
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Ankur Sinha (FranciscoD)
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-07-13 16:52 UTC by Renich Bon Ciric
Modified: 2013-10-11 07:20 UTC (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-11 07:20:13 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
A patch to fix syntax highlighting (9.58 KB, patch)
2013-07-14 00:44 UTC, Othman Madjoudj
no flags Details | Diff

Description Renich Bon Ciric 2013-07-13 16:52:10 UTC
Description of problem:
fpaste -l 'ruby' doesn't work

Version-Release number of selected component (if applicable):
current

How reproducible:
cat hello.rb | fpaste -l ruby
cat hello.rb | fpaste -l rb

Actual results:
it complains about not knowing what "ruby" is and, when one chooses rb, paste.fedoraproject.org doesn't highlight it.

But, when you set Ruby @ paste.fedoraproject.org as the language, it works fine.

Expected results:
It should work and support all the paste.fedoraproject.org languages.

Additional info:

Comment 1 Othman Madjoudj 2013-07-14 00:27:44 UTC
Hi Ankur,

We did not check 'validSyntaxOpts' list and 'ext2lang_map' mapping, when we moved to the new pastebin server, they still use the old values.

Il'll attach valid file type/syntax highlighting values in a moment.

Comment 2 Othman Madjoudj 2013-07-14 00:44:47 UTC
Created attachment 773206 [details]
A patch to fix syntax highlighting

I've attached a patch to fix this issue.

Testing:

$ cat f.rb | ./fpaste.syn-patch -l ruby
Uploading (0.7KiB)...
http://ur1.ca/emwl7 -> http://paste.fedoraproject.org/25170/37376261

Comment 3 Othman Madjoudj 2013-07-14 00:46:48 UTC
File type detection also fixed:


]$ fpaste.syn-patch f.rb 
Uploading (0.7KiB)...
http://ur1.ca/emwm1 -> http://paste.fedoraproject.org/25172/73762746

Comment 4 Renich Bon Ciric 2013-07-14 09:27:09 UTC
That was fast, dude. When can we expect the update? ;)

Comment 5 Ankur Sinha (FranciscoD) 2013-07-14 12:13:59 UTC
(In reply to Renich Bon Ciric from comment #4)
> That was fast, dude. When can we expect the update? ;)

If I find the time, tomorrow ;)

Thanks for the patch Athmane. Can you please open a ticket upstream too, so that they have a copy of the patch too? https://fedorahosted.org/fpaste

Thanks,
Warm regards,
Ankur

Comment 6 Ankur Sinha (FranciscoD) 2013-10-11 07:20:13 UTC
We're carrying a patch in Fedora and the issue has been reported upstream. Closing

Comment 7 Ankur Sinha (FranciscoD) 2013-10-11 07:20:49 UTC
*sigh*


Note You need to log in before you can comment on or make changes to this bug.