arigram/do
Ari Archer 9bfc08f357
[CORE] improved code, formatting and fixed some bugs
- Added a better `.gitignore`
- Formatted the `do` script better, made it better in general
- Improved instalation and upgrading instructons
- Removed arrow key support
- Imrproved `README.md` formatting
- Improved the runtime (`__main__.py`) script, improved formatting,
  handling of arguments and added docstrings
- Renamed `colors` to `colours`
- Added type hints to the config file and improved how it handles some
  things
- Improved chat action strings (e.g `uploading video` -> `is uploading a video`)
- Made `COPY_CMD` deprecated, using `pyperclip` instead
- Changed dependency for stability from dynamic to exact
  (`python-telegram>=....` to `python-telegram==....`)

Signed-off-by: Ari Archer <truncateddinosour@gmail.com>
2022-01-01 03:21:24 +02:00

60 lines
875 B
Bash
Executable file

#!/usr/bin/env bash
set -xe
main() {
SRC="$(dirname "$0")"
cd "$SRC"
ARG=${1:-""}
case $ARG in
review)
gh pr create -f
;;
push)
isort arigram/*.py
black .
python3 -m poetry check
python3 -m poetry lock
$0 check
$0 local
git diff >/tmp/arigram.diff
git add -A
git commit -sa
git push -u origin main
;;
local)
python3 -m poetry check
python3 -m poetry lock
python3 -m poetry install
python3 -m pip install --user --upgrade .
;;
upgrade)
git reset --hard
git pull
$0 local
;;
check)
black .
isort arigram/*.py
chmod a+rx ./check.sh
./check.sh
;;
*)
python3 -m arigram
;;
esac
}
main "$@"