Skip to content

Commit

Permalink
Merge pull request #44 from dsdavis4/small_adjustments
Browse files Browse the repository at this point in the history
Small adjustments
  • Loading branch information
dsdavis4 authored Mar 27, 2024
2 parents 590e3f1 + 66bce64 commit 5ceb081
Show file tree
Hide file tree
Showing 7 changed files with 42 additions and 7 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/check-version.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Check that package version changed

on:
pull_request:
types:
- opened
- reopened
- edited
- synchronize

jobs:
check-version:
runs-on: ubuntu-latest

steps:
- name: Check out repository code
uses: actions/checkout@v3

- name: Set up Node.js
uses: actions/setup-node@v3
with:
cache: npm
cache-dependency-path: package-lock.json

- name: Check version
id: check
uses: EndBug/version-check@v2
with:
file-url: https://unpkg.com/dyna-record@latest/package.json
static-checking: localIsNew

- name: Fail if package.json version has not changed
if: steps.check.outputs.changed == 'false'
run: |
echo "package.json version has not changed. Run 'npm version <patch|minor|major>'' and push changes."
exit 1
1 change: 0 additions & 1 deletion .github/workflows/eslint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: "18.x"
cache: npm
cache-dependency-path: package-lock.json

Expand Down
1 change: 0 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ jobs:
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: "18.x"
cache: npm
cache-dependency-path: package-lock.json

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Entities in Dyna-Record represent your DynamoDB table structures and relationshi

[Docs](https://dyna-record.com/functions/Table.html)

Create a table class that extends [DynaRecord base class](https://dyna-record.com/classes/default.html) and us decorated with the [Table decorator](https://dyna-record.com/functions/Table.html). At a minimum, the table class define the [PartitionKeyAttribute](https://dyna-record.com/functions/PartitionKeyAttribute.html) and [SortKeyAttribute](https://dyna-record.com/functions/SortKeyAttribute.html).
Create a table class that extends [DynaRecord base class](https://dyna-record.com/classes/default.html) and is decorated with the [Table decorator](https://dyna-record.com/functions/Table.html). At a minimum, the table class must define the [PartitionKeyAttribute](https://dyna-record.com/functions/PartitionKeyAttribute.html) and [SortKeyAttribute](https://dyna-record.com/functions/SortKeyAttribute.html).

#### Basic usage

Expand Down Expand Up @@ -357,7 +357,7 @@ const grade: Grade = await Grade.create({

#### Error handling

The method is designed to throw errors under various conditions, such as transaction cancellation due to failed conditional checks. For instance, if you attempt to create a `Grade` for an `Assignment` that already has one, the method throws a `TransactionWriteFailedError`.
The method is designed to throw errors under various conditions, such as transaction cancellation due to failed conditional checks. For instance, if you attempt to create a `Grade` for an `Assignment` that already has one, the method throws a [TransactionWriteFailedError](https://dyna-record.com/classes/TransactionWriteFailedError.html).

#### Notes

Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dyna-record",
"version": "0.0.15",
"version": "0.0.16",
"description": "Typescript Object Relational Mapper (ORM) for Dynamo",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down
1 change: 1 addition & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ export * from "./types";
export * from "./decorators";
export * from "./errors";
export * from "./relationships";
export * from "./dynamo-utils/errors";

0 comments on commit 5ceb081

Please sign in to comment.