You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Generating the regex
- Download the latest CSV file from https://data.gov.in/resources/all-india-pincode-directory-till-last-month.
- Copy all the pincodes to a pincodes.txt file
- Generate all unique pincodes by running
sort -u pincodes.txt > /tmp/pin.txt
node src/generate.js /tmp/pin.txt > regex.txt
Generating the browser-version
- Make sure development dependencies are installed.
npm run browserify.
- Test it by opening
tests/index.htmlin your browser.
git tag 1.2.3
git push --tags
After checking out the repo, run
bin/setup to install dependencies. You can also run
bin/console for an interactive prompt that will allow you to experiment.
To install this gem onto your local machine, run
bundle exec rake install. To release a new version, update the version number in
version.rb, and then run
bundle exec rake release, which will create a git tag for the version, push git commits and tags, and push the
.gem file to rubygems.org.