Skip to content

Commit

Permalink
Merge branch 'master' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
Balte de Wit committed Sep 2, 2019
2 parents bad75ae + 3dd59aa commit 15f26b3
Show file tree
Hide file tree
Showing 10 changed files with 1,081 additions and 809 deletions.
35 changes: 17 additions & 18 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ jobs:
- attach_workspace:
at: ~/project
- run: yarn install
- run: yarn build
- run: yarn ci
Send Coverage:
<<: *defaults
Expand Down Expand Up @@ -77,10 +78,9 @@ jobs:
- run:
name: Keyscan Github
command: ssh-keyscan -H github.com >> ~/.ssh/known_hosts
- run: git config --global user.email "[email protected]"
- run: git config --global user.name "jesperstarkar"
# - run: yarn release
- run: yarn release:skiptest
- run: git config --global user.email "[email protected]"
- run: git config --global user.name "superflytvab"
- run: yarn release
- run: git push --follow-tags origin HEAD
- persist_to_workspace:
root: .
Expand Down Expand Up @@ -109,28 +109,27 @@ workflows:
- Check for vulnerabilities:
requires:
- Checkout Code
# - Test node-8:
# requires:
# - Checkout Code
# - Send Coverage:
# requires:
# - Check for vulnerabilities
# - Test node-8
# filters:
# branches:
# only:
# - master
- Git Release:
- Test node-8:
requires:
# - Send Coverage
- Checkout Code
- Send Coverage:
requires:
- Check for vulnerabilities
- Test node-8
filters:
branches:
only:
- master
- Git Release:
requires:
- Send Coverage
filters:
branches:
only:
- master
- Build:
requires:
# - Send Coverage
- Send Coverage
- Git Release
filters:
branches:
Expand Down
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,22 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

# [4.7.0](https://github.com/SuperFlyTV/casparcg-connection/compare/4.6.1...4.7.0) (2019-04-11)


### Bug Fixes

