lib/polyn/templates/README.md in polyn-cli-0.1.3 vs lib/polyn/templates/README.md in polyn-cli-0.1.4
- old
+ new
@@ -1,40 +1,39 @@
# Polyn Events Repository
This repository contains all of the events and terraform resources for the Polyn services
environment.
-## Development Setup
-
1. Install [Ruby](https://github.com/asdf-vm/asdf-ruby)
-2. Install Terraform. For M1 Macs, [download the AMD64 version](https://www.terraform.io/downloads)
+2. Install bundler `gem install bundler`
+3. Install dependencies `bundle install`
+4. Install Terraform. For M1 Macs, [download the AMD64 version](https://www.terraform.io/downloads)
rather than using Homebrew to install Terraform.
-3. Ensure Docker & Docker Compose is installed
-4. [Install the Polyn CLI](https://github.com/SpiffInc/polyn-cli)
-5. Call `polyn tf_init` if this is the first time using terraform in the codebase.
-6. Call `polyn up`. By default this will run in `development` mode, which will start the NATS
+5. Ensure Docker & Docker Compose is installed
+6. Call `bundle exec polyn tf_init` if this is the first time using terraform in the codebase.
+7. Call `bundle exec polyn up`. By default this will run in `development` mode, which will start the NATS
server, configure it via Terraform, and update the Polyn Event Registry.
### Running NATS locally
-`polyn up` will use run a Docker container for you if one is not already running. Alternatively, you can run `nats-server` yourself locally if you prefer.
+`bundle exec polyn up` will use run a Docker container for you if one is not already running. Alternatively, you can run `nats-server` yourself locally if you prefer.
## Naming Conventions
See the Protocol Documentation for [Naming Conventions](https://github.com/SpiffInc/polyn-protocol/blob/main/NAMING_CONVENTIONS.md)
## Streams
-Each stream should have its own configuration file under `./tf` . Run `polyn gen:stream <stream_name>` to generate a new configuration file for a stream
+Each stream should have its own configuration file under `./tf`. Run `bundle exec polyn gen:stream <stream_name>` to generate a new configuration file for a stream
## Consumers
-Run `polyn gen:consumer <stream_name> <destination_name> <event_type>` to generate new configuration for a consumer of a stream. It will be included in the same file as the stream configuration.
+Run `bundle exec polyn gen:consumer <stream_name> <destination_name> <event_type>` to generate new configuration for a consumer of a stream. It will be included in the same file as the stream configuration.
## Event Schemas
-Run `polyn gen:schema <event_type>` to generate a new JSON Schema for an event
+Run `bundle exec polyn gen:schema <event_type>` to generate a new JSON Schema for an event
All the schemas for your events should live in the `./events` directory.
The name of your schema file should be the same as your event, but with `.json` at the end.
So if you have an event called `widgets.created.v1` you would create a schema file called `widgets.created.v1.json` in the `./events` directory.
Every schema should be a valid [JSON Schema](https://json-schema.org/) document.
@@ -43,10 +42,10 @@
### Subdirectories
If you'd like to organize your events by team ownership or some other convention, you can use subdirectories to do so. The full event type should still be part of the file name. You should also ensure there are not duplicate event types in different directories as only one schema can be defined per event type.
-You can generate a schema in a subdirectory like this: `polyn gen:schema some/nested/dir/widgets.created.v1`
+You can generate a schema in a subdirectory like this: `bundle exec polyn gen:schema some/nested/dir/widgets.created.v1`
## Schema Versioning
### New Event
\ No newline at end of file