0.0
Low commit activity in last 3 years
No release in over a year
Provides registry records for regions, cities, and provinces in the Philippines.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 2.3.0
 Project Readme

Phil Locator

Gem Version Known Vulnerabilities FOSSA Status

Description

Provides registry records in the Philippines which the data came from PSA (PSGC).

  • regions
  • cities
  • provinces
  • barangays
  • island_group
  • municipality
  • districts (Metro Manila Only)
  • sub_municipality (Metro Manila Only)

Installation

In Gemfile:

gem "phil_locator", "~> 1.3.0"

Or, from the command line:

gem install phil_locator -v "~> 1.3.0"

Usage

# Regions
PhilLocator::Region.all

# Provinces
PhilLocator::Province.all

# Cities
PhilLocator::City.all

# Barangays
PhilLocator::Barangay.all

Configuration

Create an initializer phil_locator.rb to configure the options, here's a sample provided below

PhilLocator.configure do |config|
    # This overrides the default data directory
    config.data_root_path = Rails.root.join("datasets").to_s
end

Copyright

This project is released under the MIT license.

License

FOSSA Status