{"id":18890045,"url":"https://github.com/shipshapecode/swach","last_synced_at":"2026-01-27T22:30:17.280Z","repository":{"id":61301934,"uuid":"218437351","full_name":"shipshapecode/swach","owner":"shipshapecode","description":"A robust color management tool for the modern age","archived":false,"fork":false,"pushed_at":"2024-05-22T12:02:43.000Z","size":22154,"stargazers_count":47,"open_issues_count":12,"forks_count":3,"subscribers_count":4,"default_branch":"main","last_synced_at":"2024-05-22T12:56:33.587Z","etag":null,"topics":["ember","hacktoberfest"],"latest_commit_sha":null,"homepage":"https://swach.io/","language":"TypeScript","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/shipshapecode.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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}},"created_at":"2019-10-30T03:38:43.000Z","updated_at":"2024-05-22T11:59:06.000Z","dependencies_parsed_at":"2023-09-28T02:25:52.962Z","dependency_job_id":"72d09251-f2ec-4255-8dc6-53f2e0dece57","html_url":"https://github.com/shipshapecode/swach","commit_stats":null,"previous_names":[],"tags_count":271,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shipshapecode%2Fswach","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shipshapecode%2Fswach/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shipshapecode%2Fswach/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shipshapecode%2Fswach/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shipshapecode","download_url":"https://codeload.github.com/shipshapecode/swach/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248978558,"owners_count":21192814,"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":["ember","hacktoberfest"],"created_at":"2024-11-08T07:52:12.116Z","updated_at":"2026-01-27T22:30:17.268Z","avatar_url":"https://github.com/shipshapecode.png","language":"TypeScript","funding_links":[],"categories":["TypeScript"],"sub_categories":[],"readme":"# Swach\n\n[![Linting](https://github.com/shipshapecode/swach/actions/workflows/lint.yml/badge.svg)](https://github.com/shipshapecode/swach/actions/workflows/lint.yml)\n[![Ember](https://github.com/shipshapecode/swach/actions/workflows/ember.yml/badge.svg)](https://github.com/shipshapecode/swach/actions/workflows/ember.yml)\n[![Electron](https://github.com/shipshapecode/swach/actions/workflows/electron.yml/badge.svg)](https://github.com/shipshapecode/swach/actions/workflows/electron.yml)\n\nSwach is a modern color palette manager.\n\n\u003ca href=\"https://swach.io/\"\u003e\n  \u003cimg width=\"1728\" \n    alt=\"Swach homepage showing the app running.\" \n    src=\"https://user-images.githubusercontent.com/2640861/194164254-4504e8f3-497c-43b2-8eb9-4bcacd1a69c8.png\"\n  /\u003e\n\u003c/a\u003e\n\n**[Swach is built and maintained by Ship Shape. Contact us for web and native app development services.](https://shipshape.io/)**\n\n## Prerequisites\n\nYou will need the following things properly installed on your computer.\n\n- [Git](https://git-scm.com/)\n- [Node.js](https://nodejs.org/)\n- [pnpm](https://pnpm.io/)\n- [Ember CLI](https://ember-cli.com/)\n- [Google Chrome](https://google.com/chrome/)\n- [Rust](https://www.rust-lang.org/) (for building the hue-hunter color picker)\n\n### Linux System Requirements\n\nOn Linux, the color picker functionality requires additional system libraries and tools. These dependencies are automatically installed when using the `.deb` package, but if building from source, ensure you have:\n\n```bash\n# Debian / Ubuntu\nsudo apt-get install libxcb1 libxrandr2 libdbus-1-3\n\n# For Wayland (recommended)\nsudo apt-get install grim\n\n# For X11 (fallback)\nsudo apt-get install imagemagick xdotool\n# OR\nsudo apt-get install scrot xdotool\n\n# Alpine\nsudo apk add libxcb libxrandr dbus grim\n```\n\n**Wayland Users:** The color picker uses PipeWire + XDG Portal on Wayland (no external tools needed). See the [hue-hunter README](https://github.com/RobbieTheWagner/hue-hunter) for more details.\n\n## Installation\n\n- `git clone \u003crepository-url\u003e` this repository\n- `cd swach`\n- `pnpm install`\n\n## Architecture\n\nSwach is built using a modern stack that combines Ember.js with Electron:\n\n- **Ember.js** - Frontend framework using Embroider (modern build system)\n- **Vite** - Fast build tool used by Embroider for development and production builds\n- **Electron Forge** - Complete toolchain for building, packaging, and distributing Electron apps\n- **TypeScript** - Type safety across the entire codebase\n\n### Build System Integration\n\nThe build system works as follows:\n\n1. **Ember + Embroider + Vite**: The Ember app is built using Embroider's Vite integration (`@embroider/vite`), which provides fast hot-reload in development and optimized production builds.\n\n2. **Electron Forge + Vite Plugin**: Electron Forge uses its Vite plugin to:\n   - Build the main process (`electron-app/src/main.ts`)\n   - Build the preload script (`electron-app/src/preload.ts`)\n   - Build the renderer process (the Ember app) using the Embroider Vite config\n\n3. **Environment Configuration**: The app detects when it's running in Electron vs web by checking the `EMBER_CLI_ELECTRON` environment variable, which affects:\n   - Router location type (`hash` for Electron, `history` for web)\n   - Root URL (`''` for Electron, `'/'` for web)\n   - Asset loading strategies\n\n## Running / Development\n\n### Electron Development\n\n- `pnpm start:electron` - Starts Electron with hot-reload pointing to Vite dev server\n- The Ember app runs on `http://localhost:4200` and Electron loads it via the dev server\n\n### Web Development\n\n- `pnpm start` - Starts just the Ember app for web development\n- Visit your app at [http://localhost:4200](http://localhost:4200).\n- Visit your tests at [http://localhost:4200/tests](http://localhost:4200/tests).\n\n### Running Tests\n\n- `ember test`\n- `ember test --server`\n\n### Linting\n\n- `pnpm lint`\n- `pnpm lint:fix`\n\n### Building / Packaging\n\n#### Testing\n\n- `pnpm test:ember` - Builds and runs Ember tests\n- `pnpm test:electron` - Builds and packages Electron, then runs Electron-specific tests\n\n#### Production Electron Builds\n\n- `pnpm package` - Packages the Electron app for the current platform (sets `EMBER_CLI_ELECTRON=true`)\n- `pnpm make` - Creates distributable packages (DMG, deb, etc.) for the current platform (sets `EMBER_CLI_ELECTRON=true`)\n\nThe production builds work by:\n\n1. Electron Forge builds the Ember renderer using Vite with `EMBER_CLI_ELECTRON=true`\n2. This enables hash routing and proper asset paths for file-based loading\n3. The main and preload processes are built and bundled\n4. Everything is packaged into the final Electron app with proper code signing and notarization\n\n## Releasing\n\n- Bump the version with:\n\n```bash\nrelease-it\n```\n\nChoose the appropriate major, minor, patch, beta, etc version in the prompt.\n\nGitHub actions should then take that new tag and build and release automatically.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshipshapecode%2Fswach","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshipshapecode%2Fswach","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshipshapecode%2Fswach/lists"}