Skip to content

Commit 15e3a0e

Browse files
feat: recent videos
1 parent 3e1c55c commit 15e3a0e

213 files changed

Lines changed: 1870 additions & 1630 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agents/skills/ntp-time/SKILL.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
name: ntp-time
3+
description: Query the current date and time from an NTP server with a bundled script. Use when a user asks for network time, wants to compare system time with NTP time, or needs a minimal example skill that includes a script and a reference file.
4+
---
5+
6+
# NTP Time
7+
8+
Use `scripts/get-ntp-time.ts` instead of reimplementing the NTP request.
9+
10+
Default to `pool.ntp.org` unless the user names a different server.
11+
12+
Run:
13+
14+
```bash
15+
tsx scripts/get-ntp-time.ts
16+
tsx scripts/get-ntp-time.ts time.google.com
17+
node --experimental-strip-types scripts/get-ntp-time.ts
18+
```
19+
20+
Return the server used, the UTC ISO timestamp, and the Unix epoch.
21+
22+
Read `references/ntp.md` only if you need protocol details or need to explain the output.
23+
24+
If the request fails, report the network error clearly and do not guess the time.
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# NTP Notes
2+
3+
- NTP uses UDP port `123`.
4+
- A minimal client can send a 48-byte packet with the first byte set to `0x1b`.
5+
- The server transmit timestamp is stored in the last 8 bytes of the response.
6+
- NTP timestamps count seconds since `1900-01-01T00:00:00Z`.
7+
- Unix timestamps count seconds since `1970-01-01T00:00:00Z`.
8+
- Convert NTP seconds to Unix seconds by subtracting `2208988800`.
9+
10+
The bundled script prints:
11+
12+
- `server`: hostname queried
13+
- `utc_iso`: UTC timestamp in ISO 8601 form
14+
- `unix_epoch`: Unix time as a floating-point number
15+
16+
Typical usage:
17+
18+
```bash
19+
tsx scripts/get-ntp-time.ts
20+
node --experimental-strip-types scripts/get-ntp-time.ts pool.ntp.org --timeout 2.0
21+
```
Lines changed: 98 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,98 @@
1+
#!/usr/bin/env node
2+
3+
import dgram from "node:dgram";
4+
5+
const NTP_DELTA = 2208988800;
6+
7+
function parseArgs(args: string[]) {
8+
let server = "pool.ntp.org";
9+
let timeout = 2000;
10+
11+
for (let index = 0; index < args.length; index += 1) {
12+
const value = args[index];
13+
14+
if (value === "--timeout") {
15+
const next = args[index + 1];
16+
if (!next) {
17+
throw new Error("missing value for --timeout");
18+
}
19+
timeout = Math.round(Number.parseFloat(next) * 1000);
20+
index += 1;
21+
continue;
22+
}
23+
24+
if (!value.startsWith("-")) {
25+
server = value;
26+
continue;
27+
}
28+
29+
throw new Error(`unknown argument: ${value}`);
30+
}
31+
32+
if (!Number.isFinite(timeout) || timeout <= 0) {
33+
throw new Error("timeout must be a positive number");
34+
}
35+
36+
return { server, timeout };
37+
}
38+
39+
function queryNtp(server: string, timeout: number) {
40+
return new Promise<{ utcIso: string; unixEpoch: number }>((resolve, reject) => {
41+
const socket = dgram.createSocket("udp4");
42+
const packet = Buffer.alloc(48);
43+
packet[0] = 0x1b;
44+
45+
const timer = setTimeout(() => {
46+
socket.close();
47+
reject(new Error("request timed out"));
48+
}, timeout);
49+
50+
socket.on("error", (error) => {
51+
clearTimeout(timer);
52+
socket.close();
53+
reject(error);
54+
});
55+
56+
socket.on("message", (message) => {
57+
clearTimeout(timer);
58+
socket.close();
59+
60+
if (message.length < 48) {
61+
reject(new Error("short NTP response"));
62+
return;
63+
}
64+
65+
const seconds = message.readUInt32BE(40);
66+
const fraction = message.readUInt32BE(44);
67+
const unixEpoch = seconds - NTP_DELTA + fraction / 2 ** 32;
68+
const utcIso = new Date(unixEpoch * 1000).toISOString();
69+
70+
resolve({ utcIso, unixEpoch });
71+
});
72+
73+
socket.send(packet, 123, server, (error) => {
74+
if (!error) {
75+
return;
76+
}
77+
78+
clearTimeout(timer);
79+
socket.close();
80+
reject(error);
81+
});
82+
});
83+
}
84+
85+
async function main() {
86+
const { server, timeout } = parseArgs(process.argv.slice(2));
87+
const { utcIso, unixEpoch } = await queryNtp(server, timeout);
88+
89+
console.log(`server: ${server}`);
90+
console.log(`utc_iso: ${utcIso}`);
91+
console.log(`unix_epoch: ${unixEpoch.toFixed(6)}`);
92+
}
93+
94+
main().catch((error: unknown) => {
95+
const message = error instanceof Error ? error.message : String(error);
96+
console.error(`error: ${message}`);
97+
process.exitCode = 1;
98+
});

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
"dependencies": {
2323
"@iconify-json/lucide": "^1.2.98",
2424
"@tailwindcss/vite": "^4.2.2",
25-
"astro": "^6.0.8",
25+
"astro": "^6.1.4",
2626
"astro-icon": "^1.1.5",
2727
"metagroup-schema-tools": "^1.1.0",
2828
"shaders": "^2.4.78",

pnpm-lock.yaml

Lines changed: 10 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/vigotech-generated.json

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,12 @@
5656
"channel_id": "UC9DPKfcLiNd7SEU-QLlIG7A"
5757
}
5858
],
59-
"nextEvent": null,
59+
"nextEvent": {
60+
"title": "Introdución ao procesado de audio con STM32 e I2S",
61+
"date": 1776499200000,
62+
"url": "https://www.meetup.com/aindustriosa/events/314059100/",
63+
"location": "Vigo - es"
64+
},
6065
"videoList": [
6166
{
6267
"player": "youtube",
@@ -1219,7 +1224,12 @@
12191224
"type": "meetup",
12201225
"meetupid": "craftersvigo"
12211226
},
1222-
"nextEvent": null,
1227+
"nextEvent": {
1228+
"title": "#65 - Forjando código: TDD con IA en el reino medieval",
1229+
"date": 1775583000000,
1230+
"url": "https://www.meetup.com/craftersvigo/events/314077652/",
1231+
"location": "A Industriosa - Gregorio Espino 38, Entresuelo 3, Vigo, al - Vigo - al - es"
1232+
},
12231233
"videoList": [],
12241234
"eventList": []
12251235
},
@@ -1231,6 +1241,10 @@
12311241
"twitter": "https://twitter.com/galpon",
12321242
"maillist": "https://www.galpon.org/content/listas-correo-galpon"
12331243
},
1244+
"events": {
1245+
"type": "json",
1246+
"source": "https://raw.githubusercontent.com/Daniel-at-github/vigotech_events/refs/heads/main/calendars/obradoiros_galpon.json"
1247+
},
12341248
"nextEvent": null,
12351249
"videoList": [],
12361250
"eventList": []
@@ -4690,6 +4704,29 @@
46904704
"location": "Círculo de Empresarios de Galicia - Rúa de García Barbón, 62, Vigo, Po - Vigo - Po - es"
46914705
},
46924706
"videoList": [
4707+
{
4708+
"player": "youtube",
4709+
"id": "kFLjqsvZKEc",
4710+
"title": "Posicionando sin IA en tiempos de IA",
4711+
"pubDate": 1775159541000,
4712+
"thumbnails": {
4713+
"default": {
4714+
"url": "https://i.ytimg.com/vi/kFLjqsvZKEc/default.jpg",
4715+
"width": 120,
4716+
"height": 90
4717+
},
4718+
"medium": {
4719+
"url": "https://i.ytimg.com/vi/kFLjqsvZKEc/mqdefault.jpg",
4720+
"width": 320,
4721+
"height": 180
4722+
},
4723+
"high": {
4724+
"url": "https://i.ytimg.com/vi/kFLjqsvZKEc/hqdefault.jpg",
4725+
"width": 480,
4726+
"height": 360
4727+
}
4728+
}
4729+
},
46934730
{
46944731
"player": "youtube",
46954732
"id": "IWd72H69Xqo",
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
sourceId: "agilevigo-1774544400000-vibe-coding-luxembourg-build-a-real-app-in-60-minutes-with-ai"
3+
groupId: "agilevigo"
4+
groupName: "Agile Vigo"
5+
groupLogo: "https://vigotech.org/images/agile_vigo.jpg"
6+
title: "Vibe Coding Luxembourg: Build a Real App in 60 Minutes with AI"
7+
description: null
8+
date: 1774544400000
9+
dateISO: "2026-03-26T17:00:00.000Z"
10+
location: "Online event"
11+
link: "https://www.meetup.com/luxembourg-vibe-coding-meetup-group/events/313651478/"
12+
---
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
sourceId: "aindustriosa-1776499200000-introducion-ao-procesado-de-audio-con-stm32-e-i2s"
3+
groupId: "aindustriosa"
4+
groupName: "A Industriosa"
5+
groupLogo: "https://vigotech.org/images/aindustriosa.png"
6+
title: "Introdución ao procesado de audio con STM32 e I2S"
7+
description: null
8+
date: 1776499200000
9+
dateISO: "2026-04-18T08:00:00.000Z"
10+
location: "Vigo - es"
11+
link: "https://www.meetup.com/aindustriosa/events/314059100/"
12+
---
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
sourceId: "craftersvigo-1775583000000-65-forjando-codigo-tdd-con-ia-en-el-reino-medieval"
3+
groupId: "craftersvigo"
4+
groupName: "Crafters Vigo"
5+
groupLogo: "https://vigotech.org/images/craftersVigo.png"
6+
title: "#65 - Forjando código: TDD con IA en el reino medieval"
7+
description: null
8+
date: 1775583000000
9+
dateISO: "2026-04-07T17:30:00.000Z"
10+
location: "A Industriosa - Gregorio Espino 38, Entresuelo 3, Vigo, al - Vigo - al - es"
11+
link: "https://www.meetup.com/craftersvigo/events/314077652/"
12+
---
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
---
2-
sourceId: 'pythonvigo-1671130800000-reunion-diciembre-2022'
3-
groupId: 'pythonvigo'
4-
groupName: 'PythonVigo'
5-
groupLogo: 'https://vigotech.org/images/python_vigo.png'
6-
title: 'Reunión Diciembre 2022'
2+
sourceId: "pythonvigo-1671130800000-reunion-diciembre-2022"
3+
groupId: "pythonvigo"
4+
groupName: "PythonVigo"
5+
groupLogo: "https://vigotech.org/images/python_vigo.png"
6+
title: "Reunión Diciembre 2022"
77
description: null
88
date: 1671130800000
9-
dateISO: '2022-12-15T19:00:00.000Z'
10-
location: 'Cafe UF'
11-
link: 'https://www.python-vigo.es/posts/reunion-diciembre-2022/'
9+
dateISO: "2022-12-15T19:00:00.000Z"
10+
location: "Cafe UF"
11+
link: "https://www.python-vigo.es/posts/reunion-diciembre-2022/"
1212
---

0 commit comments

Comments
 (0)