{"id":19724178,"url":"https://github.com/fastruby/pecas","last_synced_at":"2025-04-29T22:31:15.247Z","repository":{"id":33052824,"uuid":"36689097","full_name":"fastruby/pecas","owner":"fastruby","description":"Classy Leaderboards for Noko Time (and Alarms!)","archived":true,"fork":false,"pushed_at":"2023-09-11T20:57:28.000Z","size":666,"stargazers_count":7,"open_issues_count":13,"forks_count":5,"subscribers_count":12,"default_branch":"main","last_synced_at":"2025-03-15T07:12:18.647Z","etag":null,"topics":["hacktoberfest","hacktoberfest2022","leaderboards","noko","ombulabs","open-source","pecas","rails"],"latest_commit_sha":null,"homepage":"https://fastruby.github.io/pecas/","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/fastruby.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"code-of-conduct.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["etagwerker"]}},"created_at":"2015-06-01T21:10:14.000Z","updated_at":"2023-10-18T14:05:08.000Z","dependencies_parsed_at":"2024-11-11T23:28:14.202Z","dependency_job_id":"88db9c87-fcb7-449c-9e29-00f67b5862bc","html_url":"https://github.com/fastruby/pecas","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/fastruby%2Fpecas","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fastruby%2Fpecas/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fastruby%2Fpecas/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fastruby%2Fpecas/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fastruby","download_url":"https://codeload.github.com/fastruby/pecas/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251593022,"owners_count":21614459,"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":["hacktoberfest","hacktoberfest2022","leaderboards","noko","ombulabs","open-source","pecas","rails"],"created_at":"2024-11-11T23:24:47.355Z","updated_at":"2025-04-29T22:31:14.188Z","avatar_url":"https://github.com/fastruby.png","language":"Ruby","readme":"# Pecas: Leaderboards for [Noko](https://nokotime.com)\n\n[![Build Status](https://travis-ci.org/fastruby/pecas.svg?branch=master)](https://travis-ci.org/fastruby/pecas)\n[![Code Climate](https://codeclimate.com/github/fastruby/pecas/badges/gpa.svg)](https://codeclimate.com/github/fastruby/pecas)\n\nPecas is a time tracking leaderboard for\n[https://nokotime.com](https://nokotime.com).\n\n## Getting started\n\nTo get started with the app, clone the repo and then install the needed gems running the setup script:\n\n```bash\ngit clone git@github.com:fastruby/pecas.git\ncd pecas\n./bin/setup\n```\n\n## Environment Variables\n\nThe command `./bin/setup`, among other things, creates the `.env` file which contains the following env variables:\n\n```yml\n# .env.sample\nNOKO_ACCOUNT_HOST=ombulabs\nNOKO_TOKEN=foobar\nSMTP_SERVER=smtp.sendgrid.net\nSMTP_PORT=587\nSMTP_DOMAIN=ombushop.com\nSMTP_USER_NAME=ernesto@ombushop.com\nSMTP_USER_PASSWORD=secret\nCOUNTRY_CODE=\"ar\"\nDATABASE_NAME=\"pecas\"\nBASIC_AUTH_NAME=\"user\"\nBASIC_AUTH_PASSWORD=\"secret\"\n```\n\nNow, you just need to update the `NOKO_TOKEN` env with the correct value.\nYou can fetch the token value from the Noko app, after logging in, you can find the `API token` or create a new one under the `Connected Apps \u003e Noko API \u003e Personal Access Tokens` section.\n\nThe `BASIC_AUTH_NAME` and `BASIC_AUTH_PASSWORD` are already setup from the `.env.sample` file but you can change their values at any time, will be used for a basic http auth for the application.\n\n## Slack Notifications\n\nIf you want to use Pecas to send Slack messages you'll also need to setup\n`SLACK_OAUTH_TOKEN` in the `.env` file. This requires a `SLACK_OAUTH_TOKEN`\ngenerated with the following scopes:\n\n* chat:write\n* usergroups:read\n* users.profile:read\n* users:read\n* users:read.email\n\nOnce set up we can use the rake task `notify:send_noko_format_warning['\u003cname of slack group to alert\u003e']`.\nThis task is destined to be run once an hour (for best results - a few minutes\nafter the hour) as it will only notify users Slack reports as being in the\ntimezone currently within an hour of 8pm.\n\n## Start\n\nYou can setup your `COUNTRY_CODE` environment variable with an ISO 3166 country code.\nOtherwise the emails will be sent on holidays.\n\n## Starting the Server\n\n```bash\nrails s\n```\n\nGo to `http://localhost:3000` and start your session with the `BASIC_AUTH_NAME` and `BASIC_AUTH_PASSWORD` values.\n\n## Running Tests\n\n```bash\nrspec\n```\n\n## Using Docker\n\n\u003e NOTE: You'll need to have docker and docker-compose installed\n\nBuild the pecas docker image\n\n```bash\ndocker-compose build\n```\n\nFirst-time only\n\n```bash\ndocker-compose run web /bin/bash\n./bin/setup\n```\n\nStart\n\n```bash\ndocker-compose up\n```\n\n## Import\n\nImport the entries with:\n\n    rake import:entries\n\nCalculate the leaderboards with:\n\n    rake calc:leaderboards\n\n## Demo Data\n\nGenerate demo data with:\n\n    rake demo_data:setup\n\n## Deleting old data\n\nYou can run this task specifying the number of months ago for the query:\n\n    # delete entries with date older than 6 months ago\n    MONTHS=6 rake delete_past_entries\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at [https://github.com/fastruby/pecas](https://github.com/fastruby/pecas). This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.\n\nWhen Submitting a Pull Request:\n\n- If your PR closes any open GitHub issues, please include `Closes #XXXX` in your comment\n\n- Please include a summary of the change and which issue is fixed or which feature is introduced.\n\n- If changes to the behavior are made, clearly describe what changes.\n\n- If changes to the UI are made, please include screenshots of the before and after.\n\n## License\n\n[License]\n\n[license]: LICENSE\n\n## Sponsorship\n\n![FastRuby.io | Rails Upgrade Services](app/assets/images/fastruby-logo.png)\n\n`Pecas` is maintained and funded by [FastRuby.io](https://fastruby.io). The names and logos for FastRuby.io are trademarks of The Lean Software Boutique LLC.\n","funding_links":["https://github.com/sponsors/etagwerker"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffastruby%2Fpecas","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffastruby%2Fpecas","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffastruby%2Fpecas/lists"}