Skip to content

Commit

Permalink
Move readme documentation on contributing out of the "product documen…
Browse files Browse the repository at this point in the history
…tation" and back into the "repo readme"
  • Loading branch information
mbyrne00 committed Dec 11, 2023
1 parent c006823 commit f31402d
Showing 1 changed file with 54 additions and 0 deletions.
54 changes: 54 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,57 @@ Simplify building NodeJS applications on Google App Engine (GAE)
- [gae-js-firebase-auth](https://mondo-mob.github.io/gae-js-docs/packages/gae-js-firebase-auth.html)
- [gae-js-migrations](https://mondo-mob.github.io/gae-js-docs/packages/gae-js-migrations.html)
- [gae-js-search](https://mondo-mob.github.io/gae-js-docs/packages/gae-js-gae-search.html)

## Contributing

This is a mono-repo using npm workspaces.
Publishing is done using Atlassian Changesets (https://github.com/changesets/changesets).
This helps be consistent with versioning and auto-generates changelogs.

Here's the basic flow:

1. Create one or more changesets

- Once you've made your changes, create a changeset. You can create more than one changeset for a single version.

```
npx changeset
```

- From the cli tool, choose which packages to update and if major/minor/patch update
- Enter summary for changes
- Review and commit files

2. Update package versions

- Based on the changeset configuration - this will automatically version the packages.

```
npx changeset version
```

- Commit changes

3. Build and publish

Would be nice if this was done from CI but for now we do this locally.

- Check you're running a suitable version of node/npm. If not switch and clear out old node_modules.
- Build and publish

```
npm run publish-libs
```

### Adding new packages

There's nothing automated to do this. Essentially you just need to add a new package to `/packages` folder but
these steps should save some time:

- Create new folder in `/packages`. e.g. `/packages/gae-js-new-thing`
- Copy `package.json`, `tsconfig.json`, `tsconfig.prod.json`, `jest.config.json` from one of the existing packages
- Update `package.json` to match desired name, version, dependencies, etc
- Update `tsconfig.json` to match desired project references.
- Create file src/index.ts and export some constant
- Run `npm install` from root folder
- Run `npm run build` from project folder

0 comments on commit f31402d

Please sign in to comment.