- ~/.profile
-
- ~/.xinitrc
-
-
- ~/.xsessionrc
-
// https://en.wikipedia.org/wiki/Geometric_series | |
/** | |
* a*r.pow(1) + a*r.pow(2) + a*r.pow(3) + a*r.pow(4) + ... + a*r.pow(n) | |
* 1*10 + 1*100 + 1*1_000 + 1*10_000 + ... + 1*10.pow(n) | |
*/ | |
private fun getSumOfGeometricSeries(a: Int = 1, r: Double = 10.0, n: Int): Double { | |
return r * a * (1.0 - r.pow(n)) / (1.0 - r) | |
} |
#!/bin/bash | |
rm ggml-alpaca-7b-q4.bin | |
curl https://gateway.estuary.tech/gw/ipfs/QmQ1bf2BTnYxq73MFJWu1B7bQ2UD6qG7D7YDCxhTndVkPC -o ggml-alpaca-7b-q4.bin | |
ISSUER='alpaca.cpp' | |
ISSUER_VERSION='9116ae9' | |
IMAGE_VERSION='1' | |
IMAGE_TAG="$ISSUER:${ISSUER_VERSION}-${IMAGE_VERSION}" |
from amd64/debian:bullseye-20230320-slim | |
run apt-get update && apt-get upgrade -y | |
run apt-get install --no-install-recommends -y \ | |
make build-essential curl ca-certificates unzip | |
run apt autoremove | |
arg VERSION | |
run curl -L https://github.com/antimatter15/alpaca.cpp/archive/refs/tags/${VERSION}.zip \ |
alias d='ls --almost-all --group-directories-first --indicator-style=slash -v -1' |
PS1="\n┌ \[\033[01;34m\]\$(pwd)\]\e[0m\n└ $ " |
#!/bin/bash | |
ISSUER='some_dir' | |
echo " | |
zip..." | |
rm "${ISSUER}.zip" | |
$(DIR="$(pwd)" && cd "$ISSUER" && zip -r9 "$DIR/${ISSUER}.zip" $(ls -A) > /dev/null) || exit 1 # todo |
#!/bin/bash | |
ADDRESS='8.8.8.8' | |
REGEX='(?<=time=)[1-9][0-9]*.[0-9]+' | |
BYTES=64 | |
LINE=$(/usr/bin/ping -c1 -s $((BYTES - 8)) "$ADDRESS") | |
if test $? -ne 0; then | |
echo "Ping 1 error!"; exit 11 | |
elif test -x "$LINE"; then |
[ | |
{ | |
"button": "button1", | |
"count": 1, | |
"modifiers": ["ctrl"], | |
"press_command": "drag_select", | |
"command": "goto_definition" | |
}, | |
{ | |
"button": "button3", |
[ | |
{ "keys": ["ctrl+shift+u"], "command": "upper_case" }, | |
{ "keys": ["ctrl+shift+l"], "command": "lower_case" }, | |
{ "keys": ["ctrl+d"], "command": "duplicate_line" } | |
] |