Skip to content

Commit

Permalink
Merge branch 'next' of https://github.com/readmeio/rdme into terrell/c…
Browse files Browse the repository at this point in the history
…x-364-create-a-warning-in-rdme-when-someone-works-with-a-postman
  • Loading branch information
t-tullis committed Sep 13, 2023
2 parents f09c076 + c1a0e00 commit c1c20d9
Show file tree
Hide file tree
Showing 126 changed files with 22,543 additions and 14,145 deletions.
3 changes: 0 additions & 3 deletions .alexrc.js

This file was deleted.

1 change: 1 addition & 0 deletions .alexrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
profanitySureness: 1
2 changes: 1 addition & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
},
"overrides": [
{
"files": ["bin/*.js", "config/*.js"],
"files": ["bin/*.js"],
"rules": {
"@typescript-eslint/no-var-requires": "off"
}
Expand Down
12 changes: 9 additions & 3 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ updates:
- kanadgupta
labels:
- dependencies
groups:
minor-developent-deps:
dependency-type: 'development'
update-types:
- minor
- patch
commit-message:
prefix: chore(deps)
prefix-development: chore(deps-dev)
Expand All @@ -37,9 +43,9 @@ updates:
- dependency-name: node-fetch
versions:
- '>= 3'
- dependency-name: ora
versions:
- '>= 6'
- dependency-name: open
versions:
- '>= 9'
- dependency-name: ora
versions:
- '>= 6'
18 changes: 14 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
name: Test Suite
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
node-version:
- 14
Expand All @@ -20,34 +21,43 @@ jobs:
- 20

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: npm

- name: Build and run tests
run: npm cit

lint:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Install deps
run: npm ci

- name: Build dist
run: npm run build

- name: Run tests
run: npm test
run: npm run lint

action:
name: GitHub Action Dry Run
runs-on: ubuntu-latest
steps:
- name: Checkout GitHub Action
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: rdme-repo

- name: Checkout external repo containing OpenAPI file
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
path: oas-examples-repo
repository: readmeio/oas-examples
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout this repo
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install and build rdme deps
run: npm ci && npm run build
Expand Down
19 changes: 19 additions & 0 deletions .github/workflows/lint-pr-title.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: 'Lint PR Title'

on:
pull_request_target:
types:
- opened
- edited
- synchronize

permissions:
pull-requests: read

jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: amannn/action-semantic-pull-request@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
id-token: write
packages: write
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.RELEASE_GH_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/simple.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout GitHub Action
uses: actions/checkout@v3
uses: actions/checkout@v4

# This is a simple example that runs our `validate` command on a local file.
- name: Run `openapi:validate` command
Expand Down
2 changes: 1 addition & 1 deletion .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ __tests__/
.prettier*
bin/*.js
coverage/
jest.*.js
packages/
vitest.*
69 changes: 69 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,72 @@
# [8.7.0-next.2](https://github.com/readmeio/rdme/compare/v8.7.0-next.1...v8.7.0-next.2) (2023-09-13)


### Features

* use `actions/checkout@v4` everywhere ([#895](https://github.com/readmeio/rdme/issues/895)) ([d30b71c](https://github.com/readmeio/rdme/commit/d30b71cf39caa30da9ba94822f55e828f1a2bdc3))

# [8.7.0-next.1](https://github.com/readmeio/rdme/compare/v8.6.6...v8.7.0-next.1) (2023-09-07)


### Features

* **test:** moving unit tests over to vitest ([#857](https://github.com/readmeio/rdme/issues/857)) ([36d561b](https://github.com/readmeio/rdme/commit/36d561bba08593fb54b8473b5782d12ad436b98e)), closes [#870](https://github.com/readmeio/rdme/issues/870)

## [8.6.6](https://github.com/readmeio/rdme/compare/v8.6.5...v8.6.6) (2023-08-24)


### Bug Fixes

* **versions:** fix ability to set main version ([#872](https://github.com/readmeio/rdme/issues/872)) ([ba7ea03](https://github.com/readmeio/rdme/commit/ba7ea03a8eb63eab09ab40ad46352504a7dc0134))

## [8.6.6-next.1](https://github.com/readmeio/rdme/compare/v8.6.5...v8.6.6-next.1) (2023-08-24)


### Bug Fixes

* **versions:** fix ability to set main version ([#872](https://github.com/readmeio/rdme/issues/872)) ([ba7ea03](https://github.com/readmeio/rdme/commit/ba7ea03a8eb63eab09ab40ad46352504a7dc0134))

## [8.6.5](https://github.com/readmeio/rdme/compare/v8.6.4...v8.6.5) (2023-08-21)


### Bug Fixes

* **deps:** upgrading out of date deps ([#836](https://github.com/readmeio/rdme/issues/836)) ([8600554](https://github.com/readmeio/rdme/commit/86005541815b1810f2483f15a2bd579e14b82619))
* **npm:** revert shrinkwrap changes ([#824](https://github.com/readmeio/rdme/issues/824)) ([f96e6dc](https://github.com/readmeio/rdme/commit/f96e6dc33813e9a2db0474c1bac652cfca3c0e54))
* **openapi/inspect:** small url formatting error ([#855](https://github.com/readmeio/rdme/issues/855)) ([c54e289](https://github.com/readmeio/rdme/commit/c54e2896f253004563a29c3b42bde1f201f1e180))
* **reducer:** quirk with security schemes sometimes getting removed ([#867](https://github.com/readmeio/rdme/issues/867)) ([be2e037](https://github.com/readmeio/rdme/commit/be2e0370ce9fb29e6b56d6739a37449ecf0af8a7))
* **security:** don't publish certain files to npm ([a83fe1c](https://github.com/readmeio/rdme/commit/a83fe1cb94765f0e333374b0e6799f28c3268167)), closes [/socket.dev/npm/package/rdme/files/8.6.5-next.2/bin/docker.js#T167-182](https://github.com//socket.dev/npm/package/rdme/files/8.6.5-next.2/bin/docker.js/issues/T167-182)
* typo ([#852](https://github.com/readmeio/rdme/issues/852)) ([26c10e5](https://github.com/readmeio/rdme/commit/26c10e59415afbd32dc13f5438c8fd5a1747e22e))
* **versions:** general refactors to handle flag edge cases ([#861](https://github.com/readmeio/rdme/issues/861)) ([e316139](https://github.com/readmeio/rdme/commit/e31613915aaa383e49e949c6aac40b950f7bf9cf))

## [8.6.5-next.7](https://github.com/readmeio/rdme/compare/v8.6.5-next.6...v8.6.5-next.7) (2023-08-18)


### Bug Fixes

* **reducer:** quirk with security schemes sometimes getting removed ([#867](https://github.com/readmeio/rdme/issues/867)) ([be2e037](https://github.com/readmeio/rdme/commit/be2e0370ce9fb29e6b56d6739a37449ecf0af8a7))

## [8.6.5-next.6](https://github.com/readmeio/rdme/compare/v8.6.5-next.5...v8.6.5-next.6) (2023-08-18)


### Bug Fixes

* **versions:** general refactors to handle flag edge cases ([#861](https://github.com/readmeio/rdme/issues/861)) ([e316139](https://github.com/readmeio/rdme/commit/e31613915aaa383e49e949c6aac40b950f7bf9cf))

## [8.6.5-next.5](https://github.com/readmeio/rdme/compare/v8.6.5-next.4...v8.6.5-next.5) (2023-08-10)


### Bug Fixes

* **openapi/inspect:** small url formatting error ([#855](https://github.com/readmeio/rdme/issues/855)) ([c54e289](https://github.com/readmeio/rdme/commit/c54e2896f253004563a29c3b42bde1f201f1e180))

## [8.6.5-next.4](https://github.com/readmeio/rdme/compare/v8.6.5-next.3...v8.6.5-next.4) (2023-08-02)


### Bug Fixes

* typo ([#852](https://github.com/readmeio/rdme/issues/852)) ([26c10e5](https://github.com/readmeio/rdme/commit/26c10e59415afbd32dc13f5438c8fd5a1747e22e))

## [8.6.5-next.3](https://github.com/readmeio/rdme/compare/v8.6.5-next.2...v8.6.5-next.3) (2023-08-01)


Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ The following examples use JSON files, but `rdme` supports API Definitions that
> [!NOTE]
> The `rdme openapi` command supports both OpenAPI and Swagger API definitions. The `rdme swagger` command is an alias for `rdme openapi` and is deprecated.
If you wish to programmatically access any of this script's results (such as the API defintion ID or the link to the corresponding docs in your dashboard), supply the `--raw` flag and the command will return a JSON output.
If you wish to programmatically access any of this script's results (such as the API definition ID or the link to the corresponding docs in your dashboard), supply the `--raw` flag and the command will return a JSON output.

This command also has a dry run mode, which can be useful for initial setup and debugging. You can perform a dry run by supplying the `--dryRun` flag.

Expand Down Expand Up @@ -390,12 +390,12 @@ rdme versions --version={project-version}
rdme versions:create <version>
```

If you wish to automate the process of creating a new project version, and not have the CLI prompt you for input, you can do so by supplying the necessary flags to `versions:create`.
If you wish to automate the process of creating a new project version, and not have the CLI prompt you for input, you can do so by supplying the necessary flags to `versions:create`. The best way to ensure that you have supplied all the necessary flags is by running the command locally and verifying that the CLI does not prompt you.

For example:
For example, the following command contains all the flags to bypass the CLI prompts:

```sh
rdme versions:create <version> --fork={version-fork} --main={true|false} --beta={true|false} --isPublic={true|false}
rdme versions:create <version> --fork={version-fork} --main={true|false} --beta={true|false} --deprecated={true|false} --isPublic={true|false}
```

See `rdme versions:create --help` for a full list of flags.
Expand All @@ -406,7 +406,7 @@ See `rdme versions:create --help` for a full list of flags.
rdme versions:update <version>
```

Like `versions:create`, if you wish to automate this process and not be blocked by CLI input, you can supply the necessary flags to this command. See `rdme versions:update --help` for more information.
Like `versions:create`, if you wish to automate this process and not be blocked by CLI input, you can supply the necessary flags to this command. See `rdme versions:update --help` for a full list of flags.

#### Delete a Version

Expand Down
2 changes: 1 addition & 1 deletion __tests__/.eslintrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"extends": ["@readme/eslint-config/testing"]
"extends": "@readme/eslint-config/testing/vitest"
}
10 changes: 5 additions & 5 deletions __tests__/__snapshots__/index.test.ts.snap
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html

exports[`cli --help should not surface args that are designated as hidden 1`] = `
exports[`cli > --help > should not surface args that are designated as hidden 1`] = `
"
Upload, or resync, your OpenAPI/Swagger definition to ReadMe.
Expand Down Expand Up @@ -47,7 +47,7 @@ Related commands
"
`;

exports[`cli --help should print usage for a given command 1`] = `
exports[`cli > --help > should print usage for a given command 1`] = `
"
Upload, or resync, your OpenAPI/Swagger definition to ReadMe.
Expand Down Expand Up @@ -94,7 +94,7 @@ Related commands
"
`;

exports[`cli --help should print usage for a given command if supplied as \`help <command>\` 1`] = `
exports[`cli > --help > should print usage for a given command if supplied as \`help <command>\` 1`] = `
"
Upload, or resync, your OpenAPI/Swagger definition to ReadMe.
Expand Down Expand Up @@ -141,7 +141,7 @@ Related commands
"
`;
exports[`cli --help should show related commands for a subcommands help menu 1`] = `
exports[`cli > --help > should show related commands for a subcommands help menu 1`] = `
"
List versions available in your project or get a version by SemVer (https://semver.org/).
Expand Down
2 changes: 2 additions & 0 deletions __tests__/bin.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
import { exec } from 'child_process';

import { describe, it, expect } from 'vitest';

describe('bin', () => {
it('should show our help screen', async () => {
expect.assertions(1);
Expand Down
4 changes: 2 additions & 2 deletions __tests__/cmds/__snapshots__/whoami.test.ts.snap
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html

exports[`rdme whoami should return the authenticated user 1`] = `"You are currently logged in as [email protected] to the subdomain project."`;
exports[`rdme whoami > should return the authenticated user 1`] = `"You are currently logged in as [email protected] to the subdomain project."`;
Loading

0 comments on commit c1c20d9

Please sign in to comment.