{"id":18585084,"url":"https://github.com/nallenscott/homebrew-hops","last_synced_at":"2025-04-30T19:32:51.934Z","repository":{"id":174256482,"uuid":"651304731","full_name":"nallenscott/homebrew-hops","owner":"nallenscott","description":"Use Gist to sync Homebrew formulae, casks, and vscode extensions across multiple machines 🍻","archived":false,"fork":false,"pushed_at":"2023-06-11T17:30:00.000Z","size":225,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-30T19:13:09.124Z","etag":null,"topics":["casks","formulae","gist","homebrew","homebrew-tap","sync","vscode-extensions"],"latest_commit_sha":null,"homepage":"","language":"Shell","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/nallenscott.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}},"created_at":"2023-06-09T00:51:39.000Z","updated_at":"2024-10-26T22:12:51.000Z","dependencies_parsed_at":"2023-07-03T10:31:36.590Z","dependency_job_id":null,"html_url":"https://github.com/nallenscott/homebrew-hops","commit_stats":null,"previous_names":["nallenscott/homebrew-hops"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nallenscott%2Fhomebrew-hops","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nallenscott%2Fhomebrew-hops/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nallenscott%2Fhomebrew-hops/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nallenscott%2Fhomebrew-hops/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nallenscott","download_url":"https://codeload.github.com/nallenscott/homebrew-hops/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251769415,"owners_count":21640895,"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":["casks","formulae","gist","homebrew","homebrew-tap","sync","vscode-extensions"],"created_at":"2024-11-07T00:30:20.034Z","updated_at":"2025-04-30T19:32:51.895Z","avatar_url":"https://github.com/nallenscott.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n  \u003cimg src=\"tmpl/hops.png\" width=240 alt=\"\"\u003e\u003cbr\u003e\n  homebrew-hops\u003cbr\u003e\n\u003c/h1\u003e\n\n\u003e **Table of contents**\n\u003e - [Installation](#installation)\n\u003e - [Quick start](#quick-start)\n\u003e - [Dependencies](#dependencies)\n\u003e - [Authentication](#authentication)\n\u003e - [Environment](#environment)\n\u003e   - [Hopsfile](#hopsfile)\n\u003e   - [Brewfile](#brewfile)\n\u003e - [Commands](#commands)\n\u003e   - [`init`](#init)\n\u003e   - [`sync`](#sync)\n\nHops allows you to sync Homebrew across multiple machines by using a Gist backend to store the state of your taps, formulae, casks, and vscode extensions. Use it to keep your work and home machines in sync, or to quickly get a new machine up and running.\n\n## Installation\n\nHomebrew will pull the latest version of hops every time you run `brew update`. To install:\n\n`brew tap nallenscott/hops`\n\n## Quick start\n\n1. To sync a machine with the backend, run `init` with a personal access token, and then `sync`.\n```sh\n# hostname: home_machine\n$ brew tap nallenscott/hops\n$ brew hops init --token ghp_...\n$ brew hops sync\n```\n\n2. To sync Homebrew with another machine, run `sync` with the hostname of the target machine.\n```sh\n# hostname: work_machine\n$ brew tap nallenscott/hops\n$ brew hops init --token ghp_... --gist aad9...\n$ brew hops sync --host home_machine\n```\n\n## Dependencies\n\nHops use [`gh`](https://cli.github.com/manual/) to interact with the GitHub API. Hops will check for it and prompt you to install it if it's missing.\n\n## Authentication\n\nHops uses a personal access token to authenticate with GitHub. You can create a new token [here](https://github.com/settings/tokens). The minimum required scopes are: `repo`, `read:org`, `gist`. The `repo` and `read:org` scopes are required by `gh`.\n\n## Environment\n\n### Hopsfile\n\nThe first time `init` is run, hops will create a new Gist named `.hops` and store the Gist ID in `~/.hops/Hopsfile`. The Gist URL will be printed to the console after `init` completes.\n\n\u003e `~/.hops/backend.env`\n```env\nGITHUB_TOKEN=\"ghp_5bbd682cfbbe427297e1360fa9fd02f2einA\"\nGIST_ID=\"aad9e4b592a34fefb29515475244edfe\"\nGIST_URL=\"https://gist.github.com/foob/aad9e4b592a34fefb29515475244edfe\"\n```\n\n### Brewfile\n\nRunning `sync` will update the Brewfile with the currently installed taps, formulae, casks, and vscode extensions. The local copy is stored in `~/.hops/Brewfile`. It's also uploaded to the Gist backend using the hostname of the machine as the filename.\n\n\u003e `~/.hops/Brewfile`\n```txt\ntap \"aws/tap\"\ntap \"cargo-lambda/cargo-lambda\"\nbrew \"sqlite\"\nbrew \"python@3.11\"\ncask \"discord\"\ncask \"docker\"\nvscode \"golang.go\"\nvscode \"hashicorp.hcl\"\n```\n\n## Commands\n\n### `init`\n\nCreates a new Gist and stores the Gist ID and GitHub token in `~/hops/Hopsfile`.\n\n```sh\n$ hops init [options]\n```\n\n**Options**\n\n| Name | Description |\n| :--- | :--- |\n| `--token` | A personal access token with gist permissions [1] |\n| `--gist` | The ID of an existing Gist to use as the backend |\n\u003e [1] Requires the `repo`, `read:org`, and `gist` scopes.\n\n### `sync`\n\nUpdates the Brewfile with the currently installed taps, formulae, casks, and vscode extensions.\n\n```sh\n$ hops sync [options]\n```\n\n**Options**\n\n| Name | Description |\n| :--- | :--- |\n| `--host` | The hostname of another machine to sync with [1] |\n\u003e [1] The other machine must have the same Gist backend.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnallenscott%2Fhomebrew-hops","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnallenscott%2Fhomebrew-hops","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnallenscott%2Fhomebrew-hops/lists"}