diff --git a/.dockerignore b/.dockerignore index ac80a7f1..53e8273b 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,8 +1,7 @@ -node_modules/ -Dockerfile* -docker-compose* -.dockerignore dist/ -.git/ -.gitignore -README.md +node_modules/ +# Dockerfile* +# docker-compose* +# .dockerignore +# .git/ +# .gitignore diff --git a/.husky/_/pre-commit b/.husky/_/pre-commit new file mode 100644 index 00000000..3fbf5f96 --- /dev/null +++ b/.husky/_/pre-commit @@ -0,0 +1,60 @@ +#!/bin/sh + +if [ "$LEFTHOOK_VERBOSE" = "1" -o "$LEFTHOOK_VERBOSE" = "true" ]; then + set -x +fi + +if [ "$LEFTHOOK" = "0" ]; then + exit 0 +fi + +call_lefthook() +{ + if test -n "$LEFTHOOK_BIN" + then + "$LEFTHOOK_BIN" "$@" + elif lefthook -h >/dev/null 2>&1 + then + lefthook "$@" + else + dir="$(git rev-parse --show-toplevel)" + osArch=$(uname | tr '[:upper:]' '[:lower:]') + cpuArch=$(uname -m | sed 's/aarch64/arm64/;s/x86_64/x64/') + if test -f "$dir/node_modules/lefthook-${osArch}-${cpuArch}/bin/lefthook" + then + "$dir/node_modules/lefthook-${osArch}-${cpuArch}/bin/lefthook" "$@" + elif test -f "$dir/node_modules/@evilmartians/lefthook/bin/lefthook-${osArch}-${cpuArch}/lefthook" + then + "$dir/node_modules/@evilmartians/lefthook/bin/lefthook-${osArch}-${cpuArch}/lefthook" "$@" + elif test -f "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook" + then + "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook" "$@" + elif test -f "$dir/node_modules/lefthook/bin/index.js" + then + "$dir/node_modules/lefthook/bin/index.js" "$@" + + elif bundle exec lefthook -h >/dev/null 2>&1 + then + bundle exec lefthook "$@" + elif yarn lefthook -h >/dev/null 2>&1 + then + yarn lefthook "$@" + elif pnpm lefthook -h >/dev/null 2>&1 + then + pnpm lefthook "$@" + elif swift package plugin lefthook >/dev/null 2>&1 + then + swift package --disable-sandbox plugin lefthook "$@" + elif command -v mint >/dev/null 2>&1 + then + mint run csjones/lefthook-plugin "$@" + elif command -v npx >/dev/null 2>&1 + then + npx lefthook "$@" + else + echo "Can't find lefthook in PATH" + fi + fi +} + +call_lefthook run "pre-commit" "$@" diff --git a/.husky/_/prepare-commit-msg b/.husky/_/prepare-commit-msg new file mode 100644 index 00000000..e8e8dda9 --- /dev/null +++ b/.husky/_/prepare-commit-msg @@ -0,0 +1,60 @@ +#!/bin/sh + +if [ "$LEFTHOOK_VERBOSE" = "1" -o "$LEFTHOOK_VERBOSE" = "true" ]; then + set -x +fi + +if [ "$LEFTHOOK" = "0" ]; then + exit 0 +fi + +call_lefthook() +{ + if test -n "$LEFTHOOK_BIN" + then + "$LEFTHOOK_BIN" "$@" + elif lefthook -h >/dev/null 2>&1 + then + lefthook "$@" + else + dir="$(git rev-parse --show-toplevel)" + osArch=$(uname | tr '[:upper:]' '[:lower:]') + cpuArch=$(uname -m | sed 's/aarch64/arm64/;s/x86_64/x64/') + if test -f "$dir/node_modules/lefthook-${osArch}-${cpuArch}/bin/lefthook" + then + "$dir/node_modules/lefthook-${osArch}-${cpuArch}/bin/lefthook" "$@" + elif test -f "$dir/node_modules/@evilmartians/lefthook/bin/lefthook-${osArch}-${cpuArch}/lefthook" + then + "$dir/node_modules/@evilmartians/lefthook/bin/lefthook-${osArch}-${cpuArch}/lefthook" "$@" + elif test -f "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook" + then + "$dir/node_modules/@evilmartians/lefthook-installer/bin/lefthook" "$@" + elif test -f "$dir/node_modules/lefthook/bin/index.js" + then + "$dir/node_modules/lefthook/bin/index.js" "$@" + + elif bundle exec lefthook -h >/dev/null 2>&1 + then + bundle exec lefthook "$@" + elif yarn lefthook -h >/dev/null 2>&1 + then + yarn lefthook "$@" + elif pnpm lefthook -h >/dev/null 2>&1 + then + pnpm lefthook "$@" + elif swift package plugin lefthook >/dev/null 2>&1 + then + swift package --disable-sandbox plugin lefthook "$@" + elif command -v mint >/dev/null 2>&1 + then + mint run csjones/lefthook-plugin "$@" + elif command -v npx >/dev/null 2>&1 + then + npx lefthook "$@" + else + echo "Can't find lefthook in PATH" + fi + fi +} + +call_lefthook run "prepare-commit-msg" "$@" diff --git a/bun.lockb b/bun.lockb index b58a3748..21d46c87 100644 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/docker-compose.yml b/docker-compose.yml index 3fb01e91..e713bc7e 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -13,9 +13,9 @@ services: environment: - COMPOSE_PROJECT_NAME=app working_dir: /workspace - volumes: - - .:/workspace:cached - # - node-modules-data:/workspace/node_modules + # volumes: + # - .:/workspace:cached + # - node-modules-data:/workspace/node_modules user: dev # volumes: # node-modules-data: diff --git a/package.json b/package.json index dfbc6f4b..c9c541cc 100644 --- a/package.json +++ b/package.json @@ -23,8 +23,7 @@ "db:generate": "drizzle-kit generate", "db:studio:prod": "drizzle-kit studio", "db:migrate:local": "wrangler d1 migrations apply younagi_dev_db --local", - "db:migrate:prod": "wrangler d1 migrations apply younagi_dev_db", - "prepare": "lefthook install" + "db:migrate:prod": "wrangler d1 migrations apply younagi_dev_db" }, "dependencies": { "@astrojs/check": "^0.5.10", @@ -43,6 +42,7 @@ "astro": "^4.12.2", "astro-purgecss": "4.1.0", "drizzle-orm": "^0.31.1", + "nodemailer": "^6.9.14", "purgecss": "5.0.0", "solid-js": "^1.8.17", "solid-motionone": "^1.0.0", diff --git a/src/components/Icon/types.ts b/src/components/Icon/types.ts index dc98fa61..bc1f21e4 100644 --- a/src/components/Icon/types.ts +++ b/src/components/Icon/types.ts @@ -1,27 +1,27 @@ export type IconName = - | 'bmc' - | 'check' - | 'failure' - | 'github' - | 'hand-heart-filled' - | 'hand-heart' - | 'info' - | 'language' - | 'left-arrow' - | 'link' + | 'unsplash' | 'magnifier' + | 'publish' | 'mail' | 'moon' - | 'new' - | 'pencil' - | 'point' - | 'publish' - | 'question' | 'quote' + | 'point' + | 'bmc' | 'right-arrow' - | 'rss' - | 'sun' + | 'pencil' + | 'warning' | 'toc' - | 'unsplash' + | 'failure' + | 'hand-heart-filled' + | 'github' + | 'info' + | 'new' + | 'hand-heart' | 'update' - | 'warning'; + | 'left-arrow' + | 'language' + | 'rss' + | 'sun' + | 'link' + | 'check' + | 'question';