20022025b

This commit is contained in:
Nanten
2025-02-20 18:59:53 +09:00
parent dd132aabbe
commit ae791a07ab
4 changed files with 199 additions and 4 deletions
+34 -3
View File
@@ -1,7 +1,13 @@
# typora-img-uploader-r2
# typora-img-uploader
## Upload to R2
Upload images to R2 using Typora.
```bash
pip install python-dotenv boto3
```
``` bash:.env
.env
@@ -12,7 +18,32 @@ R2_SECRET_ACCESS_KEY = 'securet access key'
R2_CUSTOM_URL = 'https://custom.domain/'
```
## Usage
### Usage
```python
upload.py --image-path <image path>
upload_r2.py --images-path <image path>
```
## Upload to DropBox
Upload images to Dropbox.
``` bash
pip install dropbox python-dotenv
```
``` bash:.env
.env
DROPBOX_APP_KEY=your_app_key
DROPBOX_APP_SECRET=your_app_secret
DROPBOX_REFRESH_TOKEN=your_refresh_token
```
Required permissions:
- files.content.write
- files.content.read
- sharing.write
### Usage
```python
upload_dropbox.py --images-path <image path>
```