Popularity
3.2
Growing
Activity
0.0
Stable
32
2
18
Programming language: Go
License: GNU General Public License v3.0 only
Tags:
Files
Latest version: v1.1.0
go-gtfs alternatives and similar packages
Based on the "Files" category.
Alternatively, view go-gtfs alternatives based on common mentions on social networks and blogs.
-
go-storage
A vendor-neutral storage library for Golang: Write once, run on every storage service. -
bigfile
Bigfile -- a file transfer system that supports http, rpc and ftp protocol https://bigfile.site -
go-exiftool
Golang wrapper for Exiftool : extract as much metadata as possible (EXIF, ...) from files (pictures, pdf, office documents, ...) -
skywalker
A package to allow one to concurrently go through a filesystem with ease -
concurrent-writer
Highly concurrent drop-in replacement for bufio.Writer -
fileconversion
A Go library to convert various file formats to plaintext and provide related functions -
shred
This is a libary to mimic the functionallity of the linux shred command. -
go-staticfiles
Collects assets (css, js, images...) from a different locations and tags file names with a hash for easy versioning and aggressive caching.
Less time debugging, more time building
Scout APM allows you to find and fix performance issues with no hassle. Now with error monitoring and ο»Ώexternal services monitoring, Scout is a developer's best friend when it comes to application development.
Promo
scoutapm.com
Do you think we are missing an alternative of go-gtfs or a related project?
Popular Comparisons
README
go-gtfs
Load GTFS files in golang
Install
go get github.com/artonge/go-gtfs
Examples
Load one directory containing GTFS files:
path/to/gtfs_files
βββ agency.txt
βββ calendar_dates.txt
βββ calendar.txt
βββ routes.txt
βββ stops.txt
βββ stop_times.txt
βββ transfers.txt
βββ trips.txt
g, err := gtfs.Load("path/to/gtfs_files", nil)
Load a directory containing sub directories containing GTFS files:
path/to/gtfs_directories
βββ gtfs1
βΒ Β βββ agency.txt
βΒ Β βββ calendar_dates.txt
βΒ Β βββ routes.txt
βΒ Β βββ stops.txt
βΒ Β βββ stop_times.txt
βΒ Β βββ transfers.txt
βΒ Β βββ trips.txt
βββ gtfs2
βββ agency.txt
βββ calendar_dates.txt
βββ calendar.txt
βββ routes.txt
βββ stops.txt
βββ stop_times.txt
βββ transfers.txt
βββ trips.txt
gs, err := gtfs.LoadSplitted("path/to/gtfs_directories", nil)
You can then access the data through the GTFS structure. That structure contains arrays of approriate structures for each files.
type GTFS struct {
Path string // The path to the containing directory
Agency Agency
Routes []Route
Stops []Stop
StopsTimes []Stop
Trips []Trip
Calendars []Calendar
Transfers []Transfer
}
type Route struct {
ID string `csv:"route_id"`
AgencyID string `csv:"agency_id"`
ShortName string `csv:"route_short_name"`
LongName string `csv:"route_long_name"`
Type int `csv:"route_type"`
Desc string `csv:"route_url"`
URL string `csv:"route_desc"`
Color string `csv:"route_color"`
TextColor string `csv:"route_text_color"`
}
...
Contributions
Pull requests are welcome ! :)