Skip to content
This repository was archived by the owner on Jan 15, 2025. It is now read-only.

Commit 0d2e363

Browse files
authored
Merge pull request #258 from christopheranderson/chrande/license-fixes
Add license header rules to tslint
2 parents 83fcbb2 + 98ad2b1 commit 0d2e363

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+369
-16
lines changed

packages/chatdown/src/commands/chatdown.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
import {flags} from '@oclif/command'
27
import {CLIError, Command, utils} from '@microsoft/bf-cli-command'
38
const chalk = require('chalk')

packages/chatdown/src/index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,6 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
export default {}

packages/chatdown/tslint.json

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,15 @@
22
"extends": "@oclif/tslint",
33
"rules": {
44
"ordered-imports": [false],
5-
"object-literal-sort-keys": [false]
5+
"object-literal-sort-keys": [false],
6+
"file-header": [
7+
true,
8+
{
9+
"match": "Copyright \\(c\\) Microsoft Corporation\\.*",
10+
"allow-single-line-comments": false,
11+
"default": "Copyright (c) Microsoft Corporation. All rights reserved.\nLicensed under the MIT License.",
12+
"enforce-trailing-newline": false
13+
}
14+
]
615
}
716
}

packages/cli/src/hooks/init/inithook.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
import {Hook} from '@oclif/config'
27
import cli from 'cli-ux'
38
import * as fs from 'fs-extra'

packages/cli/src/index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,6 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
export {run} from '@oclif/command'

packages/cli/tslint.json

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
11
{
2-
"extends": "@oclif/tslint"
2+
"extends": "@oclif/tslint",
3+
"rules": {
4+
"ordered-imports": [false],
5+
"object-literal-sort-keys": [false],
6+
"file-header": [
7+
true,
8+
{
9+
"match": "Copyright \\(c\\) Microsoft Corporation\\.*",
10+
"allow-single-line-comments": false,
11+
"default": "Copyright (c) Microsoft Corporation. All rights reserved.\nLicensed under the MIT License.",
12+
"enforce-trailing-newline": false
13+
}
14+
]
15+
}
316
}

packages/command/src/clierror.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
export class CLIError extends Error {
27
constructor(error: string | Error) {
38
const message = error instanceof Error ? error.message : error

packages/command/src/command.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
// tslint:disable:object-curly-spacing ordered-imports
27

38
import { Command as Base } from '@oclif/command'

packages/command/src/index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
import {CLIError, Command, flags} from './command'
27
import utils from './utils'
38
export {CLIError, Command, flags, utils}

packages/command/src/readpipeddata.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
/*!
2+
* Copyright (c) Microsoft Corporation. All rights reserved.
3+
* Licensed under the MIT License.
4+
*/
5+
16
const ReadPipedStdin = {
27
read: async () => {
38
return new Promise<string>(async (resolve, reject) => {

0 commit comments

Comments
 (0)