* **Validator:** refactor of PositiveNumberValidatorBetween ([1d6f41e](https://github.com/SuperFlyTV/casparcg-connection/commit/1d6f41e))


### Features

* **call:** adds all ffmpeg producer calls ([2edbe9d](https://github.com/SuperFlyTV/casparcg-connection/commit/2edbe9d))
* **call:** Adds SEEK support to call ([1704912](https://github.com/SuperFlyTV/casparcg-connection/commit/1704912)), closes [#5](https://github.com/SuperFlyTV/casparcg-connection/issues/5)
* add support for IN property in PLAY command ([9e059be](https://github.com/SuperFlyTV/casparcg-connection/commit/9e059be))



<a name="4.6.1"></a>
## [4.6.1](https://github.com/SuperFlyTV/casparcg-connection/compare/4.6.0...4.6.1) (2019-01-15)

Expand Down
4 changes: 2 additions & 2 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
module.exports = {
globals: {
'ts-jest': {
tsConfigFile: 'tsconfig.jest.json'
tsConfig: 'tsconfig.jest.json'
}
},
moduleFileExtensions: [
'ts',
'js'
],
transform: {
'^.+\\.(ts|tsx)$': './node_modules/ts-jest/preprocessor.js'
'^.+\\.(ts|tsx)$': 'ts-jest'
},
testMatch: [
'**/__tests__/**/*.spec.(ts|js)'
Expand Down
28 changes: 16 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "casparcg-connection",
"version": "4.6.1",
"version": "4.7.0",
"description": "Node.js Javascript/Typescript library for CasparCG connection and commands.",
"main": "dist/index.js",
"typings": "dist/index.d.ts",
Expand Down Expand Up @@ -71,7 +71,8 @@
"release:skiptest": "yarn reset && yarn docs:publish && yarn changelog",
"reset": "git clean -dfx && git reset --hard && yarn",
"ci": "yarn test && yarn docs:test",
"validate:dependencies": "yarn audit"
"validate:dependencies": "yarn audit && yarn license-validate",
"license-validate": "node-license-validator -p -d --allow-licenses MIT BSD BSD-3-Clause ISC Apache"
},
"scripts-info": {
"info": "Display information about the scripts",
Expand Down Expand Up @@ -106,22 +107,22 @@
"@types/node": "^8.10.0",
"@types/xml2js": "^0.4.2",
"@types/xmlbuilder": "0.0.30",
"codecov": "3.1.0",
"del": "^3.0.0",
"codecov": "3.3.0",
"del": "^4.1.0",
"gh-pages": "^1.0.0",
"jest": "^24.1.0",
"jest": "^24.7.1",
"mkdirp": "^0.5.1",
"node-license-validator": "^1.3.0",
"npm-scripts-info": "^0.3.6",
"npm-scripts-info": "^0.3.9",
"nyc": "^13.3.0",
"opn-cli": "^3.1.0",
"rimraf": "^2.6.2",
"opn-cli": "^4.1.0",
"rimraf": "^2.6.3",
"sleep-ms": "^2.0.1",
"standard-version": "^4.3.0",
"standard-version": "^5.0.2",
"trash-cli": "^1.4.0",
"ts-jest": "^24.0.0",
"tslint": "^5.9.1",
"tslint-config-standard": "^6.0.1",
"ts-jest": "^24.0.2",
"tslint": "^5.15.0",
"tslint-config-standard": "^8.0.1",
"typedoc": "^0.14.2",
"typescript": "^3.3.3333"
},
Expand All @@ -143,6 +144,9 @@
"xml2js": "^0.4.19",
"xmlbuilder": "^9.0.7"
},
"resolutions": {
"typedoc/**/marked": "^0.6.2"
},
"standard-version": {
"message": "chore(release): %s [skip ci]",
"tagPrefix": ""
Expand Down
20 changes: 10 additions & 10 deletions src/CasparCG.ts
Original file line number Diff line number Diff line change
Expand Up @@ -689,7 +689,7 @@ export class CasparCG extends EventEmitter implements ICasparCGConnection, Conne
let command: IAMCPCommand | undefined
try {
if (isIAMCPCommand(commandOrString)) {
command = commandOrString as IAMCPCommand
command = commandOrString
} else { // then it must be a string:
if (AMCP.hasOwnProperty(commandOrString)) {
// @todo: parse out params from commandString, if Params is empty and commandString.split(" ").length > 1
Expand Down Expand Up @@ -1671,7 +1671,7 @@ export class CasparCG extends EventEmitter implements ICasparCGConnection, Conne
* <https://github.com/CasparCG/help/wiki/AMCP-Protocol#THUMBNAIL-LIST>
*/
public thumbnailList(subFolder?: string): Promise<IAMCPCommand> {
return this.do(new AMCP.ThumbnailListCommand({ subFolder: subFolder}))
return this.do(new AMCP.ThumbnailListCommand({ subFolder: subFolder }))
}

/**
Expand Down Expand Up @@ -1706,7 +1706,7 @@ export class CasparCG extends EventEmitter implements ICasparCGConnection, Conne
* <https://github.com/CasparCG/help/wiki/AMCP-Protocol#CLS>
*/
public cls(subFolder?: string): Promise<IAMCPCommand> {
return this.do(new AMCP.ClsCommand({ subFolder: subFolder}))
return this.do(new AMCP.ClsCommand({ subFolder: subFolder }))
}

/**
Expand All @@ -1720,7 +1720,7 @@ export class CasparCG extends EventEmitter implements ICasparCGConnection, Conne
* <https://github.com/CasparCG/help/wiki/AMCP-Protocol#TLS>
*/
public tls(subFolder?: string): Promise<IAMCPCommand> {
return this.do(new AMCP.TlsCommand({ subFolder: subFolder}))
return this.do(new AMCP.TlsCommand({ subFolder: subFolder }))
}

/**
Expand Down Expand Up @@ -2077,15 +2077,15 @@ export class CasparCG extends EventEmitter implements ICasparCGConnection, Conne
*
*/
private get _nextCommand(): { cmd: IAMCPCommand, priority: Priority } | null {
let VO: { cmd: IAMCPCommand, priority: Priority } | null = null
if (this._queuedCommandsHighPriority.length > 0) {
VO = { cmd: this._queuedCommandsHighPriority[0]!, priority: Priority.HIGH }
return { cmd: this._queuedCommandsHighPriority[0], priority: Priority.HIGH }
} else if (this._queuedCommands.length > 0) {
VO = { cmd: this._queuedCommands[0]!, priority: Priority.NORMAL }
return { cmd: this._queuedCommands[0], priority: Priority.NORMAL }
} else if (this._queuedCommandsLowPriority.length > 0) {
VO = { cmd: this._queuedCommandsLowPriority[0]!, priority: Priority.LOW }
return { cmd: this._queuedCommandsLowPriority[0], priority: Priority.LOW }
} else {
return null
}
return VO
}

/**
Expand Down Expand Up @@ -2260,7 +2260,7 @@ export class CasparCG extends EventEmitter implements ICasparCGConnection, Conne
this._log(`Received a response from an unknown command with token ${socketResponse.token}`)
return
}
currentCommand = (this._sentCommands[socketResponse.token])!
currentCommand = this._sentCommands[socketResponse.token]
delete this._sentCommands[socketResponse.token]
} else {
if (Object.keys(this._sentCommands).length === 0) {
Expand Down
Loading

0 comments on commit 15f26b3

Please sign in to comment.