{"id":13739167,"url":"https://github.com/dimakura/ka","last_synced_at":"2026-01-03T02:15:07.562Z","repository":{"id":8329028,"uuid":"9882103","full_name":"dimakura/ka","owner":"dimakura","description":"common functionality for georgian projects","archived":false,"fork":false,"pushed_at":"2013-11-09T09:08:06.000Z","size":136,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2024-11-15T09:42:45.717Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dimakura.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-05-06T08:00:21.000Z","updated_at":"2013-11-11T05:13:22.000Z","dependencies_parsed_at":"2022-08-07T02:30:48.132Z","dependency_job_id":null,"html_url":"https://github.com/dimakura/ka","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimakura%2Fka","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimakura%2Fka/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimakura%2Fka/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimakura%2Fka/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dimakura","download_url":"https://codeload.github.com/dimakura/ka/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253127116,"owners_count":21858194,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-03T04:00:27.032Z","updated_at":"2026-01-03T02:15:07.532Z","avatar_url":"https://github.com/dimakura.png","language":"Ruby","readme":"# KA: write georgian softwate with ruby\n\nThere are number of occasions when you deal with uncommon situations in georgian software.\nThose are:\n\n* mobile number validation,\n* numbers to readable format (1 -\u003e 'ერთი'), \n* date formatting (not supported by i18n)\n* and outdated, but still active, GEO character encoding.\n\nKA gem will enable you to deal with all these situations.\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n    gem 'ka', \n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install ka\n\n## Usage\n\n### Mobile numbers\n\nValidation and formatting of mobile numbers are self-exmplanatory:\n\n```ruby\nrequire 'ka'\ninclude KA\n...\nmobile = 'my mobile: (595) 33 55 14'\ncompact_mobile(mobile) # =\u003e '595335514'\ncorrect_mobile?(mobile) # =\u003e true\nformat_mobile(mobile, operator_pre: '[', operator_suf: ']', by: 2, separator: ' ') #=\u003e [595]33 55 14\n```\n\n### Number spelling\n\n`to_ka` method is integrated within `Integer` class.\nNow you can convert integers into georgian words (works upto 999,999,999,999,999).\n\nThis task is common, especialy when writing some accounting software.\n\n```ruby\n1.to_ka # =\u003e ერთი\n999_999_999_999_999.to_ka # =\u003e ცხრაას ოთხმოცდა ცხრამეტი ტრილიონ ცხრაას ოთხმოცდა ცხრამეტი მილიარდ ცხრაას ოთხმოცდა ცხრამეტი მილიონ ცხრაას ოთხმოცდა ცხრამეტი ათას ცხრაას ოთხმოცდა ცხრამეტი\n```\n\n### Date formats\n\nTODO:\n\n### GEO character encoding\n\nWhen using the `ka` gem `String` automatically receives the `to_ka`, `to_geo` and `to_lat` methods.\n\n```ruby\n'dimitri'.to_ka(:all)  # =\u003e დიმიტრი\n'დიმიტრი'.to_lat # =\u003e dimitri\n'დიმიტრი'.to_geo # =\u003e ÃÉÌÉÔÒÉ\n```\n\nThe `to_ka` method receives the additional `type` parameter which indicates which characters\nto use when converting to georgian unicode. There are three possible values for this parameter:\n\n* `geo`, convert only GEO characters (default),\n* `lat`, convert only LAT characters and\n* `all`, converts both GEO and LAT characters.\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create new Pull Request\n","funding_links":[],"categories":["Categories","Georgian"],"sub_categories":["Internationalization and Localization (i18n/l10n)"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdimakura%2Fka","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdimakura%2Fka","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdimakura%2Fka/lists"}