Skip to content

Commit 175eabf

Browse files
author
Ben Force
committed
fix: setup travis deployment
1 parent a79ffe5 commit 175eabf

7 files changed

Lines changed: 7925 additions & 86 deletions

File tree

.circleci/config.yml

Lines changed: 0 additions & 31 deletions
This file was deleted.

.npmignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,5 @@ examples
88
.gitignore
99
make-examples.js
1010
.vscode
11-
.circleci
11+
.circleci
12+
.travis.yml

.travis.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
language: node_js
2+
node_js: "11"
3+
4+
cache: yarn
5+
6+
jobs:
7+
include:
8+
# Define the release stage that runs semantic-release
9+
- stage: release
10+
if: branch = master
11+
node_js: lts/*
12+
# Advanced: optionally overwrite your default `script` step to skip the tests
13+
# script: skip
14+
deploy:
15+
provider: script
16+
skip_cleanup: true
17+
script: yarn semantic-release --allow-same-version

CHANGELOG.md

Lines changed: 0 additions & 24 deletions
This file was deleted.

README.md

Lines changed: 20 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,65 +1,57 @@
1-
swagger-markdown
2-
================
1+
# openapi-markdown
32

4-
[![npm][npm-image]][npm-url] [![dependencies][david-image]][david-url] [![circle ci][circleci-image]][circleci-url]
3+
[![npm][npm-image]][npm-url]
54

6-
CLI script to turn swagger yaml into markdown files.
7-
Supports swagger 2.0 format only
8-
9-
see [examples](https://github.com/syroegkin/swagger-markdown/tree/master/examples) folder
5+
CLI script to turn swagger/OpenAPI yaml into markdown files.
6+
Primarily supports swagger 2.0, with some OpenAPI 3.0 features.
107

118
### Installation
129

13-
npm install -g swagger-markdown
10+
npm install -g openapi-markdown
1411

1512
### Usage
1613

1714
```
18-
swagger-markdown [-h] [-v] -i [-o] [--skip-info]
15+
openapi-markdown [-h] [-v] -i [-o] [--skip-info]
1916
2017
Options:
2118
-h, --help Show this help message and exit.
2219
-v, --version Show program's version number and exit.
23-
-i , --input Path to the swagger yaml file
20+
-i , --input Path to the openapi yaml file
2421
-o , --output Path to the resulting md file
2522
--skip-info Skip the title, description, version etc, whatever is in the info block.
2623
2724
```
2825

2926
### Npx (requires no installation)
27+
3028
```
31-
npx swagger-markdown -i ./basic-auth.yaml
29+
npx openapi-markdown -i ./basic-auth.yaml
3230
```
3331

3432
#### Example:
3533

3634
```javascript
37-
swagger-markdown -i path/to/swagger/file.yaml
35+
openapi-markdown -i path/to/openapi/file.yaml
3836
```
39-
By default it will create the new file within the same directory with the same name as swagger file but with .md extension.
40-
So, if swagger file is placed in `project/api-doc/swagger.yaml` the new file will be created as `project/api-doc/swagger.md`
37+
38+
By default it will create the new file within the same directory with the same name as openapi file but with .md extension.
39+
So, if openapi file is placed in `project/api-doc/openapi.yaml` the new file will be created as `project/api-doc/openapi.md`
4140

4241
You can also use it as a npm script in your package.json:
4342

44-
npm i --save-dev swagger-markdown
43+
npm i --save-dev openapi-markdown
4544

4645
```jsonc
4746
{
48-
"scripts": {
49-
"md-docs": "swagger-markdown -i path/to/swagger.yaml",
50-
//...
51-
}
47+
"scripts": {
48+
"md-docs": "openapi-markdown -i path/to/openapi.yaml"
49+
//...
50+
}
5251
}
5352
```
5453

5554
npm run md-docs
5655

57-
[npm-url]: https://www.npmjs.com/package/swagger-markdown
58-
[npm-image]: https://img.shields.io/npm/v/swagger-markdown.svg
59-
60-
[david-url]: https://david-dm.org/syroegkin/swagger-markdown
61-
[david-image]: https://img.shields.io/david/syroegkin/swagger-markdown.svg
62-
63-
[circleci-url]: https://circleci.com/gh/syroegkin/swagger-markdown/tree/master
64-
[circleci-image]: https://img.shields.io/circleci/project/syroegkin/swagger-markdown.svg
65-
56+
[npm-url]: https://www.npmjs.com/package/openapi-markdown
57+
[npm-image]: https://img.shields.io/npm/v/openapi-markdown.svg

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
{
2-
"name": "swagger-markdown",
2+
"name": "openapi-markdown",
33
"version": "1.2.0",
4-
"description": "Create markdown API documentation from swagger file",
4+
"description": "Create markdown API documentation from swagger/openapi files",
55
"main": "index.js",
66
"scripts": {
77
"test": "npm run test:app && npm run test:lint",
88
"test:app": "mocha \"tests/**/*.spec.js\"",
99
"test:watch": "mocha --watch \"tests/**/*.spec.js\"",
1010
"test:lint": "eslint .",
1111
"build": "babel app --out-dir bin",
12+
"prepare": "npm run build",
1213
"prepublish": "npm run build",
1314
"commit": "git-cz",
1415
"semantic-release": "semantic-release"

0 commit comments

Comments
 (0)