.git/hooks/commit-msgConventional commits provide a consistent way to structure commit messages, which helps with automation, release notes generation, and understanding the history of a project. The format adheres to the following structure:
| function extractMeetingUrl(location: string): string { | |
| // Check if it's a goo.gl redirect URL with embedded meet.google.com link | |
| if (location.includes("goo.gl") && location.includes("meet.google.com")) { | |
| // Extract the actual meet.google.com URL from the redirect | |
| const meetMatch = location.match(/meet\.google\.com\/[a-z]+-[a-z]+-[a-z]+/i); | |
| if (meetMatch) { | |
| return `https://${meetMatch[0]}`; | |
| } | |
| } | |
| return location; |
| { | |
| "$schema": "https://biomejs.dev/schemas/2.3.2/schema.json", | |
| "vcs": { | |
| "enabled": false, | |
| "clientKind": "git", | |
| "useIgnoreFile": false | |
| }, | |
| "files": { | |
| "ignoreUnknown": true | |
| }, |
| const version = await $`git describe --tags --always`.text(); | |
| const buildTime = new Date().toISOString(); | |
| const gitCommit = await $`git rev-parse HEAD`.text(); |
| function formatDuration(seconds: number): string { | |
| let m = Math. floor (seconds / 60); | |
| let s = seconds % 60; | |
| return `${m}:${s.toString().padStart(2, "0")}`; | |
| } |
| <script lang="ts"> | |
| import { scale } from 'svelte/transition'; | |
| let hoveredIndex = $state(null as number | null); | |
| let selected = $state(null as number | null); | |
| // Create an array of years from 1993 to 2024 | |
| let YEARS = Array.from({ length: 2024 - 1993 + 1 }, (_, i) => 2024 - i); | |
| let handleMouseEnter = (index: number) => { |
| type Options = { | |
| /** The time before the copied status is reset. */ | |
| delay: number; | |
| /** Whether to reset the copied status after a delay. */ | |
| reset: boolean; | |
| }; | |
| /** Use this hook to copy text to the clipboard and show a copied state. | |
| * | |
| * ## Usage |
| import { FFmpeg } from '@ffmpeg/ffmpeg'; | |
| import { toBlobURL } from '@ffmpeg/util'; | |
| let ffmpeg: FFmpeg | null = null; | |
| export const initFFmpeg = async (): Promise<FFmpeg> => { | |
| if (ffmpeg) return ffmpeg; | |
| ffmpeg = new FFmpeg(); | |
| export async function getStars(): Promise<string> { | |
| try { | |
| const res = await fetch( | |
| "https://api.github.com/repos/milksense/milksense", | |
| { | |
| next: { revalidate: 3600 }, | |
| } | |
| ); | |
| if (!res.ok) { |
| <script lang="ts"> | |
| import { dev } from "$app/environment"; | |
| </script> | |
| {#if dev} | |
| <div | |
| data-tailwind-indicator="" | |
| class="fixed bottom-1 left-1 z-50 flex h-6 w-6 items-center justify-center rounded-full bg-gray-800 p-3 font-mono text-xs text-white" | |
| > | |
| <div class="block sm:hidden">xs</div> |