Skip to content

Commit faa062a

Browse files
authored
Merge pull request #108 from chkware/release-maintenance/2025-MAR-12-1
Release maintenance: 2025-MAR-12
2 parents 33ebbeb + 6458e79 commit faa062a

10 files changed

Lines changed: 275 additions & 268 deletions

File tree

blog/2025-02-01-Releasing-CHKware-v0.5.0.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,4 +49,4 @@ Please follow us on [_Twitter/X_](https://x.com/chkware).
4949

5050
---
5151

52-
See details [CHANGELOG](../docs/changelogs/cli) for specifics.
52+
See details [CHANGELOG](../docs/changelogs/cli-v0.x) for specifics.
Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,18 @@
11
---
22
title: Console app v0.x changelog
33
---
4+
# Changelog
45

56
All notable changes to this project will be documented in this file.
67

7-
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
8+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
89
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
910

10-
## [Unreleased]
11-
12-
Date: not-available
11+
## [Unreleased] - Date not-available
1312

1413
---
1514

16-
## 0.5.0 `beta`
17-
18-
Date: 2025-02-01
15+
## [0.5.0 `beta`] - 2025-02-01
1916

2017
### Added
2118

@@ -61,9 +58,7 @@ Date: 2025-02-01
6158

6259
---
6360

64-
## 0.4.3 `alpha`
65-
66-
Date: 2023-03-09
61+
## [0.4.3 `alpha`] - 2023-03-09
6762

6863
### Added
6964

docs/quick-start.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Quick Start
33
---
44

5-
:::warning
5+
:::info
66

77
Prerequisite: [Setup **CHKware**](/docs/setup) to continue
88

docs/references/variables.md

Lines changed: 37 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,58 @@
11
---
22
title: Variables
33
---
4-
### Introduction
5-
64
Variables are ways to hold value or computed values in specification files, like in programming language.
75

8-
### Variables
6+
## Variables node
97

10-
Variables can be defined with `variables` node on a supported specification document.
8+
Variables can be defined with `variables` node on a specification document. This node is support on all kind of spec.
119

12-
```yml
10+
```yml {3-4}
1311
version: default:http:0.7.2
1412

1513
variables:
1614
var1: 22
15+
16+
...
1717
```
1818

19-
This variables can be later used, i.e.
19+
This variables can be used later, e.g.
2020

21-
```yml
21+
```yml {3-4,7}
2222
version: default:http:0.7.2
2323

2424
variables:
2525
emailAddr: "user@domain.ext"
2626

2727
request:
2828
url: "https://httpbin.org/get?emailAddress=<% emailAddr %>"
29-
30-
...
29+
...
3130
```
3231

33-
It is not possible to name a variable prefixing an *underscore* (`_`). So, `_Name` is an invalid name. Variable names can include `A-Z, a-z, 0-9, ., -, _`.
32+
::::tip [Naming variables]
33+
34+
Variable names can include
35+
36+
- `A-Z`
37+
- `a-z`
38+
- `0-9`
39+
- `.` dot
40+
- `-` dash
41+
- `_` underscore
3442

35-
### Passing variables from console
43+
:::warning
3644

37-
It's possible to pass variables from console while invoking `chk` command. e.g:
45+
It is not possible to start a variable name with _underscore_ (`_`). Therefore, `_Name` is an invalid name, when `Name_` is valid.
3846

39-
So, for following HTTP specification:
47+
:::
4048

41-
```yml [title="request-someurl.chk"]
49+
::::
50+
51+
## Passing variables from console
52+
53+
It's possible to pass variables from console while invoking `chk` command. Let's have following HTTP specification:
54+
55+
```yml [title="request-someurl.chk"] {5,10}
4256
---
4357
version: default:http:0.7.2
4458

@@ -49,20 +63,20 @@ request:
4963
url: "https://httpbin.org/get"
5064
url_params:
5165
emailAddress: <% emailAddr %>
52-
5366
...
5467
```
68+
5569
```shell
5670
chk fetch request-someurl.chk -V {"emailAddress": "user@domain.ext"}
5771
```
5872

5973
Then CHKware will replace `<% emailAddr %>` with `"user@domain.ext"`, before making request. When variable not passed from console, `<% emailAddr %>` will be replaced with `null`.
6074

61-
### Setting default value
75+
## Setting default value
6276

6377
It's possible to set a default value for a variable. Consider following example:
6478

65-
```yml [title="request-someurl.chk"]
79+
```yml [title="request-someurl.chk"] {5,10}
6680
---
6781
version: default:http:0.7.2
6882

@@ -76,27 +90,27 @@ request:
7690
...
7791
```
7892

79-
When invoked like:
93+
When invoked in the console like:
8094

8195
```shell
8296
chk fetch request-someurl.chk -V {"emailAddress": "user@domain.ext"}
8397
```
8498

8599
Then CHKware will replace `<% emailAddr %>` with `"user@domain.ext"`, before making request.
86100

87-
However, if invoked like:
101+
However, if invoked in the console like:
88102

89103
```shell
90104
chk fetch request-someurl.chk
91105
```
92106

93-
Then CHKware will replace `<% emailAddr %>` with something like `"user-2@domain.ext"` (or with an email of randomly picked number).
107+
Then CHKware will replace `<% emailAddr %>` with something like `"user-2@domain.ext"` (or with an email of randomly picked number) since we set default value to `user-<% range(1, 5) | random %>@domain.ext`.
94108

95-
### Variable templating with Jinja2
109+
## Variable templating with Jinja2
96110

97-
For variable templating *CHKware* uses Jinja2. Almost all of the [Jinja2 features](https://jinja.palletsprojects.com/en/stable/templates/) are supported. That makes it possible to change variables values. e.g:
111+
For variable templating _CHKware_ uses Jinja2. Almost all of the [Jinja2 features](https://jinja.palletsprojects.com/en/stable/templates/) are supported. That makes it possible to change variables values. e.g:
98112

99-
```yml
113+
```yml [title="request-someurl.chk"] {4-5,10-11}
100114
version: default:http:0.7.2
101115

102116
variables:
@@ -108,6 +122,5 @@ request:
108122
url_params:
109123
userId: <% userId %>
110124
emailAddress: <% emailAddr %>
111-
112125
...
113126
```

docs/references/version.md

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
---
22
title: Document version
33
---
4-
5-
### Introduction
6-
7-
Each `.chk`, `.yaml` or `.yml` files containing *CHKware* YAML-dsl is a spec. or specification file. Each of these file **MUST** contain a YAML node called *version:*. E.g:
4+
Each `.chk`, `.yaml` or `.yml` [specification files](./console-command#specification-files) or spec contains *CHKware* YAML-dsl. Each of these file **MUST** contain a YAML node called *version:*. E.g:
85

96
```yml
107
version: default:http:0.7.2
@@ -15,11 +12,9 @@ The version string contains a document version. Document version show which vers
1512

1613
The `chk` tool will exit with an error when unsupported document version found.
1714

18-
It's encouraged for user to write document version on the very top of a spec. document, so that it's clearly visible. However it can be written as a top-level key on any place of the document.
19-
20-
Supported document version can be found on corresponding specification reference.
15+
Although `version:` can be written as a top-level key on any place of the spec, it's encouraged to write `version:` on the very top, so that it's clearly visible.
2116

22-
### Format
17+
## Document version format
2318

2419
This version string have 3 parts: `<plugin>:<module>:<number>`, e.g: `default:http:0.8.0`
2520

docs/setup/setup-ext.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,18 @@
22
title: Setup VS Code extension
33
---
44

5-
:::warning
5+
::::success[visual studio code extension download]
66

7-
[CHKware vscode extension](https://marketplace.visualstudio.com/items?itemName=chkware.chkware) on visual studio marketplace it not updated.
7+
Latest vscode extension can be found on project's Github [release page](https://github.com/chkware/vscode-ext/releases). ✅
88

9-
:::
10-
:::success
9+
:::warning[deprecated]
1110

12-
Latest vscode extension can be found on project's Github [release page](https://github.com/chkware/vscode-ext/releases).
11+
[CHKware vscode extension](https://marketplace.visualstudio.com/items?itemName=chkware.chkware) on visual studio marketplace is deprecated, and not updated to latest spec documents. ⛔️
1312

1413
:::
1514

15+
::::
16+
1617
*CHKware VS Code extension* helps to write `.chk` files quick. It contains regular used snippets those makes test spec. development quick.
1718

1819
### Install *CHKware* extension for Visual Studio Code

docusaurus.config.js

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,7 @@
1-
// @ts-check
2-
// `@type` JSDoc annotations allow editor autocompletion and type checking
3-
// (when paired with `@ts-check`).
4-
// There are various equivalent ways to declare your Docusaurus config.
5-
// See: https://docusaurus.io/docs/api/docusaurus-config
6-
7-
import { themes as prismThemes } from "prism-react-renderer";
8-
9-
const TwitterSvg =
10-
'<svg style="fill: #1DA1F2; vertical-align: middle;" width="16" height="16" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path d="M459.37 151.716c.325 4.548.325 9.097.325 13.645 0 138.72-105.583 298.558-298.558 298.558-59.452 0-114.68-17.219-161.137-47.106 8.447.974 16.568 1.299 25.34 1.299 49.055 0 94.213-16.568 130.274-44.832-46.132-.975-84.792-31.188-98.112-72.772 6.498.974 12.995 1.624 19.818 1.624 9.421 0 18.843-1.3 27.614-3.573-48.081-9.747-84.143-51.98-84.143-102.985v-1.299c13.969 7.797 30.214 12.67 47.431 13.319-28.264-18.843-46.781-51.005-46.781-87.391 0-19.492 5.197-37.36 14.294-52.954 51.655 63.675 129.3 105.258 216.365 109.807-1.624-7.797-2.599-15.918-2.599-24.04 0-57.828 46.782-104.934 104.934-104.934 30.213 0 57.502 12.67 76.67 33.137 23.715-4.548 46.456-13.32 66.599-25.34-7.798 24.366-24.366 44.833-46.132 57.827 21.117-2.273 41.584-8.122 60.426-16.243-14.292 20.791-32.161 39.308-52.628 54.253z"></path></svg>';
1+
const TwitterSvg = '<svg style="fill: #1DA1F2; vertical-align: middle;" width="16" height="16" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path d="M459.37 151.716c.325 4.548.325 9.097.325 13.645 0 138.72-105.583 298.558-298.558 298.558-59.452 0-114.68-17.219-161.137-47.106 8.447.974 16.568 1.299 25.34 1.299 49.055 0 94.213-16.568 130.274-44.832-46.132-.975-84.792-31.188-98.112-72.772 6.498.974 12.995 1.624 19.818 1.624 9.421 0 18.843-1.3 27.614-3.573-48.081-9.747-84.143-51.98-84.143-102.985v-1.299c13.969 7.797 30.214 12.67 47.431 13.319-28.264-18.843-46.781-51.005-46.781-87.391 0-19.492 5.197-37.36 14.294-52.954 51.655 63.675 129.3 105.258 216.365 109.807-1.624-7.797-2.599-15.918-2.599-24.04 0-57.828 46.782-104.934 104.934-104.934 30.213 0 57.502 12.67 76.67 33.137 23.715-4.548 46.456-13.32 66.599-25.34-7.798 24.366-24.366 44.833-46.132 57.827 21.117-2.273 41.584-8.122 60.426-16.243-14.292 20.791-32.161 39.308-52.628 54.253z"></path></svg>';
2+
const GithubSvg = `<svg xmlns="http://www.w3.org/2000/svg" style="vertical-align: middle;" width="16" height="16">
3+
<path d="M 7.5 1 C 3.910156 1 1 3.90625 1 7.488281 C 1 10.355469 2.863281 12.789063 5.445313 13.648438 C 5.769531 13.707031 6 13.375 6 13.125 C 6 12.972656 6.003906 12.789063 6 12.25 C 4.191406 12.640625 3.625 11.375 3.625 11.375 C 3.328125 10.625 2.96875 10.410156 2.96875 10.410156 C 2.378906 10.007813 3.011719 10.019531 3.011719 10.019531 C 3.664063 10.0625 4 10.625 4 10.625 C 4.5 11.5 5.628906 11.414063 6 11.25 C 6 10.851563 6.042969 10.5625 6.152344 10.378906 C 4.109375 10.019531 2.996094 8.839844 3 7.207031 C 3.003906 6.242188 3.335938 5.492188 3.875 4.9375 C 3.640625 4.640625 3.480469 3.625 3.960938 3 C 5.167969 3 5.886719 3.871094 5.886719 3.871094 C 5.886719 3.871094 6.453125 3.625 7.496094 3.625 C 8.542969 3.625 9.105469 3.859375 9.105469 3.859375 C 9.105469 3.859375 9.828125 3 11.035156 3 C 11.515625 3.625 11.355469 4.640625 11.167969 4.917969 C 11.683594 5.460938 12 6.210938 12 7.207031 C 12 8.839844 10.890625 10.019531 8.851563 10.375 C 8.980469 10.570313 9 10.84375 9 11.25 C 9 12.117188 9 12.910156 9 13.125 C 9 13.375 9.226563 13.710938 9.558594 13.648438 C 12.140625 12.785156 14 10.355469 14 7.488281 C 14 3.90625 11.089844 1 7.5 1 Z"></path>
4+
</svg>`
115

126
/** @type {import('@docusaurus/types').Config} */
137
const config = {
@@ -169,14 +163,12 @@ const config = {
169163
},
170164
prism: {
171165
additionalLanguages: ["http", "yaml"],
172-
theme: prismThemes.github,
173-
darkTheme: prismThemes.dracula,
174166
},
175167
announcementBar: {
176168
id: "support_us",
177169
content: `Like <strong>CHKware</strong>❓
178-
⭐️ Star repository on <a target="_blank" rel="noopener noreferrer" href="https://github.com/chkware/cli">GitHub</a>.
179-
Follow on <a target="_blank" rel="noopener noreferrer" href="https://twitter.com/chkware" >Twitter</a> ${TwitterSvg}`,
170+
Star repository on <a target="_blank" rel="noopener noreferrer" href="https://github.com/chkware/cli">${GithubSvg} GitHub</a>.
171+
Follow on <a target="_blank" rel="noopener noreferrer" href="https://twitter.com/chkware" >${TwitterSvg} Twitter</a>`,
180172
isCloseable: false,
181173
backgroundColor: "#DBE432",
182174
},
@@ -196,8 +188,14 @@ const config = {
196188
],
197189
],
198190
customFields: {
199-
indexCta: "docs/quick-start",
200-
indexCtaTitle: "⏱️ Takes 10 minutes to start",
191+
primary: {
192+
link: "docs/setup",
193+
title: "pipx install chk",
194+
},
195+
secondary: {
196+
link: "docs/quick-start",
197+
title: "10 minutes quick start",
198+
},
201199
shortDetails: "Low-code API quality testing, and automation tool.",
202200
longDetails:
203201
"API testing tool, a script-able HTTP client, and an API test automation tool for the API era.",

0 commit comments

Comments
 (0)