mirror of
https://github.com/denoland/deno.git
synced 2024-11-23 15:16:54 -05:00
parent
50fdccb175
commit
63bbe2a2e0
13 changed files with 19 additions and 17 deletions
|
@ -2,5 +2,5 @@ parameters:
|
||||||
exe_suffix: ""
|
exe_suffix: ""
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- bash: deno${{ parameters.exe_suffix }} run --allow-run --allow-write --allow-read format.ts --check
|
- bash: deno${{ parameters.exe_suffix }} run --allow-run --allow-write --allow-read --allow-env ./format.ts --check
|
||||||
- bash: deno${{ parameters.exe_suffix }} run --allow-run --allow-net --allow-write --allow-read --allow-env --config=tsconfig.test.json test.ts
|
- bash: deno${{ parameters.exe_suffix }} run --allow-run --allow-net --allow-write --allow-read --allow-env --config=tsconfig.test.json ./test.ts
|
|
@ -1,5 +1,5 @@
|
||||||
steps:
|
steps:
|
||||||
- bash: npm install eslint@5.16.0 typescript@$(TS_VERSION) @typescript-eslint/eslint-plugin @typescript-eslint/parser eslint-config-prettier
|
- bash: npm install eslint@5.16.0 typescript@$(TS_VERSION) @typescript-eslint/eslint-plugin@1.13.0 @typescript-eslint/parser@1.13.0 eslint-config-prettier
|
||||||
- template: ./template.unix.yml
|
- template: ./template.unix.yml
|
||||||
- bash: npx eslint **/*.ts --max-warnings=0
|
- bash: npx eslint **/*.ts --max-warnings=0
|
||||||
- template: ./template.common.yml
|
- template: ./template.common.yml
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
steps:
|
steps:
|
||||||
- bash: npm install -g functional-red-black-tree
|
- bash: npm install -g functional-red-black-tree
|
||||||
- bash: npm -g install eslint@5.16.0 typescript@$(TS_VERSION) @typescript-eslint/eslint-plugin @typescript-eslint/parser eslint-config-prettier
|
- bash: npm -g install eslint@5.16.0 typescript@$(TS_VERSION) @typescript-eslint/eslint-plugin@1.13.0 @typescript-eslint/parser@1.13.0 eslint-config-prettier
|
||||||
- template: ./template.unix.yml
|
- template: ./template.unix.yml
|
||||||
- bash: eslint **/*.ts --max-warnings=0
|
- bash: eslint **/*.ts --max-warnings=0
|
||||||
- template: ./template.common.yml
|
- template: ./template.common.yml
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
steps:
|
steps:
|
||||||
- bash: npm install eslint@5.16.0 typescript@$(TS_VERSION) @typescript-eslint/eslint-plugin @typescript-eslint/parser eslint-config-prettier
|
- bash: npm install eslint@5.16.0 typescript@$(TS_VERSION) @typescript-eslint/eslint-plugin@1.13.0 @typescript-eslint/parser@1.13.0 eslint-config-prettier
|
||||||
- powershell: iwr https://deno.land/x/install/install.ps1 -out install.ps1; .\install.ps1 $(DENO_VERSION)
|
- powershell: iwr https://deno.land/x/install/install.ps1 -out install.ps1; .\install.ps1 $(DENO_VERSION)
|
||||||
- bash: echo "##vso[task.prependpath]C:\Users\VssAdministrator\.deno\\bin"
|
- bash: echo "##vso[task.prependpath]C:\Users\VssAdministrator\.deno\\bin"
|
||||||
- bash: npx eslint **/*.ts --max-warnings=0
|
- bash: npx eslint **/*.ts --max-warnings=0
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
variables:
|
variables:
|
||||||
DENO_VERSION: "v0.12.0"
|
DENO_VERSION: "v0.15.0"
|
||||||
TS_VERSION: "3.4.5"
|
TS_VERSION: "3.4.5"
|
||||||
|
|
||||||
# TODO Try to get eslint to run under Deno, like prettier
|
# TODO Try to get eslint to run under Deno, like prettier
|
||||||
|
|
|
@ -16,7 +16,7 @@ test(function t2(): void {
|
||||||
test(async function catSmoke(): Promise<void> {
|
test(async function catSmoke(): Promise<void> {
|
||||||
const p = run({
|
const p = run({
|
||||||
args: [
|
args: [
|
||||||
Deno.execPath,
|
Deno.execPath(),
|
||||||
"run",
|
"run",
|
||||||
"--allow-read",
|
"--allow-read",
|
||||||
"examples/cat.ts",
|
"examples/cat.ts",
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/env -S deno run --allow-run --allow-write --allow-read
|
#!/usr/bin/env -S deno run --allow-run --allow-write --allow-read --allow-env
|
||||||
// Copyright 2018-2019 the Deno authors. All rights reserved. MIT license.
|
// Copyright 2018-2019 the Deno authors. All rights reserved. MIT license.
|
||||||
const { exit, args, execPath } = Deno;
|
const { exit, args, execPath } = Deno;
|
||||||
import { parse } from "./flags/mod.ts";
|
import { parse } from "./flags/mod.ts";
|
||||||
|
@ -6,7 +6,7 @@ import { xrun } from "./prettier/util.ts";
|
||||||
|
|
||||||
async function main(opts): Promise<void> {
|
async function main(opts): Promise<void> {
|
||||||
const args = [
|
const args = [
|
||||||
execPath,
|
execPath(),
|
||||||
"run",
|
"run",
|
||||||
"--allow-write",
|
"--allow-write",
|
||||||
"--allow-read",
|
"--allow-read",
|
||||||
|
@ -24,6 +24,8 @@ async function main(opts): Promise<void> {
|
||||||
args.push("--check");
|
args.push("--check");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
args.push(".");
|
||||||
|
|
||||||
exit((await xrun({ args }).status()).code);
|
exit((await xrun({ args }).status()).code);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,7 @@ let fileServer: Deno.Process;
|
||||||
async function startFileServer(): Promise<void> {
|
async function startFileServer(): Promise<void> {
|
||||||
fileServer = run({
|
fileServer = run({
|
||||||
args: [
|
args: [
|
||||||
Deno.execPath,
|
Deno.execPath(),
|
||||||
"run",
|
"run",
|
||||||
"--allow-read",
|
"--allow-read",
|
||||||
"--allow-net",
|
"--allow-net",
|
||||||
|
|
|
@ -8,7 +8,7 @@ import { TextProtoReader } from "../textproto/mod.ts";
|
||||||
let server: Deno.Process;
|
let server: Deno.Process;
|
||||||
async function startServer(): Promise<void> {
|
async function startServer(): Promise<void> {
|
||||||
server = run({
|
server = run({
|
||||||
args: [Deno.execPath, "run", "-A", "http/racing_server.ts"],
|
args: [Deno.execPath(), "run", "-A", "http/racing_server.ts"],
|
||||||
stdout: "piped"
|
stdout: "piped"
|
||||||
});
|
});
|
||||||
// Once racing server is ready it will write to its stdout.
|
// Once racing server is ready it will write to its stdout.
|
||||||
|
|
|
@ -493,7 +493,7 @@ test({
|
||||||
async fn(): Promise<void> {
|
async fn(): Promise<void> {
|
||||||
// Runs a simple server as another process
|
// Runs a simple server as another process
|
||||||
const p = Deno.run({
|
const p = Deno.run({
|
||||||
args: [Deno.execPath, "http/testdata/simple_server.ts", "--allow-net"],
|
args: [Deno.execPath(), "http/testdata/simple_server.ts", "--allow-net"],
|
||||||
stdout: "piped"
|
stdout: "piped"
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -227,7 +227,7 @@ export async function install(
|
||||||
|
|
||||||
// ensure script that is being installed exists
|
// ensure script that is being installed exists
|
||||||
const ps = run({
|
const ps = run({
|
||||||
args: [Deno.execPath, "fetch", "--reload", moduleUrl],
|
args: [Deno.execPath(), "fetch", "--reload", moduleUrl],
|
||||||
stdout: "inherit",
|
stdout: "inherit",
|
||||||
stderr: "inherit"
|
stderr: "inherit"
|
||||||
});
|
});
|
||||||
|
|
|
@ -16,7 +16,7 @@ const isWindows = Deno.platform.os === "win";
|
||||||
async function startFileServer(): Promise<void> {
|
async function startFileServer(): Promise<void> {
|
||||||
fileServer = run({
|
fileServer = run({
|
||||||
args: [
|
args: [
|
||||||
Deno.execPath,
|
Deno.execPath(),
|
||||||
"run",
|
"run",
|
||||||
"--allow-read",
|
"--allow-read",
|
||||||
"--allow-net",
|
"--allow-net",
|
||||||
|
|
|
@ -21,7 +21,7 @@ async function run(
|
||||||
}
|
}
|
||||||
|
|
||||||
const cmd = [
|
const cmd = [
|
||||||
execPath,
|
execPath(),
|
||||||
"run",
|
"run",
|
||||||
"--allow-run",
|
"--allow-run",
|
||||||
"--allow-write",
|
"--allow-write",
|
||||||
|
@ -254,13 +254,13 @@ test(async function testPrettierReadFromStdin(): Promise<void> {
|
||||||
): Promise<void> {
|
): Promise<void> {
|
||||||
const inputCode = stdin;
|
const inputCode = stdin;
|
||||||
const p1 = Deno.run({
|
const p1 = Deno.run({
|
||||||
args: [execPath, "./prettier/testdata/echox.ts", `${inputCode}`],
|
args: [execPath(), "./prettier/testdata/echox.ts", `${inputCode}`],
|
||||||
stdout: "piped"
|
stdout: "piped"
|
||||||
});
|
});
|
||||||
|
|
||||||
const p2 = Deno.run({
|
const p2 = Deno.run({
|
||||||
args: [
|
args: [
|
||||||
execPath,
|
execPath(),
|
||||||
"run",
|
"run",
|
||||||
"./prettier/main.ts",
|
"./prettier/main.ts",
|
||||||
"--stdin",
|
"--stdin",
|
||||||
|
|
Loading…
Reference in a new issue