yaichi-tg 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- yaichi_tg-0.1.0/AUTHORS.rst +13 -0
- yaichi_tg-0.1.0/CONTRIBUTING.rst +114 -0
- yaichi_tg-0.1.0/HISTORY.rst +171 -0
- yaichi_tg-0.1.0/LICENSE +11 -0
- yaichi_tg-0.1.0/MANIFEST.in +16 -0
- yaichi_tg-0.1.0/PKG-INFO +162 -0
- yaichi_tg-0.1.0/README.rst +117 -0
- yaichi_tg-0.1.0/docs/Makefile +198 -0
- yaichi_tg-0.1.0/docs/_static/logo.png +0 -0
- yaichi_tg-0.1.0/docs/authors.rst +1 -0
- yaichi_tg-0.1.0/docs/benchmark_2.0_GiB.png +0 -0
- yaichi_tg-0.1.0/docs/benchmark_2.0_GiB.rst +19 -0
- yaichi_tg-0.1.0/docs/benchmark_20.0_MiB.png +0 -0
- yaichi_tg-0.1.0/docs/benchmark_20.0_MiB.rst +19 -0
- yaichi_tg-0.1.0/docs/benchmark_200.0_MiB.png +0 -0
- yaichi_tg-0.1.0/docs/benchmark_200.0_MiB.rst +19 -0
- yaichi_tg-0.1.0/docs/benchmark_512.0_KiB.png +0 -0
- yaichi_tg-0.1.0/docs/benchmark_512.0_KiB.rst +19 -0
- yaichi_tg-0.1.0/docs/benchmark_full.rst +304 -0
- yaichi_tg-0.1.0/docs/caption_format.rst +192 -0
- yaichi_tg-0.1.0/docs/conf.py +312 -0
- yaichi_tg-0.1.0/docs/contributing.rst +1 -0
- yaichi_tg-0.1.0/docs/history.rst +1 -0
- yaichi_tg-0.1.0/docs/index.rst +34 -0
- yaichi_tg-0.1.0/docs/installation.rst +63 -0
- yaichi_tg-0.1.0/docs/readme.rst +1 -0
- yaichi_tg-0.1.0/docs/supported_file_types.rst +713 -0
- yaichi_tg-0.1.0/docs/troubleshooting.rst +85 -0
- yaichi_tg-0.1.0/docs/upload_benchmark.rst +135 -0
- yaichi_tg-0.1.0/docs/usage.rst +203 -0
- yaichi_tg-0.1.0/requirements.txt +8 -0
- yaichi_tg-0.1.0/setup.cfg +25 -0
- yaichi_tg-0.1.0/setup.py +130 -0
- yaichi_tg-0.1.0/tests/__init__.py +0 -0
- yaichi_tg-0.1.0/tests/_compat.py +4 -0
- yaichi_tg-0.1.0/tests/test_caption_formatter.py +415 -0
- yaichi_tg-0.1.0/tests/test_cli.py +48 -0
- yaichi_tg-0.1.0/tests/test_client/__init__.py +0 -0
- yaichi_tg-0.1.0/tests/test_client/test_progress_bar.py +20 -0
- yaichi_tg-0.1.0/tests/test_client/test_tg_download_client.py +84 -0
- yaichi_tg-0.1.0/tests/test_client/test_tg_manager_client.py +123 -0
- yaichi_tg-0.1.0/tests/test_client/test_tg_upload_client.py +171 -0
- yaichi_tg-0.1.0/tests/test_config.py +22 -0
- yaichi_tg-0.1.0/tests/test_download_files.py +213 -0
- yaichi_tg-0.1.0/tests/test_exceptions.py +35 -0
- yaichi_tg-0.1.0/tests/test_files.py +101 -0
- yaichi_tg-0.1.0/tests/test_management.py +61 -0
- yaichi_tg-0.1.0/tests/test_upload_files.py +30 -0
- yaichi_tg-0.1.0/tests/test_utils.py +38 -0
- yaichi_tg-0.1.0/tests/test_video.py +37 -0
- yaichi_tg-0.1.0/tg_up/__init__.py +7 -0
- yaichi_tg-0.1.0/tg_up/_compat.py +67 -0
- yaichi_tg-0.1.0/tg_up/caption_formatter.py +356 -0
- yaichi_tg-0.1.0/tg_up/cli.py +158 -0
- yaichi_tg-0.1.0/tg_up/client/__init__.py +4 -0
- yaichi_tg-0.1.0/tg_up/client/progress_bar.py +16 -0
- yaichi_tg-0.1.0/tg_up/client/tg_download_client.py +133 -0
- yaichi_tg-0.1.0/tg_up/client/tg_manager_client.py +129 -0
- yaichi_tg-0.1.0/tg_up/client/tg_upload_client.py +405 -0
- yaichi_tg-0.1.0/tg_up/config.py +24 -0
- yaichi_tg-0.1.0/tg_up/download_files.py +210 -0
- yaichi_tg-0.1.0/tg_up/exceptions.py +76 -0
- yaichi_tg-0.1.0/tg_up/management.py +257 -0
- yaichi_tg-0.1.0/tg_up/upload_files.py +254 -0
- yaichi_tg-0.1.0/tg_up/utils.py +80 -0
- yaichi_tg-0.1.0/tg_up/video.py +69 -0
- yaichi_tg-0.1.0/yaichi_tg.egg-info/PKG-INFO +162 -0
- yaichi_tg-0.1.0/yaichi_tg.egg-info/SOURCES.txt +72 -0
- yaichi_tg-0.1.0/yaichi_tg.egg-info/dependency_links.txt +1 -0
- yaichi_tg-0.1.0/yaichi_tg.egg-info/entry_points.txt +3 -0
- yaichi_tg-0.1.0/yaichi_tg.egg-info/not-zip-safe +1 -0
- yaichi_tg-0.1.0/yaichi_tg.egg-info/requires.txt +10 -0
- yaichi_tg-0.1.0/yaichi_tg.egg-info/top_level.txt +2 -0
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
.. highlight:: shell
|
|
2
|
+
|
|
3
|
+
============
|
|
4
|
+
Contributing
|
|
5
|
+
============
|
|
6
|
+
|
|
7
|
+
Contributions are welcome, and they are greatly appreciated! Every
|
|
8
|
+
little bit helps, and credit will always be given.
|
|
9
|
+
|
|
10
|
+
You can contribute in many ways:
|
|
11
|
+
|
|
12
|
+
Types of Contributions
|
|
13
|
+
----------------------
|
|
14
|
+
|
|
15
|
+
Report Bugs
|
|
16
|
+
~~~~~~~~~~~
|
|
17
|
+
|
|
18
|
+
Report bugs at https://github.com/yaichi-jk/tg-up/issues.
|
|
19
|
+
|
|
20
|
+
If you are reporting a bug, please include:
|
|
21
|
+
|
|
22
|
+
* Your operating system name and version.
|
|
23
|
+
* Any details about your local setup that might be helpful in troubleshooting.
|
|
24
|
+
* Detailed steps to reproduce the bug.
|
|
25
|
+
|
|
26
|
+
Fix Bugs
|
|
27
|
+
~~~~~~~~
|
|
28
|
+
|
|
29
|
+
Look through the GitHub issues for bugs. Anything tagged with "bug"
|
|
30
|
+
and "help wanted" is open to whoever wants to implement it.
|
|
31
|
+
|
|
32
|
+
Implement Features
|
|
33
|
+
~~~~~~~~~~~~~~~~~~
|
|
34
|
+
|
|
35
|
+
Look through the GitHub issues for features. Anything tagged with "enhancement"
|
|
36
|
+
and "help wanted" is open to whoever wants to implement it.
|
|
37
|
+
|
|
38
|
+
Write Documentation
|
|
39
|
+
~~~~~~~~~~~~~~~~~~~
|
|
40
|
+
|
|
41
|
+
tg-up could always use more documentation, whether as part of the
|
|
42
|
+
official tg-up docs, in docstrings, or even on the web in blog posts,
|
|
43
|
+
articles, and such.
|
|
44
|
+
|
|
45
|
+
Submit Feedback
|
|
46
|
+
~~~~~~~~~~~~~~~
|
|
47
|
+
|
|
48
|
+
The best way to send feedback is to file an issue at https://github.com/yaichi-jk/tg-up/issues.
|
|
49
|
+
|
|
50
|
+
If you are proposing a feature:
|
|
51
|
+
|
|
52
|
+
* Explain in detail how it would work.
|
|
53
|
+
* Keep the scope as narrow as possible, to make it easier to implement.
|
|
54
|
+
* Remember that this is a volunteer-driven project, and that contributions
|
|
55
|
+
are welcome :)
|
|
56
|
+
|
|
57
|
+
Get Started!
|
|
58
|
+
------------
|
|
59
|
+
|
|
60
|
+
Ready to contribute? Here's how to set up `tg-up` for local development.
|
|
61
|
+
|
|
62
|
+
1. Fork the `tg-up` repo on GitHub.
|
|
63
|
+
2. Clone your fork locally::
|
|
64
|
+
|
|
65
|
+
$ git clone git@github.com:your_name_here/tg-up.git
|
|
66
|
+
|
|
67
|
+
3. Install your local copy into a virtualenv. Assuming you have virtualenvwrapper installed, this is how you set up your fork for local development::
|
|
68
|
+
|
|
69
|
+
$ mkvirtualenv tg-up
|
|
70
|
+
$ cd tg-up/
|
|
71
|
+
$ python setup.py develop
|
|
72
|
+
|
|
73
|
+
4. Create a branch for local development::
|
|
74
|
+
|
|
75
|
+
$ git checkout -b name-of-your-bugfix-or-feature
|
|
76
|
+
|
|
77
|
+
Now you can make your changes locally.
|
|
78
|
+
|
|
79
|
+
5. When you're done making changes, check that your changes pass flake8 and the tests, including testing other Python versions with tox::
|
|
80
|
+
|
|
81
|
+
$ flake8 tg_up tests
|
|
82
|
+
$ python setup.py test or py.test
|
|
83
|
+
$ tox
|
|
84
|
+
|
|
85
|
+
To get flake8 and tox, just pip install them into your virtualenv.
|
|
86
|
+
|
|
87
|
+
6. Commit your changes and push your branch to GitHub::
|
|
88
|
+
|
|
89
|
+
$ git add .
|
|
90
|
+
$ git commit -m "Your detailed description of your changes."
|
|
91
|
+
$ git push origin name-of-your-bugfix-or-feature
|
|
92
|
+
|
|
93
|
+
7. Submit a pull request through the GitHub website.
|
|
94
|
+
|
|
95
|
+
Pull Request Guidelines
|
|
96
|
+
-----------------------
|
|
97
|
+
|
|
98
|
+
Before you submit a pull request, check that it meets these guidelines:
|
|
99
|
+
|
|
100
|
+
1. The pull request should include tests.
|
|
101
|
+
2. If the pull request adds functionality, the docs should be updated. Put
|
|
102
|
+
your new functionality into a function with a docstring, and add the
|
|
103
|
+
feature to the list in README.rst.
|
|
104
|
+
3. The pull request should work for Python 2.6, 2.7, 3.3, 3.4 and 3.5, and for PyPy. Check
|
|
105
|
+
https://github.com/yaichi-jk/tg-up/actions
|
|
106
|
+
and make sure that the tests pass for all supported Python versions.
|
|
107
|
+
|
|
108
|
+
Tips
|
|
109
|
+
----
|
|
110
|
+
|
|
111
|
+
To run a subset of tests::
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
$ python -m unittest tests.test_tg_up
|
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
=======
|
|
2
|
+
History
|
|
3
|
+
=======
|
|
4
|
+
|
|
5
|
+
0.7.1 (2023-08-04)
|
|
6
|
+
------------------
|
|
7
|
+
|
|
8
|
+
* Issue #215: "TypeError: __init__() got an unexpected keyword argument 'reply_to_msg_id'" in command - "tg-up --directories "recursive" --album"
|
|
9
|
+
|
|
10
|
+
0.7.0 (2023-06-29)
|
|
11
|
+
------------------
|
|
12
|
+
|
|
13
|
+
* Issue #140: Speed up upload & download speed
|
|
14
|
+
* Issue #115: Add support for variables in the caption argument
|
|
15
|
+
* Issue #159: Telegram premium
|
|
16
|
+
* Issue #176: Bug uploading .flv files
|
|
17
|
+
* Issue #198: Improve README
|
|
18
|
+
|
|
19
|
+
0.6.1 (2023-06-17)
|
|
20
|
+
------------------
|
|
21
|
+
|
|
22
|
+
* Issue #197: if to.lstrip("-+").isdigit(): AttributeError: 'int' object has no attribute 'lstrip'
|
|
23
|
+
|
|
24
|
+
0.6.0 (2023-06-15)
|
|
25
|
+
------------------
|
|
26
|
+
|
|
27
|
+
* Issue #99: Combine split files when downloading
|
|
28
|
+
* Issue #118: Feature Request - Choose channel by ID
|
|
29
|
+
* Issue #113: Numbered files are uploaded in weird order
|
|
30
|
+
* Issue #111: telethon.errors.rpcerrorlist.FloodWaitError: A wait of 819 seconds is required (caused by CheckChatInviteRequest)
|
|
31
|
+
* Issue #108: RPCError 400: INPUT_GZIP_INVALID
|
|
32
|
+
* Issue #193: Remove Python 3.6 support
|
|
33
|
+
* Issue #194: Python 3.11 support.
|
|
34
|
+
|
|
35
|
+
0.5.1 (2022-05-18)
|
|
36
|
+
------------------
|
|
37
|
+
|
|
38
|
+
* Issue #154: Python classifiers for Python 3.1.0
|
|
39
|
+
* Issue #151: Error while uploading files
|
|
40
|
+
* Issue #121: Thumbnail gets auto deleted
|
|
41
|
+
|
|
42
|
+
0.5.0 (2022-02-27)
|
|
43
|
+
------------------
|
|
44
|
+
|
|
45
|
+
* Issue #34: Selective downloading option
|
|
46
|
+
* Issue #131: Selective uploading option
|
|
47
|
+
* Issue #61: Upload as album
|
|
48
|
+
* Issue #66: How to re-verify when I type in wrong app-id
|
|
49
|
+
* Issue #69: Create Dockerfile
|
|
50
|
+
* Issue #82: Error in files with corrupted or unsupported video mimetype
|
|
51
|
+
* Issue #83: Raise error when file is empty
|
|
52
|
+
* Issue #84: Catch ChatWriteForbiddenError
|
|
53
|
+
* Issue #94: Unclosed file ~/.config/tg-up.json wb
|
|
54
|
+
* Issue #110: Error uploading corrupt or unsupported video file
|
|
55
|
+
* Issue #129: Caption chars length
|
|
56
|
+
* Issue #149: Support Python 3.10
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
0.4.0 (2020-12-31)
|
|
60
|
+
------------------
|
|
61
|
+
|
|
62
|
+
* Issue #79: Python 3.9 support
|
|
63
|
+
* Issue #74: Help on dependency issues
|
|
64
|
+
* Issue #70: Document streamable file types
|
|
65
|
+
* Issue #68: Silence hachoir warnings ([warn] [/file[0]/uid] ...)
|
|
66
|
+
* Issue #65: Custom Thumbnail For the Files getting Uploaded
|
|
67
|
+
* Issue #43: Write tests
|
|
68
|
+
* Issue #40: Not using system HTTP Proxy
|
|
69
|
+
* Issue #38: Upload to Pypi using Github Actions
|
|
70
|
+
* Issue #36: Database is locked
|
|
71
|
+
* Issue #35: Document send files to a chat_id
|
|
72
|
+
* Issue #13: Change session directory enhancement
|
|
73
|
+
* Issue #11: Change session directory enhancement
|
|
74
|
+
* Issue #3: Split large files (> 2GB)
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
0.3.4 (2020-10-06)
|
|
78
|
+
------------------
|
|
79
|
+
|
|
80
|
+
* Issue #59: Stream upload videos
|
|
81
|
+
|
|
82
|
+
0.3.3 (2020-09-11)
|
|
83
|
+
------------------
|
|
84
|
+
|
|
85
|
+
* Pull request #54: Finalizing ProgressBar
|
|
86
|
+
* Pull request #55: Verifying document size returned by Telegram
|
|
87
|
+
* Pull request #56: Extra convenience options for no caption and no thumbnail
|
|
88
|
+
|
|
89
|
+
0.3.3 (2020-09-11)
|
|
90
|
+
------------------
|
|
91
|
+
|
|
92
|
+
* Pull request #54: Finalizing ProgressBar
|
|
93
|
+
* Pull request #55: Verifying document size returned by Telegram
|
|
94
|
+
* Pull request #56: Extra convenience options for no caption and no thumbnail
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
0.3.2 (2020-07-15)
|
|
98
|
+
------------------
|
|
99
|
+
|
|
100
|
+
* Issue #44: Caption problem
|
|
101
|
+
|
|
102
|
+
0.3.1 (2020-05-11)
|
|
103
|
+
------------------
|
|
104
|
+
|
|
105
|
+
* Issue #37: Directories recursive does not work
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
0.3.0 (2020-05-07)
|
|
109
|
+
------------------
|
|
110
|
+
|
|
111
|
+
* Issue #2: Upload directories
|
|
112
|
+
* Issue #30: Check available disk space in download file
|
|
113
|
+
* Issue #33: edit file name
|
|
114
|
+
* Issue #24: How to install and use in windows?
|
|
115
|
+
* Issue #29: Option to forward uploaded file enhancement
|
|
116
|
+
* Issue #20: Can't upload video as Document.
|
|
117
|
+
* Issue #12: Docs
|
|
118
|
+
|
|
119
|
+
0.2.1 (2019-07-30)
|
|
120
|
+
------------------
|
|
121
|
+
|
|
122
|
+
* Issue #26: Installation Error - hachoir3
|
|
123
|
+
|
|
124
|
+
0.2.0 (2019-00-00)
|
|
125
|
+
------------------
|
|
126
|
+
|
|
127
|
+
* Issue #10: Update docs and validation: mobile phone is required
|
|
128
|
+
* Issue #23: Create ~/.config directory if not exists
|
|
129
|
+
* Issue #15: Getting file_id of the uploaded file
|
|
130
|
+
* Issue #21: Windows support for videos
|
|
131
|
+
* Issue #22: Download files
|
|
132
|
+
|
|
133
|
+
0.1.10 (2019-03-22)
|
|
134
|
+
-------------------
|
|
135
|
+
|
|
136
|
+
* Issue #19: uploading video files with delay
|
|
137
|
+
|
|
138
|
+
0.1.9 (2019-03-15)
|
|
139
|
+
------------------
|
|
140
|
+
|
|
141
|
+
* Fixed setup: Included requirements.txt to MANIFEST.in.
|
|
142
|
+
|
|
143
|
+
0.1.8 (2019-03-08)
|
|
144
|
+
------------------
|
|
145
|
+
|
|
146
|
+
* Setup.py requirements only supports python3.
|
|
147
|
+
|
|
148
|
+
0.1.7 (2019-03-08)
|
|
149
|
+
------------------
|
|
150
|
+
|
|
151
|
+
* Support MKV videos
|
|
152
|
+
|
|
153
|
+
0.1.6 (2018-07-22)
|
|
154
|
+
------------------
|
|
155
|
+
|
|
156
|
+
* Update to Telethon 1.0
|
|
157
|
+
|
|
158
|
+
0.1.4 (2018-04-16)
|
|
159
|
+
------------------
|
|
160
|
+
|
|
161
|
+
* Pip 10.0 support
|
|
162
|
+
|
|
163
|
+
0.1.2 (2018-03-29)
|
|
164
|
+
------------------
|
|
165
|
+
|
|
166
|
+
* Best upload performance
|
|
167
|
+
|
|
168
|
+
0.1.0 (2018-03-26)
|
|
169
|
+
------------------
|
|
170
|
+
|
|
171
|
+
* First release on PyPI.
|
yaichi_tg-0.1.0/LICENSE
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
|
|
2
|
+
MIT License
|
|
3
|
+
|
|
4
|
+
Copyright (c) 2026, yaichi-jk
|
|
5
|
+
|
|
6
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
7
|
+
|
|
8
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
9
|
+
|
|
10
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
11
|
+
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
include AUTHORS.rst
|
|
2
|
+
include CONTRIBUTING.rst
|
|
3
|
+
include HISTORY.rst
|
|
4
|
+
include LICENSE
|
|
5
|
+
include README.rst
|
|
6
|
+
include common-requirements.txt
|
|
7
|
+
include py2-requirements.txt
|
|
8
|
+
include py3-requirements.txt
|
|
9
|
+
include requirements.txt
|
|
10
|
+
|
|
11
|
+
recursive-include tests *
|
|
12
|
+
recursive-exclude * __pycache__
|
|
13
|
+
recursive-exclude * *.py[co]
|
|
14
|
+
recursive-exclude * *.session
|
|
15
|
+
|
|
16
|
+
recursive-include docs *.rst conf.py Makefile make.bat *.jpg *.png *.gif
|
yaichi_tg-0.1.0/PKG-INFO
ADDED
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: yaichi-tg
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Upload (and download) files to Telegram up to 4 GiB using your account.
|
|
5
|
+
Home-page: https://github.com/yaichi-jk/tg-up/
|
|
6
|
+
Download-URL: https://github.com/yaichi-jk/tg-up/archive/main.zip
|
|
7
|
+
Author: yaichi-jk
|
|
8
|
+
Author-email:
|
|
9
|
+
Keywords: tg-up,telegram,upload,video,tg-dw
|
|
10
|
+
Platform: linux
|
|
11
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
12
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
13
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
14
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
18
|
+
Classifier: Operating System :: POSIX
|
|
19
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
20
|
+
Classifier: Natural Language :: English
|
|
21
|
+
Classifier: Development Status :: 4 - Beta
|
|
22
|
+
Provides: tests
|
|
23
|
+
Provides: tg_up
|
|
24
|
+
License-File: LICENSE
|
|
25
|
+
License-File: AUTHORS.rst
|
|
26
|
+
Requires-Dist: telethon
|
|
27
|
+
Requires-Dist: click>=6.0
|
|
28
|
+
Requires-Dist: cryptg
|
|
29
|
+
Requires-Dist: hachoir
|
|
30
|
+
Requires-Dist: scandir; python_version < "3.6"
|
|
31
|
+
Requires-Dist: prompt_toolkit
|
|
32
|
+
Requires-Dist: pysocks
|
|
33
|
+
Requires-Dist: more-itertools
|
|
34
|
+
Dynamic: author
|
|
35
|
+
Dynamic: classifier
|
|
36
|
+
Dynamic: description
|
|
37
|
+
Dynamic: download-url
|
|
38
|
+
Dynamic: home-page
|
|
39
|
+
Dynamic: keywords
|
|
40
|
+
Dynamic: license-file
|
|
41
|
+
Dynamic: platform
|
|
42
|
+
Dynamic: provides
|
|
43
|
+
Dynamic: requires-dist
|
|
44
|
+
Dynamic: summary
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
#######
|
|
48
|
+
tg-up
|
|
49
|
+
#######
|
|
50
|
+
Upload and download files to Telegram up to **4 GiB** (2 GiB for free users) using your personal account. Turn Telegram into your personal โ cloud!
|
|
51
|
+
|
|
52
|
+
To **install ๐ง tg-up**, run this command in your terminal:
|
|
53
|
+
|
|
54
|
+
.. code-block:: console
|
|
55
|
+
|
|
56
|
+
$ pip install tg-up
|
|
57
|
+
|
|
58
|
+
Or from source:
|
|
59
|
+
|
|
60
|
+
.. code-block:: console
|
|
61
|
+
|
|
62
|
+
$ pip install -e <path-to-repo>
|
|
63
|
+
|
|
64
|
+
๐ **Python 3.7-3.13** supported.
|
|
65
|
+
|
|
66
|
+
โ Usage
|
|
67
|
+
========
|
|
68
|
+
To use this program you need a Telegram account and your **App api_id & api_hash** (get it in
|
|
69
|
+
`my.telegram.org <https://my.telegram.org/>`_). The first time you use tg-up it requests your
|
|
70
|
+
๐ฑ **telephone**, **api_id** and **api_hash**. Bot tokens cannot be used (bot uploads are limited to 50MB).
|
|
71
|
+
|
|
72
|
+
To **send โฌ๏ธ files** (default: saved messages):
|
|
73
|
+
|
|
74
|
+
.. code-block:: console
|
|
75
|
+
|
|
76
|
+
$ tg-up file1.mp4 file2.mkv
|
|
77
|
+
|
|
78
|
+
To **reply to a specific message**:
|
|
79
|
+
|
|
80
|
+
.. code-block:: console
|
|
81
|
+
|
|
82
|
+
$ tg-up video.mp4 --to @chat --reply-to 12345
|
|
83
|
+
|
|
84
|
+
You can **download โคต๏ธ files** from your saved messages (default) or from a channel:
|
|
85
|
+
|
|
86
|
+
.. code-block:: console
|
|
87
|
+
|
|
88
|
+
$ tg-dw
|
|
89
|
+
|
|
90
|
+
Interactive mode
|
|
91
|
+
----------------
|
|
92
|
+
The **interactive option** (``--interactive``) allows you to choose the dialog and the files with a **terminal ๐ช wizard**:
|
|
93
|
+
|
|
94
|
+
.. code-block:: console
|
|
95
|
+
|
|
96
|
+
$ tg-up --interactive # Interactive upload
|
|
97
|
+
$ tg-dw --interactive # Interactive download
|
|
98
|
+
|
|
99
|
+
Set group or chat
|
|
100
|
+
-----------------
|
|
101
|
+
For upload, use ``--to <entity>``:
|
|
102
|
+
|
|
103
|
+
.. code-block::
|
|
104
|
+
|
|
105
|
+
$ tg-up --to @channel video.mkv
|
|
106
|
+
|
|
107
|
+
For download, use ``--from <entity>``:
|
|
108
|
+
|
|
109
|
+
.. code-block::
|
|
110
|
+
|
|
111
|
+
$ tg-dw --from username
|
|
112
|
+
|
|
113
|
+
Reply to a message
|
|
114
|
+
------------------
|
|
115
|
+
You can reply to a specific message ID with ``--reply-to``:
|
|
116
|
+
|
|
117
|
+
.. code-block::
|
|
118
|
+
|
|
119
|
+
$ tg-up file.mp4 --to @chat --reply-to 42
|
|
120
|
+
|
|
121
|
+
Split & join files
|
|
122
|
+
------------------
|
|
123
|
+
Enable โ **split mode** for large files:
|
|
124
|
+
|
|
125
|
+
.. code-block:: console
|
|
126
|
+
|
|
127
|
+
$ tg-up --large-files split large-video.mkv
|
|
128
|
+
|
|
129
|
+
Rejoin on download:
|
|
130
|
+
|
|
131
|
+
.. code-block:: console
|
|
132
|
+
|
|
133
|
+
$ tg-dw --split-files join
|
|
134
|
+
|
|
135
|
+
Delete on success
|
|
136
|
+
-----------------
|
|
137
|
+
``--delete-on-success`` deletes the Telegram message after downloading / the local file after uploading.
|
|
138
|
+
|
|
139
|
+
Configuration
|
|
140
|
+
-------------
|
|
141
|
+
Credentials saved in ``~/.config/tg-up.json`` and ``~/.config/tg-up.session``.
|
|
142
|
+
You can copy these ๐ files to authenticate on more machines.
|
|
143
|
+
|
|
144
|
+
More options
|
|
145
|
+
------------
|
|
146
|
+
Customize thumbnail (``--thumbnail-file``), caption with variables (``--caption``), proxy (``--proxy`` / ``TG_UP_PROXY``),
|
|
147
|
+
parallel upload blocks (``TG_UP_PARALLEL_UPLOAD_BLOCKS``), and more.
|
|
148
|
+
|
|
149
|
+
๐ก Features
|
|
150
|
+
===========
|
|
151
|
+
|
|
152
|
+
* **Upload** and **download** multiples files (up to 4 GiB).
|
|
153
|
+
* **Interactive** mode.
|
|
154
|
+
* **Reply to** a specific message (``--reply-to``).
|
|
155
|
+
* Add video **thumbs**.
|
|
156
|
+
* **Split** and **join** large files.
|
|
157
|
+
* **Delete** local or remote file on success.
|
|
158
|
+
* Use **variables** in the **caption** message.
|
|
159
|
+
* **Proxy** support (http, socks4/5, mtproxy).
|
|
160
|
+
* **Parallel upload** blocks (env: ``TG_UP_PARALLEL_UPLOAD_BLOCKS``).
|
|
161
|
+
|
|
162
|
+
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
|
|
2
|
+
#######
|
|
3
|
+
tg-up
|
|
4
|
+
#######
|
|
5
|
+
Upload and download files to Telegram up to **4 GiB** (2 GiB for free users) using your personal account. Turn Telegram into your personal โ cloud!
|
|
6
|
+
|
|
7
|
+
To **install ๐ง tg-up**, run this command in your terminal:
|
|
8
|
+
|
|
9
|
+
.. code-block:: console
|
|
10
|
+
|
|
11
|
+
$ pip install tg-up
|
|
12
|
+
|
|
13
|
+
Or from source:
|
|
14
|
+
|
|
15
|
+
.. code-block:: console
|
|
16
|
+
|
|
17
|
+
$ pip install -e <path-to-repo>
|
|
18
|
+
|
|
19
|
+
๐ **Python 3.7-3.13** supported.
|
|
20
|
+
|
|
21
|
+
โ Usage
|
|
22
|
+
========
|
|
23
|
+
To use this program you need a Telegram account and your **App api_id & api_hash** (get it in
|
|
24
|
+
`my.telegram.org <https://my.telegram.org/>`_). The first time you use tg-up it requests your
|
|
25
|
+
๐ฑ **telephone**, **api_id** and **api_hash**. Bot tokens cannot be used (bot uploads are limited to 50MB).
|
|
26
|
+
|
|
27
|
+
To **send โฌ๏ธ files** (default: saved messages):
|
|
28
|
+
|
|
29
|
+
.. code-block:: console
|
|
30
|
+
|
|
31
|
+
$ tg-up file1.mp4 file2.mkv
|
|
32
|
+
|
|
33
|
+
To **reply to a specific message**:
|
|
34
|
+
|
|
35
|
+
.. code-block:: console
|
|
36
|
+
|
|
37
|
+
$ tg-up video.mp4 --to @chat --reply-to 12345
|
|
38
|
+
|
|
39
|
+
You can **download โคต๏ธ files** from your saved messages (default) or from a channel:
|
|
40
|
+
|
|
41
|
+
.. code-block:: console
|
|
42
|
+
|
|
43
|
+
$ tg-dw
|
|
44
|
+
|
|
45
|
+
Interactive mode
|
|
46
|
+
----------------
|
|
47
|
+
The **interactive option** (``--interactive``) allows you to choose the dialog and the files with a **terminal ๐ช wizard**:
|
|
48
|
+
|
|
49
|
+
.. code-block:: console
|
|
50
|
+
|
|
51
|
+
$ tg-up --interactive # Interactive upload
|
|
52
|
+
$ tg-dw --interactive # Interactive download
|
|
53
|
+
|
|
54
|
+
Set group or chat
|
|
55
|
+
-----------------
|
|
56
|
+
For upload, use ``--to <entity>``:
|
|
57
|
+
|
|
58
|
+
.. code-block::
|
|
59
|
+
|
|
60
|
+
$ tg-up --to @channel video.mkv
|
|
61
|
+
|
|
62
|
+
For download, use ``--from <entity>``:
|
|
63
|
+
|
|
64
|
+
.. code-block::
|
|
65
|
+
|
|
66
|
+
$ tg-dw --from username
|
|
67
|
+
|
|
68
|
+
Reply to a message
|
|
69
|
+
------------------
|
|
70
|
+
You can reply to a specific message ID with ``--reply-to``:
|
|
71
|
+
|
|
72
|
+
.. code-block::
|
|
73
|
+
|
|
74
|
+
$ tg-up file.mp4 --to @chat --reply-to 42
|
|
75
|
+
|
|
76
|
+
Split & join files
|
|
77
|
+
------------------
|
|
78
|
+
Enable โ **split mode** for large files:
|
|
79
|
+
|
|
80
|
+
.. code-block:: console
|
|
81
|
+
|
|
82
|
+
$ tg-up --large-files split large-video.mkv
|
|
83
|
+
|
|
84
|
+
Rejoin on download:
|
|
85
|
+
|
|
86
|
+
.. code-block:: console
|
|
87
|
+
|
|
88
|
+
$ tg-dw --split-files join
|
|
89
|
+
|
|
90
|
+
Delete on success
|
|
91
|
+
-----------------
|
|
92
|
+
``--delete-on-success`` deletes the Telegram message after downloading / the local file after uploading.
|
|
93
|
+
|
|
94
|
+
Configuration
|
|
95
|
+
-------------
|
|
96
|
+
Credentials saved in ``~/.config/tg-up.json`` and ``~/.config/tg-up.session``.
|
|
97
|
+
You can copy these ๐ files to authenticate on more machines.
|
|
98
|
+
|
|
99
|
+
More options
|
|
100
|
+
------------
|
|
101
|
+
Customize thumbnail (``--thumbnail-file``), caption with variables (``--caption``), proxy (``--proxy`` / ``TG_UP_PROXY``),
|
|
102
|
+
parallel upload blocks (``TG_UP_PARALLEL_UPLOAD_BLOCKS``), and more.
|
|
103
|
+
|
|
104
|
+
๐ก Features
|
|
105
|
+
===========
|
|
106
|
+
|
|
107
|
+
* **Upload** and **download** multiples files (up to 4 GiB).
|
|
108
|
+
* **Interactive** mode.
|
|
109
|
+
* **Reply to** a specific message (``--reply-to``).
|
|
110
|
+
* Add video **thumbs**.
|
|
111
|
+
* **Split** and **join** large files.
|
|
112
|
+
* **Delete** local or remote file on success.
|
|
113
|
+
* Use **variables** in the **caption** message.
|
|
114
|
+
* **Proxy** support (http, socks4/5, mtproxy).
|
|
115
|
+
* **Parallel upload** blocks (env: ``TG_UP_PARALLEL_UPLOAD_BLOCKS``).
|
|
116
|
+
|
|
117
|
+
|