Skip to content

Commit

Permalink
Apply correction to the documentation for quoting functions (#969)
Browse files Browse the repository at this point in the history
Quotes are shell specific, not necessarily the same for all shells for a
given OS.
  • Loading branch information
ericcornelissen committed Jun 17, 2023
1 parent 640ecf4 commit b661bf2
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Versioning].

## [Unreleased]

- _No changes yet_
- Correct documented behavior of quoting functions. ([#969])

## [1.7.0] - 2023-06-12

Expand Down Expand Up @@ -259,6 +259,7 @@ Versioning].
[#908]: https://github.com/ericcornelissen/shescape/pull/908
[#909]: https://github.com/ericcornelissen/shescape/pull/909
[#936]: https://github.com/ericcornelissen/shescape/pull/936
[#969]: https://github.com/ericcornelissen/shescape/pull/969
[552e8ea]: https://github.com/ericcornelissen/shescape/commit/552e8eab56861720b1d4e5474fb65741643358f9
[keep a changelog]: https://keepachangelog.com/en/1.0.0/
[semantic versioning]: https://semver.org/spec/v2.0.0.html
6 changes: 3 additions & 3 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ export function escape(arg: string, options?: EscapeOptions): string;
export function escapeAll(args: string[], options?: EscapeOptions): string[];

/**
* Take a single value, the argument, put OS-specific quotes around it and
* Take a single value, the argument, put shell-specific quotes around it and
* escape any dangerous characters.
*
* Non-string inputs will be converted to strings using a `toString()` method.
Expand Down Expand Up @@ -144,8 +144,8 @@ export function escapeAll(args: string[], options?: EscapeOptions): string[];
export function quote(arg: string, options?: QuoteOptions): string;

/**
* Take an array of values, the arguments, put OS-specific quotes around every
* argument and escape any dangerous characters in every argument.
* Take an array of values, the arguments, put shell-specific quotes around
* every argument and escape any dangerous characters in every argument.
*
* Non-array inputs will be converted to one-value arrays and non-string values
* will be converted to strings using a `toString()` method.
Expand Down
6 changes: 3 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ export function escapeAll(args, options = {}) {
}

/**
* Take a single value, the argument, put OS-specific quotes around it and
* Take a single value, the argument, put shell-specific quotes around it and
* escape any dangerous characters.
*
* Non-string inputs will be converted to strings using a `toString()` method.
Expand Down Expand Up @@ -120,8 +120,8 @@ export function quote(arg, options = {}) {
}

/**
* Take an array of values, the arguments, put OS-specific quotes around every
* argument and escape any dangerous characters in every argument.
* Take an array of values, the arguments, put shell-specific quotes around
* every argument and escape any dangerous characters in every argument.
*
* Non-array inputs will be converted to one-value arrays and non-string values
* will be converted to strings using a `toString()` method.
Expand Down

0 comments on commit b661bf2

Please sign in to comment.