Session String (#2)
* Update README.md * Update README.md * Update gdriveTools.py
This commit is contained in:
parent
2bf51a3c00
commit
fbd77ae313
|
|
@ -14,7 +14,7 @@ Original Source [Ayanamileechbot](https://gitlab.com/Dank-del/ayanamileechbot)
|
||||||
- Go to the Credentials tab and click Create Credentials -> OAuth Client ID
|
- Go to the Credentials tab and click Create Credentials -> OAuth Client ID
|
||||||
- Choose Desktop and Create.
|
- Choose Desktop and Create.
|
||||||
- Use the download button to download your credentials.
|
- Use the download button to download your credentials.
|
||||||
- Move that file to the root of mirror-bot, and rename it to credentials.json
|
- Move that file to the root of slam-mirrorbot, and rename it to credentials.json
|
||||||
- Visit [Google API page](https://console.developers.google.com/apis/library)
|
- Visit [Google API page](https://console.developers.google.com/apis/library)
|
||||||
- Search for Drive and enable it if it is disabled
|
- Search for Drive and enable it if it is disabled
|
||||||
- Finally, run the script to generate token file (token.pickle) for Google Drive:
|
- Finally, run the script to generate token file (token.pickle) for Google Drive:
|
||||||
|
|
@ -22,6 +22,13 @@ Original Source [Ayanamileechbot](https://gitlab.com/Dank-del/ayanamileechbot)
|
||||||
pip install google-api-python-client google-auth-httplib2 google-auth-oauthlib
|
pip install google-api-python-client google-auth-httplib2 google-auth-oauthlib
|
||||||
python3 generate_drive_token.py
|
python3 generate_drive_token.py
|
||||||
```
|
```
|
||||||
|
## Session String
|
||||||
|
Generate session string by running:
|
||||||
|
```
|
||||||
|
git clone https://github.com/breakdowns/slam-mirrorbot
|
||||||
|
cd slam-mirrorbot
|
||||||
|
python3 generate_string_session.py
|
||||||
|
```
|
||||||
|
|
||||||
## Deploying on Heroku
|
## Deploying on Heroku
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -93,7 +93,7 @@ class GoogleDriveHelper:
|
||||||
resumable=False)
|
resumable=False)
|
||||||
file_metadata = {
|
file_metadata = {
|
||||||
'name': file_name,
|
'name': file_name,
|
||||||
'description': 'mirror',
|
'description': 'Uploaded using Slam Mirror Bot',
|
||||||
'mimeType': mime_type,
|
'mimeType': mime_type,
|
||||||
}
|
}
|
||||||
if parent_id is not None:
|
if parent_id is not None:
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue