From 80f2e72cd4818a4c0a5b5d4afb93dc23f04208e2 Mon Sep 17 00:00:00 2001 From: Martin Kagamino Lehoux Date: Sat, 1 Aug 2026 22:40:08 +0200 Subject: feat: Download mountain passes from centcols into SQLite --- db/migrations/20250802140659_mountain_passes.sql | 12 ++++++++++++ db/schema.sql | 12 ++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 db/migrations/20250802140659_mountain_passes.sql create mode 100644 db/schema.sql (limited to 'db') diff --git a/db/migrations/20250802140659_mountain_passes.sql b/db/migrations/20250802140659_mountain_passes.sql new file mode 100644 index 0000000..afe3218 --- /dev/null +++ b/db/migrations/20250802140659_mountain_passes.sql @@ -0,0 +1,12 @@ +-- migrate:up +create table mountain_passes ( + id integer primary key, + external_id text unique not null, + name text not null, + country_code text not null, + department_code text not null, + elevation integer not null +); + +-- migrate:down +drop table mountain_passes; diff --git a/db/schema.sql b/db/schema.sql new file mode 100644 index 0000000..e6796c8 --- /dev/null +++ b/db/schema.sql @@ -0,0 +1,12 @@ +CREATE TABLE IF NOT EXISTS "schema_migrations" (version varchar(255) primary key); +CREATE TABLE mountain_passes ( + id integer primary key, + external_id text unique not null, + name text not null, + country_code text not null, + department_code text not null, + elevation integer not null +); +-- Dbmate schema migrations +INSERT INTO "schema_migrations" (version) VALUES + ('20250802140659'); -- cgit v1.2.3