Skip to content

Commit

Permalink
Merge hotfix release branch back in main (microsoft#1193)
Browse files Browse the repository at this point in the history
  • Loading branch information
timotheeguerin authored Oct 20, 2022
1 parent 08502ef commit 3676818
Show file tree
Hide file tree
Showing 20 changed files with 55 additions and 22 deletions.
3 changes: 3 additions & 0 deletions eng/pipelines/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

trigger:
- main
# For patch releases
- release/*

pr: none

jobs:
Expand Down
1 change: 1 addition & 0 deletions eng/pipelines/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ trigger:
- main
pr:
- main
- release/*

jobs:
- job: Build_And_Test
Expand Down
2 changes: 1 addition & 1 deletion eng/pipelines/pull-request-consistency.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ steps:
displayName: Install JavaScript Dependencies

- script: node common/scripts/install-run-rush.js change -v
condition: and(succeeded(), eq(startsWith(variables['System.PullRequest.SourceBranch'], 'publish/'), false))
condition: and(succeeded(), not(or(startsWith(variables['System.PullRequest.SourceBranch'], 'publish/'), startsWith(variables['System.PullRequest.SourceBranch'], 'backmerge/'))))
displayName: Check that changelog has been provided

- script: node common/scripts/install-run-rush.js publish --apply && node eng/scripts/check-for-changed-files.js publish
Expand Down
2 changes: 1 addition & 1 deletion packages/bundler/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"!dist/test/**"
],
"dependencies": {
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@rollup/plugin-virtual": "~2.1.0",
"@rollup/plugin-commonjs": "~22.0.2",
"@rollup/plugin-json": "~4.1.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/cadl-vscode/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@
"@types/mocha": "~9.1.0",
"@types/node": "~16.0.3",
"@types/vscode": "~1.53.0",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/eslint-config-cadl": "~0.4.1",
"@cadl-lang/internal-build-utils": "~0.3.1",
"eslint": "^8.12.0",
Expand Down
12 changes: 12 additions & 0 deletions packages/compiler/CHANGELOG.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,18 @@
{
"name": "@cadl-lang/compiler",
"entries": [
{
"version": "0.36.1",
"tag": "@cadl-lang/compiler_v0.36.1",
"date": "Wed, 19 Oct 2022 19:36:13 GMT",
"comments": {
"patch": [
{
"comment": "**Fix** augment decorators can be applied on namespace"
}
]
}
},
{
"version": "0.36.0",
"tag": "@cadl-lang/compiler_v0.36.0",
Expand Down
9 changes: 8 additions & 1 deletion packages/compiler/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# Change Log - @cadl-lang/compiler

This log was last generated on Wed, 12 Oct 2022 21:12:35 GMT and should not be manually modified.
This log was last generated on Wed, 19 Oct 2022 19:36:13 GMT and should not be manually modified.

## 0.36.1
Wed, 19 Oct 2022 19:36:13 GMT

### Patches

- **Fix** augment decorators can be applied on namespace

## 0.36.0
Wed, 12 Oct 2022 21:12:35 GMT
Expand Down
10 changes: 9 additions & 1 deletion packages/compiler/core/checker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,15 @@ export function createChecker(program: Program): Checker {
for (const decNode of augmentDecorators) {
const ref = resolveTypeReference(decNode.targetType, undefined);
if (ref) {
if (ref.flags & SymbolFlags.LateBound) {
if (ref.flags & SymbolFlags.Namespace) {
const decApp = checkDecorator(decNode, undefined);
if (decApp) {
const links = getSymbolLinks(getMergedSymbol(ref));
const type: Type & DecoratedType = links.type! as any;
type.decorators.push(decApp);
applyDecoratorToType(program, decApp, type);
}
} else if (ref.flags & SymbolFlags.LateBound) {
const decApp = checkDecorator(decNode, undefined);
if (decApp) {
const type: Type & DecoratedType = ref.type! as any;
Expand Down
2 changes: 1 addition & 1 deletion packages/compiler/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cadl-lang/compiler",
"version": "0.36.0",
"version": "0.36.1",
"description": "Cadl Compiler Preview",
"author": "Microsoft Corporation",
"license": "MIT",
Expand Down
2 changes: 2 additions & 0 deletions packages/compiler/test/checker/augment-decorators.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,8 @@ describe("compiler: checker: augment decorators", () => {
strictEqual(customName, "FooCustom");
}

it("namespace", () => expectTarget(`@test("target") namespace Foo {}`, "Foo"));

it("model", () => expectTarget(`@test("target") model Foo {}`, "Foo"));
it("model property", () =>
expectTarget(
Expand Down
4 changes: 2 additions & 2 deletions packages/html-program-viewer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"!dist/test/**"
],
"peerDependencies": {
"@cadl-lang/compiler": "~0.36.0"
"@cadl-lang/compiler": "~0.36.1"
},
"dependencies": {
"prettier": "~2.7.1",
Expand All @@ -66,7 +66,7 @@
"@types/prettier": "2.6.0",
"@types/react": "~18.0.5",
"@types/react-dom": "~18.0.1",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/eslint-config-cadl": "~0.4.1",
"@babel/core": "^7.0.0",
"eslint": "^8.12.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/library-linter/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,12 @@
"!dist/test/**"
],
"peerDependencies": {
"@cadl-lang/compiler": "~0.36.0"
"@cadl-lang/compiler": "~0.36.1"
},
"devDependencies": {
"@types/mocha": "~9.1.0",
"@types/node": "~16.0.3",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/eslint-config-cadl": "~0.4.1",
"eslint": "^8.12.0",
"mocha": "~9.2.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/lint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,12 +50,12 @@
"!dist/test/**"
],
"peerDependencies": {
"@cadl-lang/compiler": "~0.36.0"
"@cadl-lang/compiler": "~0.36.1"
},
"devDependencies": {
"@types/mocha": "~9.1.0",
"@types/node": "~16.0.3",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/eslint-config-cadl": "~0.4.1",
"@cadl-lang/eslint-plugin": "~0.1.1",
"eslint": "^8.12.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/openapi/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,13 @@
"!dist/test/**"
],
"peerDependencies": {
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/rest": "~0.18.0"
},
"devDependencies": {
"@types/mocha": "~9.1.0",
"@types/node": "~16.0.3",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/rest": "~0.18.0",
"@cadl-lang/eslint-config-cadl": "~0.4.1",
"@cadl-lang/library-linter": "~0.2.1",
Expand Down
4 changes: 2 additions & 2 deletions packages/openapi3/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,14 @@
],
"peerDependencies": {
"@cadl-lang/versioning": "~0.9.0",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/rest": "~0.18.0",
"@cadl-lang/openapi": "~0.13.0"
},
"devDependencies": {
"@types/mocha": "~9.1.0",
"@types/node": "~16.0.3",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/rest": "~0.18.0",
"@cadl-lang/openapi": "~0.13.0",
"@cadl-lang/versioning": "~0.9.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/playground/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
],
"dependencies": {
"@cadl-lang/versioning": "~0.9.0",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/rest": "~0.18.0",
"@cadl-lang/openapi3": "~0.16.0",
"@cadl-lang/openapi": "~0.13.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/prettier-plugin-cadl/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"prettier": "~2.7.1"
},
"devDependencies": {
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/internal-build-utils": "~0.3.1",
"@rollup/plugin-commonjs": "~22.0.2",
"@rollup/plugin-json": "~4.1.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/rest/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,12 @@
"!dist/test/**"
],
"peerDependencies": {
"@cadl-lang/compiler": "~0.36.0"
"@cadl-lang/compiler": "~0.36.1"
},
"devDependencies": {
"@types/mocha": "~9.1.0",
"@types/node": "~16.0.3",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/eslint-config-cadl": "~0.4.1",
"@cadl-lang/library-linter": "~0.2.1",
"@cadl-lang/eslint-plugin": "~0.1.1",
Expand Down
2 changes: 1 addition & 1 deletion packages/samples/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
],
"dependencies": {
"@cadl-lang/versioning": "~0.9.0",
"@cadl-lang/compiler": "~0.36.0",
"@cadl-lang/compiler": "~0.36.1",
"@cadl-lang/rest": "~0.18.0",
"@cadl-lang/openapi": "~0.13.0",
"@cadl-lang/openapi3": "~0.16.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/versioning/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"!dist/test/**"
],
"dependencies": {
"@cadl-lang/compiler": "~0.36.0"
"@cadl-lang/compiler": "~0.36.1"
},
"devDependencies": {
"@types/mocha": "~9.1.0",
Expand Down

0 comments on commit 3676818

Please sign in to comment.