{"id":48890732,"url":"https://github.com/ericboehs/github-viewer","last_synced_at":"2026-04-16T07:36:57.129Z","repository":{"id":321854481,"uuid":"1086058148","full_name":"ericboehs/github-viewer","owner":"ericboehs","description":null,"archived":false,"fork":false,"pushed_at":"2026-03-12T03:20:35.000Z","size":1761,"stargazers_count":1,"open_issues_count":15,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-12T03:55:38.591Z","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":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ericboehs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-29T22:16:00.000Z","updated_at":"2026-03-12T03:20:38.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ericboehs/github-viewer","commit_stats":null,"previous_names":["ericboehs/github-viewer"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ericboehs/github-viewer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericboehs%2Fgithub-viewer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericboehs%2Fgithub-viewer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericboehs%2Fgithub-viewer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericboehs%2Fgithub-viewer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ericboehs","download_url":"https://codeload.github.com/ericboehs/github-viewer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericboehs%2Fgithub-viewer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31876810,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-16T07:36:03.521Z","status":"ssl_error","status_checked_at":"2026-04-16T07:35:53.576Z","response_time":69,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":"2026-04-16T07:36:56.512Z","updated_at":"2026-04-16T07:36:57.124Z","avatar_url":"https://github.com/ericboehs.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GitHub Issues Viewer\n\nA modern Rails 8.1.0 application for viewing and managing GitHub issues with smart caching and real-time API integration. Browse issues from multiple repositories across GitHub.com and GitHub Enterprise with a GitHub.com-quality UI.\n\n**Status**: ✅ Production-ready with all core features implemented (October 2025)\n\n## Features\n\n### Core Functionality\n\n- **Multi-Repository Support** - Track and view issues from multiple GitHub repositories with flexible URL parsing\n- **Smart Hybrid Caching** - Fast local cache with on-demand API fetching and graceful degradation\n- **GitHub.com Clone UI** - Full-featured issue viewing with labels, assignees, comments, and metadata\n- **Advanced Search \u0026 Filtering** - GitHub query syntax parser with filter dropdowns and keyboard navigation\n- **GitHub Enterprise Support** - Works with both GitHub.com and self-hosted GitHub Enterprise servers\n- **Per-User GitHub Tokens** - Each user connects their own GitHub account with encrypted token storage\n- **Real-Time Sync** - Manual refresh at repository and individual issue level with staleness indicators\n\n### Technical Highlights\n\n- **Component-Based UI** - ViewComponent architecture with reusable GitHub-style components\n- **GitHub-Flavored Markdown** - Full markdown rendering for issue bodies and comments\n- **Dual Search Modes** - Local SQLite search and GitHub API search with automatic mode switching\n- **Comprehensive Testing** - 98.18% line coverage, 91.84% branch coverage (341 tests, 897 assertions)\n- **Dark Mode Support** - Full dark mode throughout the application\n- **Accessibility** - WCAG 2.1 AA compliant with automated accessibility testing\n\n## Tech Stack\n\n### Backend\n- **Rails 8.1.0** with modern asset pipeline (Propshaft)\n- **Ruby 3.4.7**\n- **SQLite3** for all environments including production (multi-database setup)\n- **Octokit 10.0+** for GitHub REST API integration with rate limiting and retries\n- **CommonMarker** for GitHub-flavored markdown rendering\n- **BCrypt** for secure password hashing\n- **Solid Libraries** for database-backed cache, queue, and cable\n\n### Frontend\n- **Hotwire** (Turbo + Stimulus) for interactive features with minimal JavaScript\n- **Tailwind CSS** via CDN for GitHub-style UI\n- **ViewComponent** for reusable GitHub UI components\n- **ImportMap** for JavaScript (no Node.js bundling required)\n- **Custom markdown.css** for GitHub-inspired styling with dark mode\n\n### Testing \u0026 Quality\n- **Minitest** with Mocha for comprehensive testing\n- **SimpleCov** for code coverage analysis (98.18% line, 91.84% branch)\n- **RuboCop** (Rails Omakase configuration)\n- **Brakeman** for security scanning\n- **Capybara + Selenium** for system tests\n- **Axe-core** for accessibility testing\n\n## Getting Started\n\n### Prerequisites\n\n- Ruby 3.4.7\n- Rails 8.1.0+\n- SQLite3\n\n### Installation\n\n1. Clone the repository\n2. Install dependencies:\n  ```bash\n  bin/setup\n  ```\n\n3. Start the development server:\n  ```bash\n  bin/rails server\n  ```\n\n4. Visit `http://localhost:3000` and create an account\n\n### GitHub Token Setup\n\nTo use the application, you'll need a GitHub Personal Access Token:\n\n1. Go to GitHub Settings \u003e Developer Settings \u003e Personal Access Tokens \u003e Fine-grained tokens\n2. Create a new token with these permissions:\n  - **Repository access**: Select repositories you want to view\n  - **Repository permissions**:\n    - Issues: Read-only\n    - Metadata: Read-only\n    - Pull requests: Read-only (if viewing PRs)\n3. Copy the token\n4. In the application, go to your user profile settings\n5. Enter your GitHub token and domain:\n  - Domain: `github.com` (or your GitHub Enterprise domain like `foo.ghe.com`)\n  - Token: Paste your personal access token\n6. Save and start adding repositories!\n\n## Development\n\n### Code Quality\n\nRun the full CI pipeline (formatting, linting, security scan, tests):\n\n```bash\nbin/ci\n```\n\nAuto-fix formatting issues:\n\n```bash\nbin/ci --fix\n```\n\nWatch CI status in real-time:\n\n```bash\nbin/watch-ci\n```\n\n### Testing\n\nRun tests:\n\n```bash\nbin/rails test\n```\n\nGenerate coverage report:\n\n```bash\nbin/coverage\n```\n\n### Code Standards\n\n- **EditorConfig**: UTF-8, LF line endings, 2-space indentation\n- **RuboCop**: Rails Omakase configuration\n- **SimpleCov**: 95% minimum coverage requirement\n- **Conventional Commits**: Structured commit messages\n\n## Architecture\n\n### Database Setup\n\nMulti-database configuration with separate SQLite databases:\n- **Primary database**: Users, repositories, issues, and comments (with caching layer)\n- **Cache database**: Solid Cache for application-level caching\n- **Queue database**: Solid Queue for background jobs\n- **Cable database**: Solid Cable for WebSocket connections\n\n### Caching Strategy\n\n**Hybrid on-demand caching** for optimal performance:\n- Issues and repository data are cached per-user in SQLite\n- On page load, serve cached data if available\n- If cache is cold (no data), fetch from GitHub API in the request\n- Manual refresh button shows staleness (time since last sync)\n- When API errors occur (rate limit, invalid token), show stale cached data with warnings\n\n**Cache keying**: Each user maintains separate caches for their repositories, even if multiple users track the same repo. This simplifies permissions (handled by per-user GitHub tokens).\n\n### GitHub Service Layer\n\nLocated in `app/services/github/`:\n- **ApiClient**: GitHub REST API client with rate limiting, retries, exponential backoff, and search API support\n- **ApiConfiguration**: Centralized configuration for rate limits, retries, and pagination\n- **RepositorySyncService**: Syncs repository metadata from GitHub\n- **IssueSyncService**: Syncs issues with full metadata (labels, assignees, comments); supports single issue or full repo sync\n- **IssueSearchService**: Dual-mode search (local SQLite + GitHub API) with GitHub query syntax parser\n\n### Component System\n\nThe application uses ViewComponent for UI components:\n- **Auth Components**: `Auth::*` for authentication forms and flows\n- **Issue Components**: `IssueCardComponent`, `IssueLabelComponent`, `IssueStateComponent`, `IssueCommentComponent`\n- **Filter Components**: `FilterDropdown::*` namespace for reusable dropdown filters with search and keyboard navigation\n- **Common Components**: `AvatarComponent` (with Gravatar fallback), `AlertComponent`, `UserPageComponent`\n\n### Stimulus Controllers\n\nClient-side JavaScript controllers for enhanced interactivity:\n- **TimeController**: Relative time formatting with hover tooltips\n- **FilterDropdownController**: Keyboard navigation, search, and intelligent positioning for filter dropdowns\n- **AccordionController**: Collapsible sections for UI elements\n\n## Search Syntax\n\nThe application supports GitHub's search syntax for powerful filtering:\n\n- **State filters**: `is:open`, `is:closed`, `state:open`, `state:closed`\n- **Label filters**: `label:bug`, `label:\"needs review\"` (use quotes for labels with spaces)\n- **Assignee filters**: `assignee:username`\n- **Sorting**: `sort:created`, `sort:updated`, `sort:comments` (add `-desc` for descending, e.g., `sort:updated-desc`)\n\nExamples:\n```\nis:open label:bug memory leak\nassignee:alice label:\"high priority\" sort:updated-desc\nstate:closed sort:comments-desc\n```\n\nThe search automatically switches to GitHub API mode when qualifiers are detected, otherwise it uses fast local SQLite search.\n\n## Contributing\n\n1. Follow the existing code style and conventions (Rails Omakase)\n2. Ensure tests pass: `bin/ci`\n3. Maintain test coverage above 95% line, 90% branch\n4. Use conventional commit messages (see CLAUDE.md)\n5. Add tests for all new features\n\nFor detailed development guidelines, see `CLAUDE.md` and `docs/` directory.\n\n## License\n\nThis project is licensed under the [MIT License](https://opensource.org/licenses/MIT).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericboehs%2Fgithub-viewer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fericboehs%2Fgithub-viewer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericboehs%2Fgithub-viewer/lists"}