Price look-up codes made easy
🍉 4032 🍌 4011 🍇 4023
Data cleaned up from the International Federation of Produce Standards
Add this line to your application’s Gemfile:
gem "plu"
List known PLUs
PLU.all
Get name from PLU
PLU.new(4011).name # Bananas
Check if valid
PLU.new(2000).valid? # false
For PLUs with 5 digits, the first digit has a special meaning: 9 specifies organic.
4011 - Bananas 🍌 94011 - Organic bananas 🍌
PLU.new(94011).organic? # true
PLU.new(3170).retailer_assigned? # true
View the changelog
Everyone is encouraged to help improve this project. Here are a few ways you can help:
- Report bugs
- Fix bugs and submit pull requests
- Write, clarify, or fix documentation
- Suggest or add new features
To get started with development:
git clone https://github.com/ankane/plu.git
cd plu
bundle install
bundle exec rake test