This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PYTHON_VERSION=3.11.9 | |
pyenv install $PYTHON_VERSION | |
pyenv shell $PYTHON_VERSION | |
WHERE_IS_THE_PYTHON_UBUNTOVSKI=`pyenv which python` | |
pipx reinstall --python=$WHERE_IS_THE_PYTHON_UBUNTOVSKI poetry | |
pipx reinstall --python=$WHERE_IS_THE_PYTHON_UBUNTOVSKI cookiecutter |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Update whole docker swarm stack from CI job and wait untill success. | |
# Inits rollback process in case of unsuccessfull deployment. | |
# | |
# Requires another script from here: https://github.com/sudo-bmitch/docker-stack-wait | |
# | |
# By: Alexey Chudin <[email protected]> | |
# License: MIT | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
mplayer -ontop -noborder -geometry 300x300+80+750 -vf mirror,crop=240:240:30:0 -vo gl2 -msglevel all=0 -tv width=300:height=300:device=/dev/video0 tv:// & | |
simplescreenrecorder --start-hidden &>/dev/null & | |
sleep 3 | |
wmctrl -r MPlayer -b add,sticky |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Here is a way to flatten python dictionaries for making multipart/form-data POST requests. | |
{"some": ["balls", "toys"], "field": "value", "nested": {"objects": "here"}} | |
-> | |
{"some[0]": "balls", "some[1]": "toys", "field": "value", "nested[objects]": "here"} | |