Skip to content

Commit

Permalink
fix document and region bug (#62)
Browse files Browse the repository at this point in the history
* fix document demo code indentation

* sync region choices of fun config

* add code packing log
  • Loading branch information
tanhe123 authored Jul 14, 2018
1 parent 9cea02f commit ff8fab3
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 15 deletions.
12 changes: 6 additions & 6 deletions docs/specs/2018-04-03-zh-cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ Resources:
Handler: index.handler
Runtime: nodejs6
CodeUri: './'
Events:
http-test: # trigger name
Type: HTTP # http trigger
Properties:
AuthType: ANONYMOUS
Methods: ['GET', 'POST', 'PUT']
Events:
http-test: # trigger name
Type: HTTP # http trigger
Properties:
AuthType: ANONYMOUS
Methods: ['GET', 'POST', 'PUT']
```
阿里云 Fun 中的所有属性名称都**区分大小写**。
Expand Down
8 changes: 4 additions & 4 deletions docs/specs/2018-04-03.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ Resources:
Handler: index.handler
Runtime: nodejs6
CodeUri: './'
Events:
http-test: # trigger name
Events:
http-test: # trigger name
Type: HTTP # http trigger
Properties:
AuthType: ANONYMOUS
Methods: ['GET', 'POST', 'PUT']
AuthType: ANONYMOUS
Methods: ['GET', 'POST', 'PUT']
```
All property names in Aliyun Fun are **case sensitive**.
Expand Down
4 changes: 2 additions & 2 deletions lib/commands/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ async function config() {
type: 'list',
name: 'defaultRegion',
message: 'Default region name',
choices: ['cn-beijing', 'cn-shanghai', 'cn-shenzhen', 'cn-hangzhou', 'cn-zhangjiakou', 'cn-hongkong',
'ap-southeast-1', 'ap-southeast-2'],
choices: ['cn-beijing', 'cn-hangzhou', 'cn-shanghai', 'cn-shenzhen' , 'cn-hongkong',
'ap-southeast-1', 'ap-southeast-2', 'ap-northeast-1', 'eu-central-1'],
default: profile.defaultRegion
}
];
Expand Down
6 changes: 3 additions & 3 deletions lib/deploy/deploy-support.js
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ async function getFunCodeAsBase64(codeUri) {
} else {
codeUri = './';
}

return await zip.file(codeUri);
}

Expand Down Expand Up @@ -316,9 +316,9 @@ async function makeFunction({
if (codeUri && codeUri.startsWith('oss://')) {
code = extractOssCodeUri(codeUri);
} else {
debug(`package function ${functionName}.`);
console.log(`\t\tWaiting for packaging function ${functionName} code...`);
const base64 = await getFunCodeAsBase64(codeUri);
debug(`package function ${functionName}. done.`);
console.log(green(`\t\tpackage function ${functionName} code done`));

code = {
zipFile: base64
Expand Down

0 comments on commit ff8fab3

Please sign in to comment.