bashrc: better git add

This commit is contained in:
Jaewook Lee
2024-08-11 14:01:10 +09:00
parent 29aa690274
commit cbbde754a8
2 changed files with 29 additions and 2 deletions

View File

@@ -1,5 +1,6 @@
export RC="~/.bash_aliases"
alias rc="vi $RC && tail $RC && source $HOME/.${SHELL##*/}rc"
alias bat="batcat --paging=never"
alias my="sudo chown -R $(id -u):$(id -g)"
@@ -47,6 +48,8 @@ diff() {
if [[ $# -eq 0 ]]; then
clear
git status
echo
echo
git diff --staged
else
diff -qr "$@"
@@ -78,12 +81,19 @@ alias df="df -h"
alias status="git status ."
alias push="git push"
alias pull="git pull"
alias add="git add"
add() {
if [ $# -eq 0 ]; then
git add .
else
git add $@
fi
diff
}
alias remote="git remote -v"
alias stash="git stash"
alias vimrc="vi ~/.vimrc"
commit() {
git commit -m "$*"
git commit -m "$*"
}
git() {
@@ -103,3 +113,5 @@ git() {
alias cls="clear"
alias weather="curl ko.wttr.in"
alias dryblack="clear; black --check --diff --color ."

15
playwright/app.py Normal file
View File

@@ -0,0 +1,15 @@
# pip install playwright && playwright install --with-deps
import asyncio, threading, queue, io, pandas as pd
from playwright.async_api import async_playwright
def GET(url, html = queue.Queue()):
async def aGET(P = async_playwright().start()):
html.put(await (await (await (await (await P)
.chromium.launch()).new_page()).goto(url)).text())
threading.Thread(target=lambda: asyncio.run(aGET())).start()
return io.StringIO(html.get())
df = pd.read_html(GET('https://freeproxy.world/?type=socks5'))[0]
df = df.loc[df.Type == 'socks5'].reset_index(drop=True)
print(f'\x1b[92m{df}\x1b[0m')