Improving links (http -> https) (#425)
This commit is contained in:
committed by
GitHub
parent
25d2811293
commit
da13e2fbe7
@@ -1,5 +1,5 @@
|
||||
// Go provides built-in support for [base64
|
||||
// encoding/decoding](http://en.wikipedia.org/wiki/Base64).
|
||||
// encoding/decoding](https://en.wikipedia.org/wiki/Base64).
|
||||
|
||||
package main
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
cd00d89ad0a31e48d6a2e2adc2e8d65b0f70dc73
|
||||
S7ff3UgzNlG
|
||||
47f0317643bc5107af6fae64cb0fdad1260ead37
|
||||
yztzkirFEvv
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Go supports [_anonymous functions_](http://en.wikipedia.org/wiki/Anonymous_function),
|
||||
// which can form <a href="http://en.wikipedia.org/wiki/Closure_(computer_science)"><em>closures</em></a>.
|
||||
// Go supports [_anonymous functions_](https://en.wikipedia.org/wiki/Anonymous_function),
|
||||
// which can form <a href="https://en.wikipedia.org/wiki/Closure_(computer_science)"><em>closures</em></a>.
|
||||
// Anonymous functions are useful when you want to define
|
||||
// a function inline without having to name it.
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
6713bdbb6de0d7d484422517dd77316c8b9f0a7a
|
||||
66Lgw9iIIch
|
||||
6514e124c8127250a2eecfadc9708181e51f9603
|
||||
NpgpzS8ZG8y
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// [_Command-line arguments_](http://en.wikipedia.org/wiki/Command-line_interface#Arguments)
|
||||
// [_Command-line arguments_](https://en.wikipedia.org/wiki/Command-line_interface#Arguments)
|
||||
// are a common way to parameterize execution of programs.
|
||||
// For example, `go run hello.go` uses `run` and
|
||||
// `hello.go` arguments to the `go` program.
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
d60d1c9cb5dbbb748cf3b692334076951cea7d59
|
||||
oSxtj7v_v1K
|
||||
ad871e829d1457d97d0f1c1af77e39f6942ac5a5
|
||||
UYCEvh9d2Zb
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// [_Command-line flags_](http://en.wikipedia.org/wiki/Command-line_interface#Command-line_option)
|
||||
// [_Command-line flags_](https://en.wikipedia.org/wiki/Command-line_interface#Command-line_option)
|
||||
// are a common way to specify options for command-line
|
||||
// programs. For example, in `wc -l` the `-l` is a
|
||||
// command-line flag.
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
08e716a5ee3b5f74ef826d7b5ce157cb3b44c4f7
|
||||
-zzqphwtdJq
|
||||
9cca50e58f488570cc8e92dde37582ea5ee04bf3
|
||||
IUPZlYSigc3
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// [Environment variables](http://en.wikipedia.org/wiki/Environment_variable)
|
||||
// [Environment variables](https://en.wikipedia.org/wiki/Environment_variable)
|
||||
// are a universal mechanism for [conveying configuration
|
||||
// information to Unix programs](http://www.12factor.net/config).
|
||||
// information to Unix programs](https://www.12factor.net/config).
|
||||
// Let's look at how to set, get, and list environment variables.
|
||||
|
||||
package main
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
bee983e7820d64dec5331dc706c08f6135b5c632
|
||||
KuD8tDyB4lQ
|
||||
f480d3803659977183a4bc5c14da26c80b1d31fe
|
||||
2jmwXM264NC
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// A common requirement in programs is getting the number
|
||||
// of seconds, milliseconds, or nanoseconds since the
|
||||
// [Unix epoch](http://en.wikipedia.org/wiki/Unix_time).
|
||||
// [Unix epoch](https://en.wikipedia.org/wiki/Unix_time).
|
||||
// Here's how to do it in Go.
|
||||
|
||||
package main
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
54e66c2e84334f2adbf87aaeb62065111c5644ea
|
||||
iG_EcjJp4ss
|
||||
a67ae165a1f00c205a344327d9d638f4eb931b5c
|
||||
lRmD1EWHHPz
|
||||
|
||||
@@ -6,5 +6,5 @@ f2 failed: 42 - can't work with it
|
||||
42
|
||||
can't work with it
|
||||
|
||||
# See this [great post](http://blog.golang.org/2011/07/error-handling-and-go.html)
|
||||
# See this [great post](https://go.dev/blog/error-handling-and-go)
|
||||
# on the Go blog for more on error handling.
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
// completely replace the current Go process with another
|
||||
// (perhaps non-Go) one. To do this we'll use Go's
|
||||
// implementation of the classic
|
||||
// <a href="http://en.wikipedia.org/wiki/Exec_(operating_system)"><code>exec</code></a>
|
||||
// <a href="https://en.wikipedia.org/wiki/Exec_(operating_system)"><code>exec</code></a>
|
||||
// function.
|
||||
|
||||
package main
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
18867a0e743aaadb2aba0a0c7b1ca8098a1aa95c
|
||||
nI-HMuCI2lG
|
||||
568ae983493addff02d2ce8df57f41daf537f077
|
||||
s9qg7olf1dM
|
||||
|
||||
@@ -17,7 +17,7 @@ func main() {
|
||||
// object and calling its `Get` method; it uses the
|
||||
// `http.DefaultClient` object which has useful default
|
||||
// settings.
|
||||
resp, err := http.Get("http://gobyexample.com")
|
||||
resp, err := http.Get("https://gobyexample.com")
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
fbc80f8cfcd34e9daa3c52c23f6720f6ef7019dc
|
||||
kHCcVLoz7nd
|
||||
1497e193431e4740f593039f613773daaf97772e
|
||||
vFW_el7oHMk
|
||||
|
||||
@@ -3,6 +3,6 @@ $ go run if-else.go
|
||||
8 is divisible by 4
|
||||
9 has 1 digit
|
||||
|
||||
# There is no [ternary if](http://en.wikipedia.org/wiki/%3F:)
|
||||
# There is no [ternary if](https://en.wikipedia.org/wiki/%3F:)
|
||||
# in Go, so you'll need to use a full `if` statement even
|
||||
# for basic conditions.
|
||||
|
||||
@@ -7,4 +7,4 @@ $ go run interfaces.go
|
||||
31.41592653589793
|
||||
|
||||
# To learn more about Go's interfaces, check out this
|
||||
# [great blog post](http://jordanorelli.tumblr.com/post/32665860244/how-to-use-interfaces-in-go).
|
||||
# [great blog post](https://jordanorelli.tumblr.com/post/32665860244/how-to-use-interfaces-in-go).
|
||||
|
||||
@@ -16,6 +16,6 @@ apple
|
||||
|
||||
|
||||
# We've covered the basic of JSON in Go here, but check
|
||||
# out the [JSON and Go](http://blog.golang.org/2011/01/json-and-go.html)
|
||||
# blog post and [JSON package docs](http://golang.org/pkg/encoding/json/)
|
||||
# out the [JSON and Go](https://go.dev/blog/json)
|
||||
# blog post and [JSON package docs](https://pkg.go.dev/encoding/json)
|
||||
# for more.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// _Maps_ are Go's built-in [associative data type](http://en.wikipedia.org/wiki/Associative_array)
|
||||
// _Maps_ are Go's built-in [associative data type](https://en.wikipedia.org/wiki/Associative_array)
|
||||
// (sometimes called _hashes_ or _dicts_ in other languages).
|
||||
|
||||
package main
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
9e0e4535c99668b460c7175f8ff2edc2ccf58bec
|
||||
agK2Ro2i-Lu
|
||||
22d147fe9402f9ff210f12b9810811c07f4d64ca
|
||||
ulCzODwCde_0
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// In the previous example we saw how to manage simple
|
||||
// counter state using [atomic operations](atomic-counters).
|
||||
// For more complex state we can use a [_mutex_](http://en.wikipedia.org/wiki/Mutual_exclusion)
|
||||
// For more complex state we can use a [_mutex_](https://en.wikipedia.org/wiki/Mutual_exclusion)
|
||||
// to safely access data across multiple goroutines.
|
||||
|
||||
package main
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
3688453f408d8c7cc6db91ab7fd5e0ac06ade7ea
|
||||
tDqeib2-yZA
|
||||
a437476f37f1f797e1bab491b3f2ac9b386f6700
|
||||
Kr_cdza5vyz
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Go supports <em><a href="http://en.wikipedia.org/wiki/Pointer_(computer_programming)">pointers</a></em>,
|
||||
// Go supports <em><a href="https://en.wikipedia.org/wiki/Pointer_(computer_programming)">pointers</a></em>,
|
||||
// allowing you to pass references to values and records
|
||||
// within your program.
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
c727916063ddc3e99199cd24bfbde37ff301c0b4
|
||||
oimmXypnAcs
|
||||
7f9855cfb983efc07415117e2be734f55a6bb64b
|
||||
OlWCLpxAyBz
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Go's `math/rand` package provides
|
||||
// [pseudorandom number](http://en.wikipedia.org/wiki/Pseudorandom_number_generator)
|
||||
// [pseudorandom number](https://en.wikipedia.org/wiki/Pseudorandom_number_generator)
|
||||
// generation.
|
||||
|
||||
package main
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
102041ca421268afbd4b4e7687386bb65a8c7965
|
||||
PGklfJzErTN
|
||||
f0f88939692a32975d902c94066537a6ba5ab96f
|
||||
RaoKyUd9tgC
|
||||
|
||||
@@ -7,6 +7,6 @@ $ go run random-numbers.go
|
||||
5,87
|
||||
|
||||
|
||||
# See the [`math/rand`](http://golang.org/pkg/math/rand/)
|
||||
# See the [`math/rand`](https://pkg.go.dev/math/rand)
|
||||
# package docs for references on other random quantities
|
||||
# that Go can provide.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// [_Rate limiting_](http://en.wikipedia.org/wiki/Rate_limiting)
|
||||
// [_Rate limiting_](https://en.wikipedia.org/wiki/Rate_limiting)
|
||||
// is an important mechanism for controlling resource
|
||||
// utilization and maintaining quality of service. Go
|
||||
// elegantly supports rate limiting with goroutines,
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
c7063265708287744ea172ed9ed1390043140718
|
||||
GXjXHfnKFXg
|
||||
4f327f5bd5ac199ae5590652563ea6ca4ce7eff5
|
||||
lqf7pC2FUeT
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Go supports
|
||||
// <a href="http://en.wikipedia.org/wiki/Recursion_(computer_science)"><em>recursive functions</em></a>.
|
||||
// <a href="https://en.wikipedia.org/wiki/Recursion_(computer_science)"><em>recursive functions</em></a>.
|
||||
// Here's a classic example.
|
||||
|
||||
package main
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
9ac9b5af828c33eb20dd322fd1a991334242c4b3
|
||||
7hD-3-bIuSp
|
||||
cdbd1a6957b3e2d7d9baa9efe4581ba4f8f3e753
|
||||
MBTKk9VpAiK
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// Go offers built-in support for [regular expressions](http://en.wikipedia.org/wiki/Regular_expression).
|
||||
// Go offers built-in support for [regular expressions](https://en.wikipedia.org/wiki/Regular_expression).
|
||||
// Here are some examples of common regexp-related tasks
|
||||
// in Go.
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
5c3bcf9f8c61fc074143f766c4517e445a6d9b0f
|
||||
htCqJrLdh9Q
|
||||
7fd60a9497546cb5c84242276ed79aecbde7e950
|
||||
fI2YIfYsCaL
|
||||
|
||||
@@ -14,4 +14,4 @@ a <fruit>
|
||||
a PEACH
|
||||
|
||||
# For a complete reference on Go regular expressions check
|
||||
# the [`regexp`](http://golang.org/pkg/regexp/) package docs.
|
||||
# the [`regexp`](https://pkg.go.dev/regexp) package docs.
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Sometimes we'd like our Go programs to intelligently
|
||||
// handle [Unix signals](http://en.wikipedia.org/wiki/Unix_signal).
|
||||
// handle [Unix signals](https://en.wikipedia.org/wiki/Unix_signal).
|
||||
// For example, we might want a server to gracefully
|
||||
// shutdown when it receives a `SIGTERM`, or a command-line
|
||||
// tool to stop processing input if it receives a `SIGINT`.
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
cd15508731199185f3205692af0f80cbdee4fcd7
|
||||
LauPuRo3v9l
|
||||
739d6c0e33656817de5701412fe266c51730b532
|
||||
RKLAbvblJMQ
|
||||
|
||||
@@ -13,7 +13,7 @@ sl3: [c d e f]
|
||||
dcl: [g h i]
|
||||
2d: [[0] [1 2] [2 3 4]]
|
||||
|
||||
# Check out this [great blog post](http://blog.golang.org/2011/01/go-slices-usage-and-internals.html)
|
||||
# Check out this [great blog post](https://go.dev/blog/slices-intro)
|
||||
# by the Go team for more details on the design and
|
||||
# implementation of slices in Go.
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ func main() {
|
||||
// package, not methods on the string object itself,
|
||||
// we need pass the string in question as the first
|
||||
// argument to the function. You can find more
|
||||
// functions in the [`strings`](http://golang.org/pkg/strings/)
|
||||
// functions in the [`strings`](https://pkg.go.dev/strings)
|
||||
// package docs.
|
||||
p("Contains: ", s.Contains("test", "es"))
|
||||
p("Count: ", s.Count("test", "t"))
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
e52d4023b8102ba47f3f97e67e47da1bfe393e6c
|
||||
mdta6dlNB6e
|
||||
a8fc7e03fd17f6d432adf2f0e991461630ce4350
|
||||
DSKkoyx9Rcy
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
// [_Variadic functions_](http://en.wikipedia.org/wiki/Variadic_function)
|
||||
// [_Variadic functions_](https://en.wikipedia.org/wiki/Variadic_function)
|
||||
// can be called with any number of trailing arguments.
|
||||
// For example, `fmt.Println` is a common variadic
|
||||
// function.
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
560aaef6ce8867710f3ef609b1bb2317377a71bf
|
||||
Ua6kZOMabBp
|
||||
dd2e819d49c1110c7eb7dc198b62e0994e0ba93e
|
||||
7_-i75JEsmM
|
||||
|
||||
Reference in New Issue
Block a user