diff options
| author | Martin Kagamino Lehoux <martin@lehoux.net> | 2026-08-27 19:03:34 +0200 |
|---|---|---|
| committer | Martin Kagamino Lehoux <martin@lehoux.net> | 2026-08-27 19:03:34 +0200 |
| commit | d7b93325d4f70eeab369fa8a3c4cce9f0c4e0081 (patch) | |
| tree | 76a913248fa04325e8e85f34df0cd03654e1ca76 /config/config.go | |
| parent | 558f755f5746a4ee819de87579951b7533688e5d (diff) | |
Add dual GPX/FIT exporter and backfill for rides
Phase 1 writes both .gpx and .fit on Strava import, adds fit_path
column, renames storage.gpx_dir to storage.rides_dir, and backfills
missing FIT files from existing GPX without breaking CLI progress.
FIT files are gitignored.
Diffstat (limited to 'config/config.go')
| -rw-r--r-- | config/config.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/config/config.go b/config/config.go index f95d3f8..8a61d43 100644 --- a/config/config.go +++ b/config/config.go @@ -29,7 +29,7 @@ type ServerConfig struct { } type StorageConfig struct { - GPXDir string `yaml:"gpx_dir"` + RidesDir string `yaml:"rides_dir"` } type StravaConfig struct { @@ -57,7 +57,7 @@ func Default() Config { Address: "127.0.0.1:8080", PublicURL: "http://localhost:8080", }, - Storage: StorageConfig{GPXDir: "data/rides"}, + Storage: StorageConfig{RidesDir: "data/rides"}, OfficialClimb: OfficialClimbConfig{MatchRadiusM: official_climb.DefaultMatchRadiusM}, Pyroscope: PyroscopeConfig{ ApplicationName: "biking_home", @@ -81,8 +81,8 @@ func Load(filename string) (Config, error) { if config.Server.Address == "" || config.Server.PublicURL == "" { return Config{}, fmt.Errorf("config %q: server.address and server.public_url are required", filename) } - if config.Storage.GPXDir == "" { - return Config{}, fmt.Errorf("config %q: storage.gpx_dir is required", filename) + if config.Storage.RidesDir == "" { + return Config{}, fmt.Errorf("config %q: storage.rides_dir is required", filename) } if config.Pyroscope.Enabled && config.Pyroscope.ApplicationName == "" { return Config{}, fmt.Errorf("config %q: pyroscope.application_name is required when pyroscope is enabled", filename) |
