Skip to content

Frequently Asked Questions

Levi edited this page Nov 26, 2022 · 17 revisions

What's this bot about?

This is a multipurpose Telegram bot written in Python for Google Drive

Does this bot support recursive search?

Yes

Does this bot search data with Folder ID?

No

How to remove commit id from a gist raw link?

For example here's a gist raw link from which we will remove the commit id

https://gist.githubusercontent.com/l3v11/7o1eed3691f87f7dcah11af1ld4bdeb1/raw/92b7a460031d5v171a546ccad274f3e7f44fka46/config.env

Now focus on the link, there's an alphanumeric code exists after raw and before config.env. That's the commit id. Now remove that code along with a slash (/). So the final link will be like this

https://gist.githubusercontent.com/l3v11/7o1eed3691f87f7dcah11af1ld4bdeb1/raw/config.env

How to add SAs into Shared Drive

  • Mount the accounts folder

    cd accounts
    

    Grab email addresses form all SAs and put them into the emails.txt file

  • For Windows using PowerShell

    $emails = Get-ChildItem .\**.json |Get-Content -Raw |ConvertFrom-Json |Select -ExpandProperty client_email >>emails.txt
    
  • For Linux / macOS

    grep -oPh '"client_email": "\K[^"]+' *.json > emails.txt
    
  • Unmount the accounts folder

    cd ..
    
  • Now add emails from emails.txt to a Google Group, then add that Google Group to your Shared Drive and promote it to Manager. After that delete the email.txt file from accounts folder.

Getting this error - 'python3' is not recognized as an internal or external command, operable program or batch file.

Use python or py instead of python3