{"id":17911624,"url":"https://github.com/prezha/pubsubctl","last_synced_at":"2025-04-03T06:43:52.953Z","repository":{"id":90017682,"uuid":"600462409","full_name":"prezha/pubsubctl","owner":"prezha","description":"pubsubctl is a basic Google Cloud Platform Pub/Sub [Emulator] CLI","archived":false,"fork":false,"pushed_at":"2023-02-13T23:21:28.000Z","size":20,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-02-08T20:30:40.668Z","etag":null,"topics":["gcloud","gcloud-pubsub","gcloud-sdk","google-cloud-pubsub","pubsub","pubsub-emulator","pubsubclient"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/prezha.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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-02-11T15:17:01.000Z","updated_at":"2023-06-18T00:38:27.000Z","dependencies_parsed_at":"2023-03-17T19:01:19.564Z","dependency_job_id":null,"html_url":"https://github.com/prezha/pubsubctl","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prezha%2Fpubsubctl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prezha%2Fpubsubctl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prezha%2Fpubsubctl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prezha%2Fpubsubctl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/prezha","download_url":"https://codeload.github.com/prezha/pubsubctl/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246952273,"owners_count":20859811,"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":["gcloud","gcloud-pubsub","gcloud-sdk","google-cloud-pubsub","pubsub","pubsub-emulator","pubsubclient"],"created_at":"2024-10-28T19:39:33.377Z","updated_at":"2025-04-03T06:43:52.936Z","avatar_url":"https://github.com/prezha.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pubsubctl\npubsubctl is a basic Google Pub/Sub Emulator/Cloud CLI\n\n## quick start - basic _emulator_ usage\n1. start pubsub emulator in a separate session (to monitor logs)\n - using the gCloud Docker image:\n\u003e docker run --rm -ti -p 127.0.0.1:8085:8085 gcr.io/google.com/cloudsdktool/google-cloud-cli:latest gcloud beta emulators pubsub start --host-port=0.0.0.0:8085 --project=my-project --log-http --verbosity=debug --user-output-enabled\n - using the Google Cloud CLI:\n\u003e gcloud beta emulators pubsub start --host-port=127.0.0.1:8085 --project=my-project --log-http --verbosity=debug --user-output-enabled\n2. set the environment variables\n\u003e export PUBSUB_EMULATOR_HOST=127.0.0.1:8085\n\n\u003e export PUBSUB_PROJECT_ID=my-project\n3. create topic and subscription\n\u003e pubsubctl create -t my-topic -s my-sub\n4. publish a message to topic\n\u003e pubsubctl publish -t my-topic -m \"my message\"\n5. receive message from subscription\n\u003e pubsubctl receive -s my-sub\n\n## getting help\n```\n$ ./pubsubctl --help\npubsubctl v0.6.5-beta\n        pubsubctl is a basic Google Cloud Platform Pub/Sub [Emulator] CLI\n\nUsage:\n  pubsubctl [command]\n\nAvailable Commands:\n  completion  Generate the autocompletion script for the specified shell\n  create      create topic/subscription\n  delete      delete topic and/or subscription\n  help        Help about any command\n  list        list topics and/or subscriptions\n  publish     publish message\n  receive     receive message\n  test        test pubsub emulator\n\nFlags:\n      --cloud                 use cloud pubsub instead of the emulator\n  -h, --help                  help for pubsubctl\n      --host string           [address:port] of the emulator host, defaulting to PUBSUB_EMULATOR_HOST environment variable value (if set), ignored if 'cloud' flag is also set (default \"localhost:8085\")\n  -p, --project string        pubsub project, defaulting to PUBSUB_PROJECT_ID environment variable value (if set) (default \"default\")\n  -s, --subscription string   pubsub subscription\n      --timeout duration      time to wait for command execution (value \u003c=0 disables timeout) (default 5s)\n  -t, --topic string          pubsub topic\n\nUse \"pubsubctl [command] --help\" for more information about a command.\n```\n\n## build from source\n - linux\n\u003e GOOS=linux GOARCH=amd64 go build -ldflags=\"-w -s\" -o pubsubctl\n - macos\n\u003e GOOS=darwin GOARCH=arm64 go build -ldflags=\"-w -s\" -o pubsubctl\n\n## references\n - https://cloud.google.com/pubsub/docs/overview\n - https://cloud.google.com/pubsub/docs/emulator\n - https://cloud.google.com/sdk/gcloud/reference/beta/emulators/pubsub\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprezha%2Fpubsubctl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprezha%2Fpubsubctl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprezha%2Fpubsubctl/lists"}