Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bodrovis-learning/python-screenshots
Python script to capture screenshots.
https://github.com/bodrovis-learning/python-screenshots
pyautogui python screenshots
Last synced: 10 days ago
JSON representation
Python script to capture screenshots.
- Host: GitHub
- URL: https://github.com/bodrovis-learning/python-screenshots
- Owner: bodrovis-learning
- License: other
- Created: 2021-04-02T19:49:20.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2023-12-14T21:20:37.000Z (11 months ago)
- Last Synced: 2023-12-14T22:57:50.508Z (11 months ago)
- Topics: pyautogui, python, screenshots
- Language: Python
- Homepage: https://www.youtube.com/watch?v=rJe_osIzqUY
- Size: 40 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Python Screenshots Capturer
A dead simple Python script to capture screenshots. Written mostly for demonstration purposes. Dependencies:
* [Keyboard](https://github.com/boppreh/keyboard)
* [MSS](https://github.com/BoboTiG/python-mss)
* Built-in modules (OS, Sys, Datetime)How this program was built (Russian): https://www.youtube.com/watch?v=rJe_osIzqUY
## How to use it
Install the above dependencies manually or use [Poetry](https://python-poetry.org) to do the job for you:
```
poetry install
```Run:
```
python python_screenshots/screenshots.py
```Or with Poetry:
```
poetry run python python_screenshots\screenshots.py
```Keep the window opened (it does not have to stay in focus) and press the `PrtScr` key to make a PNG screenshot. By default, screenshots are created in the same directory where your script resides, under the `screens` subdirectory.
To provide a custom subdirectory:
```
python python_screenshots/screenshots.py my/sub_dir
```Stop the script with `Ctrl+Shift+X`.
## Building
To build an executable file you can use `pyinstaller`:
```
poetry run pyinstaller python_screenshots/screenshots.py -F
```## Development
Install Poetry and run:
```
poetry install
```Have fun.
## License
(c) [Ilya Bodrov-Krukowski](http://bodrovis.tech/), licensed under the [beer-ware license](https://fedoraproject.org/wiki/Licensing/Beerware).