Upload to BayFiles

Dolphin Service Menus

Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net

0
Score 58.0%
Description:

A simple service to upload any file to BayFiles.com

To install this service menu:

1. as root:
cp bayfiles-upload.desktop /usr/share/kde4/services/ServiceMenus/

2. and as normal user:
kbuildsycoca4

Dependencies:
* curl
* awk
* grep
* tr
* xdg-open
* Perl and libjson-pp-perl(for json_pp)
Last changelog:

8 years ago

0.2 Opens Links webpage instead of displaying a dialog with the link
0.1 First release

masterdany88

8 years ago

Please help me with Dependencies:
* curl
curl is a client to get files from servers using any of the supported protocols. The command is designed to work without user interaction or any kind of interactivity.

curl offers a busload of useful tricks like proxy support, user authentication, ftp upload, HTTP post, file transfer resume and more.

Canonical dostarcza aktualizacje krytyczne dla curl do kwietnia 2013
WHICH IS INSTALLED

* awk
mamwk gawk and original-awk I've installed
* grep- installed
* tr??? what is it???
* xdg-open
xdg-utils and openbox-xdgmenu I've installed
* Perl(for json_pp) ??? what is it??? I have package perl in my repo and I have installed it.


PS. I am using Kubutnu 11.10

Report

masterdany88

8 years ago

tr it\'s like awk. It\'s used to manipulate strings. http://ss64.com/bash/tr.html. I used it to delete , and \" from the recieved links.

Could you try this in a console, see if it works and tell me the results?
curl -s http://api.bayfiles.com/v1/file/uploadUrl | json_pp | grep uploadUrl | awk \'{print $3}\' | tr -d , | tr -d \\\\\"

[code]danielo@danielos:~/pobrane_Firefox$ curl -s http://api.bayfiles.com/v1/file/uploadUrl | json_pp | grep uploadUrl | awk \'{print $3}\' | tr -d , | tr -d \\\\\"
awk: '{print
awk: ^ nieprawidłowy znak ''' w wyrażeniu
[/code]


If you get an try:
curl -s http://api.bayfiles.com/v1/file/uploadUrl | json_pp

[code]danielo@danielos:~/pobrane_Firefox$ curl -s http://api.bayfiles.com/v1/file/uploadUrl | json_pp
{
"uploadUrl" : "http://s7.baycdn.com/upload/78e9a6f5/4f10c663/16/0?X-Progress-ID=4f0b482366CB6D2D7112F86C52C5859B66DF4286",
"progressUrl" : "http://s7.baycdn.com/progress/?X-Progress-ID=4f0b482366CB6D2D7112F86C52C5859B66DF4286",
"error" : ""
}
danielo@danielos:~/pobrane_Firefox$
[/code]

If you still get an error try just
curl -s http://api.bayfiles.com/v1/file/uploadUrl

[code]danielo@danielos:~/pobrane_Firefox$ curl -s http://api.bayfiles.com/v1/file/uploadUrl

{"error":"","uploadUrl":"http:\/\/s1.baycdn.com\/upload\/48c53848\/4f10c683\/0\/0?X-Progress-ID=4f0b4843AF286A0347489C55F4CA19273F73DEEE","progressUrl":"http:\/\/s1.baycdn.com\/progress\/?X-Progress-ID=4f0b4843AF286A0347489C55F4CA19273F73DEEE"} [/code]


If you get an error it means you don\'t have curl, otherwise you don\'t have json_pp

danielo@danielos:~/pobrane_Firefox$ sudo apt-get install libjson-pp-perl[sudo] password for danielo:
Czytanie list pakietów... Gotowe
Budowanie drzewa zależności
Odczyt informacji o stanie... Gotowe
libjson-pp-perl jest już w najnowszej wersji.
0 aktualizowanych, 0 nowo instalowanych, 0 usuwanych i 1 nieaktualizowanych.
danielo@danielos:~/pobrane_Firefox$


still the same error

Report

C

otzy007

8 years ago

Could you try this one and tell me if you get a dialog with the link or any other error?
http://bayfiles.com/file/1lmh/XzXMUm/bayfiles-upload.desktop

Report

masterdany88

8 years ago

Unfortunately still the same error...

Report

C

otzy007

8 years ago

OK. Thank you. I'll get Kubuntu into a virtual machine and try to fix it.

Report

C

otzy007

8 years ago

Do you have installed libjson-pp-perl and libjson-perl?

On my fresh installed Kubuntu the service is working

Report

masterdany88

8 years ago

danielo@danielos:~/pobrane_Firefox/148065-bayfiles-upload$ kbuildsycoca4
kbuildsycoca4 running...
kbuildsycoca4(6614) VFolderMenu::loadDoc: Parse error in "/home/danielo/.config/menus/applications-merged/xdg-desktop-menu-dummy.menu" , line 1 , col 1 : "unexpected end of file"
kbuildsycoca4(6614)/kdecore (services) KServicePrivate::init: The desktop entry file "/usr/share/applications/kde4/koffice.desktop" has Type= "Application" but no Exec line

kbuildsycoca4(6614) KBuildServiceFactory::createEntry: Invalid Service : "/usr/share/applications/kde4/koffice.desktop"
kbuildsycoca4(6614) parseLayoutNode: The menu spec file contains a Layout or DefaultLayout tag without the mandatory Merge tag inside. Please fix your file.
danielo@danielos:~/pobrane_Firefox/148065-bayfiles-upload$




RMB>Upload to BayFiles
Nie można znaleźć programu '-s' =>
It can find program '-s'

thanks in advance

Report

C

otzy007

8 years ago

From kbuildsyscoca it seems you have a problem with kofiice, not from the uploader.

And for the second error it's my fault. In order to use Upload to BayFiles you need to have installed:
* curl
* awk
* grep
* tr
* xdg-open
* Perl(for json_pp)

Report

8 years ago

0.2 Opens Links webpage instead of displaying a dialog with the link
0.1 First release

12345678910
1
product-maker vitoubien Jan 09 2012 9 excellent
product-maker Base: 4 x 5.0 Ratings
File (click to download) Version Description Downloads Date Filesize DL OCS-Install MD5SUM
*Needs pling-store or ocs-url to install things
Pling
0 Affiliates
Details
license
version
0.2
updated Jan 12 2012
added Jan 08 2012
downloads 24h
1
mediaviews 24h 0
pageviews 24h 1
System Tags addon