Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document slice flags as part of examples (v2) #1751

Merged
merged 1 commit into from Jun 12, 2023

Conversation

carhartl
Copy link
Member

This PR adds an example for how to use slice flags to flags.md in the v2 docs example directory, using a StringSliceFlag in the specific example. As instructed in #1005, which seems to indicate there's some demand for it.

Also see #1750

What type of PR is this?

  • documentation

What this PR does / why we need it:

Make the documentation more complete, so that users can get started without looking at source/tests/discussions, like me :)

Which issue(s) this PR fixes:

Fixes #1005

Release Notes

Add example for using slice flags.

@carhartl carhartl requested a review from a team as a code owner June 12, 2023 12:21
@carhartl carhartl changed the base branch from main to v2-maint June 12, 2023 12:21
@carhartl carhartl changed the title Document slice flags v2 Document slice flags as part of examples (v2) Jun 12, 2023
@dearchap
Copy link
Contributor

Thank you so much @carhartl . Appreciate your PR

@dearchap dearchap merged commit 25fcea0 into urfave:v2-maint Jun 12, 2023
@carhartl carhartl deleted the document-slice-flags-v2 branch June 12, 2023 12:27
another-rex pushed a commit to google/osv-scanner that referenced this pull request Jun 14, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [github.com/BurntSushi/toml](https://togithub.com/BurntSushi/toml) |
require | patch | `v1.3.0` -> `v1.3.2` |
| [github.com/spdx/tools-golang](https://togithub.com/spdx/tools-golang)
| require | patch | `v0.5.1` -> `v0.5.2` |
| [github.com/urfave/cli/v2](https://togithub.com/urfave/cli) | require
| patch | `v2.25.5` -> `v2.25.6` |
| golang.org/x/mod | require | minor | `v0.10.0` -> `v0.11.0` |
| golang.org/x/sync | require | minor | `v0.2.0` -> `v0.3.0` |
| golang.org/x/term | require | minor | `v0.8.0` -> `v0.9.0` |

---

### Release Notes

<details>
<summary>BurntSushi/toml</summary>

### [`v1.3.2`](https://togithub.com/BurntSushi/toml/releases/tag/v1.3.2)

[Compare
Source](https://togithub.com/BurntSushi/toml/compare/v1.3.1...v1.3.2)

Fix reading `BURNTSUSHI_TOML_110` again 😅 The fix for 1.3.1 caused a
race issue with multiple decodes being run in parallel.

### [`v1.3.1`](https://togithub.com/BurntSushi/toml/releases/tag/v1.3.1)

[Compare
Source](https://togithub.com/BurntSushi/toml/compare/v1.3.0...v1.3.1)

This fixes two small bugs:

- The `BURNTSUSHI_TOML_110` environment variable would be checked on
package import, rather than Decode().

This meant that setting `os.Setenv("BURNTSUSHI_TOML_110", "")` had no
effect, as it happens after the import.

- Fix order of `Meta.Keys()` for inline tables (this has been an issue
since support for inline tables was added).

</details>

<details>
<summary>spdx/tools-golang</summary>

###
[`v0.5.2`](https://togithub.com/spdx/tools-golang/releases/tag/v0.5.2)

[Compare
Source](https://togithub.com/spdx/tools-golang/compare/v0.5.1...v0.5.2)

#### What's Changed

- fix duplicate shorthand relationships for opposite case by
[@&#8203;lumjjb](https://togithub.com/lumjjb) in
[spdx/tools-golang#220

**Full Changelog**:
spdx/tools-golang@v0.5.1...v0.5.2

</details>

<details>
<summary>urfave/cli</summary>

### [`v2.25.6`](https://togithub.com/urfave/cli/releases/tag/v2.25.6)

[Compare
Source](https://togithub.com/urfave/cli/compare/v2.25.5...v2.25.6)

##### What's Changed

- Fix:(issue\_1668) Add test case for sub command of sub command
completion by [@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1747
- Update dependencies for v2 by
[@&#8203;meatballhat](https://togithub.com/meatballhat) in
[urfave/cli#1749
- Document slice flags as part of examples (v2) by
[@&#8203;carhartl](https://togithub.com/carhartl) in
[urfave/cli#1751

**Full Changelog**:
urfave/cli@v2.25.5...v2.25.6

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "before 6am on monday" in timezone
Australia/Sydney, Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get
[config help](https://togithub.com/renovatebot/renovate/discussions) if
that's undesired.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://app.renovatebot.com/dashboard#github/google/osv-scanner).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNS4xMTAuMCIsInVwZGF0ZWRJblZlciI6IjM1LjExNy4zIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9-->
kyubisation pushed a commit to angular-static-server/angular-static-server that referenced this pull request Aug 20, 2023
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [github.com/urfave/cli/v2](https://togithub.com/urfave/cli) | require
| patch | `v2.25.3` -> `v2.25.7` |

---

### Release Notes

<details>
<summary>urfave/cli (github.com/urfave/cli/v2)</summary>

### [`v2.25.7`](https://togithub.com/urfave/cli/releases/tag/v2.25.7)

[Compare
Source](https://togithub.com/urfave/cli/compare/v2.25.6...v2.25.7)

#### What's Changed

- Fix: fix v2 broken tests by
[@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1757
- Fix:(issue\_1755) Ensure that timestamp flag destination is set
correctly by [@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1756

**Full Changelog**:
urfave/cli@v2.25.6...v2.25.7

### [`v2.25.6`](https://togithub.com/urfave/cli/releases/tag/v2.25.6)

[Compare
Source](https://togithub.com/urfave/cli/compare/v2.25.5...v2.25.6)

#### What's Changed

- Fix:(issue\_1668) Add test case for sub command of sub command
completion by [@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1747
- Update dependencies for v2 by
[@&#8203;meatballhat](https://togithub.com/meatballhat) in
[urfave/cli#1749
- Document slice flags as part of examples (v2) by
[@&#8203;carhartl](https://togithub.com/carhartl) in
[urfave/cli#1751

**Full Changelog**:
urfave/cli@v2.25.5...v2.25.6

### [`v2.25.5`](https://togithub.com/urfave/cli/releases/tag/v2.25.5)

[Compare
Source](https://togithub.com/urfave/cli/compare/v2.25.4...v2.25.5)

#### What's Changed

- Fix:(issue\_1737) Set bool count by taking care of num of aliases by
[@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1740

**Full Changelog**:
urfave/cli@v2.25.4...v2.25.5

### [`v2.25.4`](https://togithub.com/urfave/cli/releases/tag/v2.25.4)

[Compare
Source](https://togithub.com/urfave/cli/compare/v2.25.3...v2.25.4)

#### What's Changed

- Bug/fix issue 1703 by [@&#8203;jojje](https://togithub.com/jojje) in
[urfave/cli#1728
- Fix:(issue\_1734) Show categories for subcommands by
[@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1735
- Fix:(issue\_1610). Keep RunAsSubcommand behaviour as before by
[@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1736
- Fix:(issue\_1731) Add fix for checking if aliases are set by
[@&#8203;dearchap](https://togithub.com/dearchap) in
[urfave/cli#1732
- Fix func name referenced in doc comment by
[@&#8203;meatballhat](https://togithub.com/meatballhat) in
[urfave/cli#1738

#### New Contributors

- [@&#8203;jojje](https://togithub.com/jojje) made their first
contribution in
[urfave/cli#1728

**Full Changelog**:
urfave/cli@v2.25.3...v2.25.4

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/angular-static-server/angular-static-server).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi40My4yIiwidXBkYXRlZEluVmVyIjoiMzYuNDMuMiIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

v2 documentation: add a StringSliceFlag example to the manual
2 participants