Skip to content

Commit

Permalink
docs: autoupdate
Browse files Browse the repository at this point in the history
  • Loading branch information
MarvinJWendt committed Jul 22, 2022
1 parent d436318 commit 8acc75a
Show file tree
Hide file tree
Showing 41 changed files with 130 additions and 36 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
@@ -1,6 +1,9 @@
<a name="unreleased"></a>
## [Unreleased]


<a name="v0.12.43"></a>
## [v0.12.43] - 2022-07-17
### Bug Fixes
- **spinner:** fix line didn't clear properly
- **table:** fixed column length calculation for Chinese strings
Expand Down Expand Up @@ -1016,7 +1019,8 @@ removed `Header` and put it's content directly into `HeaderPrinter`
- initial commit


[Unreleased]: https://github.com/pterm/pterm/compare/v0.12.42...HEAD
[Unreleased]: https://github.com/pterm/pterm/compare/v0.12.43...HEAD
[v0.12.43]: https://github.com/pterm/pterm/compare/v0.12.42...v0.12.43
[v0.12.42]: https://github.com/pterm/pterm/compare/v0.12.41...v0.12.42
[v0.12.41]: https://github.com/pterm/pterm/compare/v0.12.40...v0.12.41
[v0.12.40]: https://github.com/pterm/pterm/compare/v0.12.39...v0.12.40
Expand Down
18 changes: 18 additions & 0 deletions README.md
Expand Up @@ -1394,6 +1394,11 @@ import (
)

func main() {
// Create and start a fork of the default spinner.
spinnerInfo, _ := pterm.DefaultSpinner.Start("Some informational action...")
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
spinnerInfo.Info() // Resolve spinner with error message.

// Create and start a fork of the default spinner.
spinnerSuccess, _ := pterm.DefaultSpinner.Start("Doing something important... (will succeed)")
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
Expand All @@ -1409,6 +1414,19 @@ func main() {
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
spinnerFail.Fail() // Resolve spinner with error message.

// Create and start a fork of the default spinner.
spinnerNochange, _ := pterm.DefaultSpinner.Start("Checking something important... (will result in no change)")
// Replace the InfoPrinter with a custom "NOCHG" one
spinnerNochange.InfoPrinter = &pterm.PrefixPrinter{
MessageStyle: &pterm.Style{pterm.FgLightBlue},
Prefix: pterm.Prefix{
Style: &pterm.Style{pterm.FgBlack, pterm.BgLightBlue},
Text: " NOCHG ",
},
}
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
spinnerNochange.Info("No change were required") // Resolve spinner with error message.

// Create and start a fork of the default spinner.
spinnerLiveText, _ := pterm.DefaultSpinner.Start("Doing a lot of stuff...")
time.Sleep(time.Second) // Simulate 2 seconds of processing something.
Expand Down
18 changes: 18 additions & 0 deletions _examples/README.md
Expand Up @@ -1266,6 +1266,11 @@ import (
)

func main() {
// Create and start a fork of the default spinner.
spinnerInfo, _ := pterm.DefaultSpinner.Start("Some informational action...")
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
spinnerInfo.Info() // Resolve spinner with error message.

// Create and start a fork of the default spinner.
spinnerSuccess, _ := pterm.DefaultSpinner.Start("Doing something important... (will succeed)")
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
Expand All @@ -1281,6 +1286,19 @@ func main() {
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
spinnerFail.Fail() // Resolve spinner with error message.

// Create and start a fork of the default spinner.
spinnerNochange, _ := pterm.DefaultSpinner.Start("Checking something important... (will result in no change)")
// Replace the InfoPrinter with a custom "NOCHG" one
spinnerNochange.InfoPrinter = &pterm.PrefixPrinter{
MessageStyle: &pterm.Style{pterm.FgLightBlue},
Prefix: pterm.Prefix{
Style: &pterm.Style{pterm.FgBlack, pterm.BgLightBlue},
Text: " NOCHG ",
},
}
time.Sleep(time.Second * 2) // Simulate 3 seconds of processing something.
spinnerNochange.Info("No change were required") // Resolve spinner with error message.

// Create and start a fork of the default spinner.
spinnerLiveText, _ := pterm.DefaultSpinner.Start("Doing a lot of stuff...")
time.Sleep(time.Second) // Simulate 2 seconds of processing something.
Expand Down
2 changes: 1 addition & 1 deletion _examples/area/demo/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/barchart/demo/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/barchart/mixed-values/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/barchart/negative-values/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/basictext/demo/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/bigtext/demo/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/box/demo/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/bulletlist/customized/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion _examples/bulletlist/demo/animation.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 8acc75a

Please sign in to comment.