geo_bearing
Version, currently 0.1.01 version
- 0.1.0latestMar 29, 2024
github.com/geocrystal/geo_bearing
Calculates initial and final bearings between two points using great-circle distance formulas
4 stars
1 dependent
License: MIT
Installation
# Add this to your shard.yml
dependencies:
geo_bearing:
github: geocrystal/geo_bearing
version: ~> 0.1.0Then run:
shards installshard.yml
- Crystal
>= 1.0.0- License
- MIT
- Author
- Anton Maminov <anton.maminov@gmail.com>
Dependencies
This version declares no dependencies.
README
# geo_bearing
[](https://github.com/geocrystal/geo_bearing/actions/workflows/crystal.yml)
[](https://github.com/mamgeocrystalantoha/geo_bearing/releases)
[](https://github.com/geocrystal/geo_bearing/blob/main/LICENSE)
Crystal implementation of calculating initial and final bearings between two points using great-circle distance formulas.
## Installation
1. Add the dependency to your `shard.yml`:
```yaml
dependencies:
geo_bearing:
github: geocrystal/geo_bearing
```
2. Run `shards install`
## Usage
```crystal
require "geo_bearing"
lat1, lng1 = {48.8566, 2.3522} # Paris
lat2, lng2 = {40.7128, -74.0060} # New York
Geo::Bearing.bearing(lat1, lng1, lat2, lng2)
# => 291.7938627483058
Geo::Bearing.bearing(lat1, lng1, lat2, lng2, true)
# => 233.70448129781204
```

## Contributing
1. Fork it (<https://github.com/geocrystal/geo_bearing/fork>)
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create a new Pull Request
## Contributors
- [Anton Maminov](https://github.com/mamantoha) - creator and maintainer
Documentation
Built from the current release. The first visit to a release nobody has asked for starts its build.
Links
This release
- Version
0.1.0- Tagged
- Mar 29, 2024
- Commit
6229514418c8- Crystal
>= 1.0.0- Indexed
- yes
Dependents
Repository
github.com/geocrystal/geo_bearing
Metadata
- Created
- Aug 12, 2026
- Updated
- Aug 12, 2026
- Synced
- Aug 12, 2026
- Versions
- 1