Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:

strategy:
matrix:
node-version: [16.x]
node-version: [18.x,20.x]

steps:
- uses: actions/checkout@v2
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: 16
node-version: '18.x'
- name: Install dependencies
run: npm install
- name: Build
Expand All @@ -38,7 +38,7 @@ jobs:
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: 16
node-version: '18.x'
- name: Install dependencies
run: npm install
- name: Download dist
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/sast-scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: SAST Scan
on:
pull_request:
types: [opened, synchronize, reopened]
jobs:
security:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Horusec Scan
run: docker run -v /var/run/docker.sock:/var/run/docker.sock -v $(pwd):/src horuszup/horusec-cli:latest horusec start -p /src -P $(pwd)
11 changes: 11 additions & 0 deletions .github/workflows/secrets-scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Secrets Scan
on:
pull_request:
types: [opened, synchronize, reopened]
jobs:
security:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Gittyleaks
uses: gupy-io/gittyleaks-action@v0.1
8 changes: 4 additions & 4 deletions package-lock.json

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

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"name": "contentstack-cli-tsgen",
"description": "Generate TypeScript typings from a Stack.",
"version": "2.1.3",
"version": "2.1.4",
"author": "Michael Davis",
"bugs": "https://github.com/Contentstack-Solutions/contentstack-cli-tsgen/issues",
"dependencies": {
"@contentstack/cli-command": "^1.2.7",
"@contentstack/cli-utilities": "^1.4.3",
"@contentstack/cli-command": "^1.2.9",
"@contentstack/cli-utilities": "^1.4.5",
"lodash": "^4.17.20",
"prettier": "^2.0.5",
"tslib": "^1.13.0"
Expand Down
2 changes: 2 additions & 0 deletions src/lib/tsgen/factory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,8 @@ export default function (userOptions: TSGenOptions) {
field.reference_to.forEach(v => {
references.push(name_type(v))
})
} else {
references.push(name_type(field.reference_to))
}

return ['(', references.join(' | '), ')', '[]'].join('')
Expand Down