The time now is Thu 19 Apr 2018, 13:44
All times are UTC - 4 |
Page 1 of 3 [38 Posts] |
Goto page: 1, 2, 3 Next |
Author |
Message |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Wed 13 Dec 2017, 14:09 Post subject:
Google-drive Filemanager Subject description: Simple way to upload, download, delete, share files or folders for google-drive |
|
*** Google-drive Filemanager ***
==============================================================
EDIT 2018-01-03: For a completely new version (v2, not compatible with earlier versions), see here:
http://murga-linux.com/puppy/viewtopic.php?p=979148#979148
2018-01-11, update of v2, multiple file section supported from main GUI, see:
http://murga-linux.com/puppy/viewtopic.php?p=979902#979902
==============================================================
Very, very similar to: Dropbox Filemanager from mikeb, I took his GUI concept of a dual pane filemanager (thanks mikeb !!), but then made it for google-drive.
It makes use of the "drive" command line program (it's included in the packages for download below), see here:
https://github.com/odeke-em/drive
(it has tons of options, just basic options are used in Google-drive Filemanager)
Same as for Dropbox Filemanager, this has limitation also that only one file or folder can be selected for upload/download/delete (gtkdialog limitation)
One significant difference is that the 'profile' should be an existing directory (rather than just a name), e.g. /root or /mnt/sda2 (see also info by clicking Help button).
Also: downloading is restricted to that directory (or a subfolder of that directory)
First thing you need to do is to select an existing directory, then click 'New Profile'. A terminal will open and follow the instructions by pasting the URL in your browser, log in at your Google account, click 'Allow', copy the authorization code and paste in the terminal.
EDIT: To explain better: Select the (long) URL in the terminal, fire up your browser and 'paste' it in the address bar by doing mouse middle-click, login if required, click 'Allow', then just select the authorization code, go to the earlier opened terminal and 'paste' it in by mouse middle-click (and press ENTER).
(not sure, this can be hard to do when using touchpad, I always use mouse)
Note: 'Share Url' will give a link for direct download of a file , but the parent folder needs to be marked as 'Shared', otherwise it won't work
(this program can't do that at the moment, so it should be done from google-drive in browser)
(EDIT: changed that in v0.2.0, see below)
Update: v0.2.0
- 'Share Url' will automatically mark file or folder as shared (anyone with the link can view or download
- Added button 'Unshare' to undo that (NOT anyone with the link can view or download, login is required)
- Added tooltips for some buttons and changed Help text (according to above changes)
Update: Version 0.3.2, changes (compared to v0.3.1):
- No absolute dependency anymore for 'yad', if yad is installed there will be option for multiple file selection, if not, the program still runs, but supports single file selection only (thanks mikeb !)
- Fix for 'Add all', uploads folders also now (previously only files)
- Also 'Add all' will be processed in one terminal now (previously was spawning terminal for every file)
- If yad installed (and nothing selected in main GUI), the 'Add' button will give "file-selection" (previously was list) which is better IMO, to be able to browse files or folders for upload from everywhere
Download: googledrivegui pet packages v0.3.2: (from google-drive URL links of course, where else )
32-bit: https://drive.google.com/uc?export=download&id=19MgD8bLApjp-hEcC5S8udihFb0KWTlHb
64-bit: https://drive.google.com/uc?export=download&id=1MNbAkwcwmaXdYGq-JxwBmogQp1yem8BH
Deb packages v0.3.2 (for e.g. DebianDog, Stretchdog, Xenialdog): :
32-bit: https://fredx181.github.io/StretchDog/i386/Packages/Extra/googledrivegui_0.3.2_i386.deb
64-bit: https://fredx181.github.io/StretchDog/amd64/Packages/Extra/googledrivegui_0.3.2_amd64.deb
Here's also a portable version, recommended to extract at the top dir level of a partition, e.g. /mnt/sda2 (to have that partition as 'profile' and have download access to all that (including it's subfolders)
This contains the files 'gdrive_gui' (the executable script to launch the program) and 'drive' (a hidden directory '.gd' and hidden config file '.gdriverc' will be created in (same) profile dir after initiated profile dir).
Portable v0.3.2:
32-bit .tar.gz: https://drive.google.com/uc?export=download&id=1U_CYyPRDmx4Ysf09MDRtFqW1hc_3nQ7f
64-bit .tar.gz: https://drive.google.com/uc?export=download&id=155TUbBuKLZ8nTG2V8jqkBEeVTiyrovaU
See here for experimental version 0.3.0, with support for selecting multiple items (continued with v0.3.1. and higher)
Tested on Tahrpup (x-tahr) and Stretchdog, (and D-pup Stretch), not sure it works on other (older) puppies
It pops up rxvt or xterm for upload/download/delete, about the parameters, I'm not sure, please tell me if there's no terminal showing in case of download, upload, delete, and I'll try to fix it.
Update: Mike Walsh tested v0.2.0 on many puppies (see further in this thread): Tahr64 6.0.5, Tahr 6.0.6 (uefi), Xenialpup 7081, Upup Raring, Slacko 570, Racy 5.5, Lucid.
Works on all, but there can be a problem with authentication, (as is on Upup Raring), all that's required then is to update ca-certificates, Mike provided a pet for it, download:
http://www.mediafire.com/file/rc2e6drbf6f0qcb/Ca_certs-update.pet
EDIT: Also he provided mirrors for googledrivegui , see here: http://murga-linux.com/puppy/viewtopic.php?p=977447#977447
Fred
 |
Description |
v0.2.0 |
Filesize |
135.67 KB |
Viewed |
627 Time(s) |

|
Last edited by fredx181 on Thu 11 Jan 2018, 13:03; edited 24 times in total
|
Back to top
|
|
 |
dancytron
Joined: 18 Jul 2012 Posts: 1027
|
Posted: Wed 13 Dec 2017, 14:37 Post subject:
|
|
Works nicely.
Some instructions on the profile page on how copy/paste works in Xterm might help some people. It took me a few tries to remember.
|
Back to top
|
|
 |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Wed 13 Dec 2017, 15:41 Post subject:
|
|
dancytron wrote: | Works nicely.
Some instructions on the profile page on how copy/paste works in Xterm might help some people. It took me a few tries to remember. |
Thanks Dan !
Yeah, I assume you mean the select <> middle-click thing, for now I edited first post (see EDIT:) to make that more clear.
Fred
_________________ Dog Linux website
|
Back to top
|
|
 |
mikeb

Joined: 23 Nov 2006 Posts: 11100
|
Posted: Wed 13 Dec 2017, 16:50 Post subject:
|
|
Excellent...spread the love
mike
|
Back to top
|
|
 |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Fri 15 Dec 2017, 15:04 Post subject:
|
|
Updated to v0.2.0, (mostly change for share options) see for changes info and download at first post.
Fred
_________________ Dog Linux website
|
Back to top
|
|
 |
Mike Walsh

Joined: 28 Jun 2014 Posts: 3576 Location: King's Lynn, UK.
|
Posted: Fri 15 Dec 2017, 17:50 Post subject:
|
|
Fred, this is excellent. Thank you.
I never thought I'd see it, TBH. It's the Puppy version of the old Ubuntu 'Grive' client. And it's working extremely well in Tahr 64.
(Make sure you give Mike the credit he deserves, too!)
Well done, both of you. Thanks are due all round. Oh, one question while I think of it... Is there a minimum glibc requirement for this, or owt like that? This would be a good addition to the rest of the kennels.....which are all 32-bit.
Mike.
_________________ MY PUPPY PACKAGES | 'Thanks' are always appreciated!
--------------------------------------
 
|
Back to top
|
|
 |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Fri 15 Dec 2017, 19:43 Post subject:
|
|
Thank you Mike !
Quote: | (Make sure you give Mike the credit he deserves, too!) |
Yes, I thanked him much too many times, he deserves only one...
No... seriously, look in his Dropbox GUI topic and you'll see.
Great concept by mikeb indeed !
Quote: | Oh, one question while I think of it... Is there a minimum glibc requirement for this, or owt like that? This would be a good addition to the rest of the kennels.....which are all 32-bit. |
I tested on Debian Wheezy, which has glibc 2.13 and works fine (pleasantly surprised about that, to be honest I didn't expect that), don't know about in case of older glibc than 2.13.
Fred
_________________ Dog Linux website
|
Back to top
|
|
 |
Mike Walsh

Joined: 28 Jun 2014 Posts: 3576 Location: King's Lynn, UK.
|
Posted: Fri 15 Dec 2017, 20:40 Post subject:
|
|
Hi again, Fred.
Perhaps my exuberance was premature...
As I said, the 64-bit version is working fine. Upon trying to install to one of the 32-bit Pups (in this case, Upup Raring (glibc 2.17)), I can't get the profile to set up correctly.
I follow the set-up procedure; get the authorization code from Google, paste it into the terminal, and hit 'Enter'. In Tahr64, I then had another terminal window, while it was doing something (possibly corroborating that code?), and then the GUI came back, with my Drive folders in the right-hand pane. As you would expect.
All that happens in the 32-bit version is that it immediately returns to the GUI, with nothing showing in the right-hand pane. Upon trying 'Rescan', it pops-up a window telling me no profile has been initiated, and to go back and start again.
I tried this half-a-dozen times, with identical results. I then tried, in succession, Slacko 570, Precise 571, and Slacko 560 (all glibc 2.15). Still no go. Same thing in all of them.
I guess feedback is what you're after, yes? I know it always helps me with packages I produce.
[Tried the 'portable' version, too. Same results.]
Thoughts? Or am I doing summat wrong.....and 'can't see the wood for the trees'..??
(EDIT:- Of course, it's always possible Google won't permit access to your Drive from multiple apps using the same IP address. What d'you reckon?)
My eventual intention is to have the 32-bit version running in as many Pups as possible, sym-linked from my remote 'Data' partition, and all utilising the same, common profile. It works fine for many other apps; no reason it shouldn't work for this.
Mike.
_________________ MY PUPPY PACKAGES | 'Thanks' are always appreciated!
--------------------------------------
 
|
Back to top
|
|
 |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Sat 16 Dec 2017, 06:40 Post subject:
|
|
Hi Mike,
Sure, feedback appreciated, I'd like it to work for everyone on all Linux systems.
As said, I tested earlier only on Tahrpup and Stretchdog, but just now I made a testing round in different OS's
On Slacko, Xenialpup, D-pup Stretch, Linux Mint (full install), (Debian) Wheezy, XenialDog and Raringpup
On all it worked fine for me, except on... Raring
I have no clue, why not on raring, the authorization just doesn't work, tried without using the GUI (just with the 'drive' command), also no go.
When running from terminal on raring, the error messages are:
Trying to initiate new profile dir, authentication fails
Code: | Get https://www.googleapis.com/drive/v2/files/root?alt=json: oauth2: token expired and refresh token is not set: '/' |
Trying to use an already initated profile (I had made already for /mnt/sda5, works fine in all systems except for raring)
Code: | Get https://www.googleapis.com/drive/v2/files/root?alt=json: Post https://accounts.google.com/o/oauth2/token: x509: failed to load system roots and no roots provided: '/' |
Anyone has idea what can be wrong here ?
Quote: | (EDIT:- Of course, it's always possible Google won't permit access to your Drive from multiple apps using the same IP address. What d'you reckon?) |
I think my tests are proving that can't be a problem.
Also I guess that the glibc version has nothing to do with the problem on raring. (but I may be wrong)
Can you test on other (older) puppies maybe ?
EDIT: After some googling, found a fix for raring, ca-certificates missing (well, works for me), in terminal:
Code: | mkdir -p /etc/ssl/certs/
curl -k -o /etc/ssl/certs/ca-certificates.crt https://raw.githubusercontent.com/bagder/ca-bundle/master/ca-bundle.crt |
And try initiating profile again, maybe best to remove first the hidden folder: ".gd"
Fred
Last edited by fredx181 on Sat 16 Dec 2017, 07:18; edited 1 time in total
|
Back to top
|
|
 |
Mike Walsh

Joined: 28 Jun 2014 Posts: 3576 Location: King's Lynn, UK.
|
Posted: Sat 16 Dec 2017, 07:16 Post subject:
|
|
Morning, Fred!
Curiouser and curiouser.
The 32-bit version runs fine in Tahr 6.0.6 (uefi) and Xenialpup 7081. Both of these use the newer urxvt terminal, with which you can visit the Google page for authorization simply by clicking on the link itself. By using this, it appears to set itself up correctly.
Older Pups, using rxvt, seem to be the ones with the problem here. I need to follow your instructions in post #1, and copy'n'paste the address directly into the browser bar.....and for older Pups (on my system at least), this seems to be where the setup process breaks.
I know this is outside the scope of this thread, but is there a way to install the newer version of the terminal in older Pups? It might fix this.....and I prefer the newer version anyway, since appearance is customizable. In rxvt, although I've tried, changes don't seem to 'stick'.
Food for thought, perhaps?
Mike.
_________________ MY PUPPY PACKAGES | 'Thanks' are always appreciated!
--------------------------------------
 
|
Back to top
|
|
 |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Sat 16 Dec 2017, 07:20 Post subject:
|
|
Hi Mike, edited my previous post (found a fix for raring) at the same time you just posted.
Fred
_________________ Dog Linux website
|
Back to top
|
|
 |
Mike Walsh

Joined: 28 Jun 2014 Posts: 3576 Location: King's Lynn, UK.
|
Posted: Sat 16 Dec 2017, 07:25 Post subject:
|
|
Hmm. Yeah. Certificates. Now why didn't I think of that?
Google are, as we all know, almost paranoid about insisting everything be as up-to-date as possible.
Do we have a way to update certificates for Pup.....or might it just be as simple as making sure you use a newer browser? I tend to use Chrome 48 (the final 32-bit version) as default in all my 32-bitzers, although I do have much newer versions of SlimJet and Iron installed in all of them.
What d'you think? Worth trying? Are certificates contained within the browser itself.....or do they get read from some other location?
EDIT:- Just read your update above. I'm going to try copying over the contents of Tahr or Xenial's /etc/ssl/certs to one or two older Pups; I'll get back to you in a little while. Bear with me.
EDIT2:- Nope, they're all symlinks to somewhere else that I can't find..! I'll run your script, and get the (newest?) bundle, and take it from there...
Back soon.
Mike.
_________________ MY PUPPY PACKAGES | 'Thanks' are always appreciated!
--------------------------------------
 
Last edited by Mike Walsh on Sat 16 Dec 2017, 08:51; edited 2 times in total
|
Back to top
|
|
 |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Sat 16 Dec 2017, 07:42 Post subject:
|
|
Mike Walsh wrote: | What d'you think? Worth trying? Are certificates contained within the browser itself.....or do they get read from some other location? |
Don't know much about it but I don't think they are contained in the browser.
On Debian and Ubuntu there's package "ca-certificates" and part of that package installs in /etc/ssl/certs/
And apparently the commands in my earlier post do a similar job.
Fred
_________________ Dog Linux website
|
Back to top
|
|
 |
Mike Walsh

Joined: 28 Jun 2014 Posts: 3576 Location: King's Lynn, UK.
|
Posted: Sat 16 Dec 2017, 08:49 Post subject:
|
|
Hi again, Fred.
We have (wait for it, wait for it)..... Success!!
I ran your curl script in VoxPup (this is greengeek's 'spin' on Upup Raring), and installed the certs package to /etc/ssl/certs. Ran the 'New Profile' script again, and.....it's all working beautifully.
I then moved/symlinked back /root/.gd & /root/.gdriverc to my remote data partition. While I was in Raring, I made up a 'sym-links' .pet for GDrive_gui (basically, this just installs all necessary sym-links to the remote partition, so that Pup sees it as installed locally. Davids45 and I have been experimenting with this in recent days, since we both run a lot of stuff 'remotely' like this, and it speeds up 'installation' when we try out new Pups.)
Re-booted into Slacko 570, installed the sym-links .pet, and.....initially, it wasn't behaving itself. I had a look in /root, and realized that /root/.gd was still there from last night's failed attempt.....so I deleted it, and re-established the sym-link (because a sym-link doesn't 'overwrite' an existing file, does it?) Fired up GDrive_gui again, and.....
Bingo. Working sweetly.
Re-booted into Racy 5.5 this time. I deleted the contents of /etc/ssl/certs, 'cos I know this is all old stuff, and I've been meaning to update it for a while. Installed the sym-links .pet again, and, once again, success.
Working fine in Racy!
So, to re-cap:-
Currently works fine in
Tahr64 6.0.5
Tahr 6.0.6 (uefi)
Xenialpup 7081
Upup Raring
Slacko 570
Racy 5.5
This bodes well for this project, Fred. From all this, I conclude that it should work in pretty much all 5-series Pups, at least.
Once again, excellent work, mate. A very neat addition to Pup's arsenal. Cheers!
Mike.
_________________ MY PUPPY PACKAGES | 'Thanks' are always appreciated!
--------------------------------------
 
|
Back to top
|
|
 |
fredx181

Joined: 11 Dec 2013 Posts: 2892 Location: holland
|
Posted: Sat 16 Dec 2017, 09:07 Post subject:
|
|
Haha.., that's good news, thanks Mike !!
Fred
_________________ Dog Linux website
|
Back to top
|
|
 |
|
Page 1 of 3 [38 Posts] |
Goto page: 1, 2, 3 Next |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|