Skip to content

Commit 1373e7a

Browse files
author
zhangfuxing
committed
v1.4.9: Both JSR and HTTPS are supported
1 parent f3d5cbd commit 1373e7a

29 files changed

+73
-42
lines changed

README.md

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,14 @@ ProgressBar in terminal for deno
1111
#### example
1212

1313
```ts
14-
import { MultiProgressBar } from "https://deno.land/x/[email protected].8/mod.ts";
14+
import { MultiProgressBar } from "https://deno.land/x/[email protected].9/mod.ts";
1515
import { delay } from "https://deno.land/[email protected]/async/delay.ts";
16+
1617
// or JSR
18+
// import { MultiProgressBar } from "jsr:@deno-library/[email protected]";
19+
// import { delay } from "jsr:@std/[email protected]";
20+
21+
// or JSR (Run `deno add @deno-library/progress` and `deno add @std/async`)
1722
// import { MultiProgressBar } from "@deno-library/progress";
1823
// import { delay } from "@std/async";
1924

@@ -149,10 +154,16 @@ What is displayed and display order, default: ':bar :text :percent :time
149154
#### simple example
150155

151156
```ts
152-
import ProgressBar from "https://deno.land/x/[email protected]/mod.ts";
157+
import ProgressBar from "https://deno.land/x/[email protected]/mod.ts";
158+
import { delay } from "https://deno.land/[email protected]/async/delay.ts";
159+
153160
// or JSR
161+
// import ProgressBar from "jsr:@deno-library/[email protected]";
162+
// import { delay } from "jsr:@std/[email protected]";
163+
164+
// or JSR (Run `deno add @deno-library/progress` and `deno add @std/async`)
154165
// import ProgressBar from "@deno-library/progress";
155-
import { delay } from "https://deno.land/[email protected]/async/delay.ts";
166+
// import { delay } from "@std/async";
156167

157168
const title = "downloading:";
158169
const total = 100;
@@ -174,10 +185,16 @@ await download();
174185
#### complex example
175186

176187
```ts
177-
import ProgressBar from "https://deno.land/x/[email protected]/mod.ts";
188+
import ProgressBar from "https://deno.land/x/[email protected]/mod.ts";
189+
import { delay } from "https://deno.land/[email protected]/async/delay.ts";
190+
178191
// or JSR
192+
// import ProgressBar from "jsr:@deno-library/[email protected]";
193+
// import { delay } from "jsr:@std/[email protected]";
194+
195+
// or JSR (Run `deno add @deno-library/progress` and `deno add @std/async`)
179196
// import ProgressBar from "@deno-library/progress";
180-
import { delay } from "https://deno.land/[email protected]/async/delay.ts";
197+
// import { delay } from "@std/async";
181198

182199
const total = 100;
183200
const progress = new ProgressBar({

changelog.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
## Changelog
22

3+
### v1.4.9 - 2024.04.02
4+
5+
[Both JSR and HTTPS are supported](https://github.com/deno-library/progress/issues/29)
6+
37
### v1.4.6 - 2024.03.27
48

59
[support JSR](https://github.com/deno-library/progress/issues/28)
@@ -38,7 +42,7 @@ changes:
3842

3943
1. fixed [colored string length calculation bug](https://github.com/deno-library/progress/issues/8)
4044

41-
2. **Deno.consoleSize is now stable**
45+
2. **Deno.consoleSize is now stable**
4246

4347
> [Deno v1.27.0 : Stabilize Deno.consoleSize() API](https://github.com/denoland/deno/pull/15933)
4448

deno.json

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
{
22
"name": "@deno-library/progress",
3-
"version": "1.4.8",
4-
"exports": "./mod.ts",
5-
"lock": false,
6-
"imports": {
7-
"@std/assert": "jsr:@std/assert@^0.220.1",
8-
"@std/async": "jsr:@std/async@^0.220.1",
9-
"@std/fmt": "jsr:@std/fmt@^0.220.1"
3+
"version": "1.4.9",
4+
"exports": {
5+
".": "./mod.ts",
6+
"./time": "./time.ts"
107
},
8+
"lock": false,
119
"publish": {
1210
"exclude": [
1311
"examples",
@@ -18,5 +16,8 @@
1816
"changelog.md"
1917
]
2018
},
21-
"compilerOptions": {}
22-
}
19+
"compilerOptions": {},
20+
"fmt": {
21+
"exclude": ["README.md"]
22+
}
23+
}

deps.example.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
export { delay } from "jsr:@std/[email protected]";
2+
export * from "jsr:@std/[email protected]/colors";
3+
export {
4+
simpleCallbackTarget,
5+
timerSource,
6+
} from "https://deno.land/x/[email protected]/mod.ts";

deps.test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
export { assertEquals } from "jsr:@std/[email protected]";
2+
export { simpleTimerStream } from "https://deno.land/x/[email protected]/mod.ts";

deps.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export { bgGreen, bgWhite, stripAnsiCode } from "jsr:@std/[email protected]/colors";

examples/backward.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import ProgressBar from "../mod.ts";
2-
import { delay } from "@std/async";
2+
import { delay } from "../deps.example.ts";
33

44
const progress = new ProgressBar({
55
title: "backward",

examples/changeBgColor.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import ProgressBar from "../mod.ts";
2-
import { bgCyan, bgMagenta } from "@std/fmt/colors";
3-
import { delay } from "@std/async";
2+
import { delay } from "../deps.example.ts";
3+
import { bgCyan, bgMagenta } from "../deps.example.ts";
44

55
const total = 100;
66

examples/changeColor.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import ProgressBar from "../mod.ts";
2-
import { green, yellow } from "@std/fmt/colors";
3-
import { delay } from "@std/async";
2+
import { delay } from "../deps.example.ts";
3+
import { green, yellow } from "../deps.example.ts";
44

55
const total = 100;
66

examples/clear.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import ProgressBar from "../mod.ts";
2-
import { delay } from "@std/async";
2+
import { delay } from "../deps.example.ts";
33

44
const total = 100;
55

0 commit comments

Comments
 (0)