Skip to content

Commit

Permalink
Merge pull request #2754 from alexandear/correct-typos
Browse files Browse the repository at this point in the history
Correct typos in comments
  • Loading branch information
AkihiroSuda authored Oct 17, 2024
2 parents 5c1975c + fe4ab4d commit 47916aa
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 15 deletions.
12 changes: 6 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ ENVS__output/bin/limactl$(exe) = CGO_ENABLED=1 GOOS=$(GOOS) GOARCH=$(GOARCH) CC=

_output/bin/limactl$(exe): $(LIMACTL_DEPS) $$(call force_build,$$@)
# If the previous cross-compilation was for GOOS=windows, limactl.exe might still be present.
ifneq ($(GOOS),windows) #
ifneq ($(GOOS),windows) #
@rm -rf _output/bin/limactl.exe
else
@rm -rf _output/bin/limactl
Expand Down Expand Up @@ -254,7 +254,7 @@ MKDIR_TARGETS += _output/bin
# _output/share/lima/lima-guestagent
LINUX_GUESTAGENT_PATH_COMMON = _output/share/lima/lima-guestagent.Linux-

# How to add architecure specific guestagent:
# How to add architecture specific guestagent:
# 1. Add the architecture to GUESTAGENT_ARCHS
# 2. Add ENVS_$(LINUX_GUESTAGENT_PATH_COMMON)<arch> to set GOOS, GOARCH, and other necessary environment variables
GUESTAGENT_ARCHS = aarch64 armv7l riscv64 x86_64
Expand Down Expand Up @@ -395,8 +395,8 @@ native_compiling = $(if $(cross_compiling),,true)
################################################################################
# _output/share/man/man1
.PHONY: manpages
# Set limactl.1 as explicit dependency.
# It's uncertain how many manpages will be generated by `make`,
# Set limactl.1 as explicit dependency.
# It's uncertain how many manpages will be generated by `make`,
# because `limactl` generates them without corresponding source code for the manpages.
manpages: _output/share/man/man1/limactl.1
_output/share/man/man1/limactl.1: _output/bin/limactl$(exe)
Expand All @@ -410,7 +410,7 @@ endif
################################################################################
.PHONY: docsy
# Set limactl.md as explicit dependency.
# It's uncertain how many docsy pages will be generated by `make`,
# It's uncertain how many docsy pages will be generated by `make`,
# because `limactl` generates them without corresponding source code for the docsy pages.
docsy: website/_output/docsy/limactl.md
website/_output/docsy/limactl.md: _output/bin/limactl$(exe)
Expand Down Expand Up @@ -488,7 +488,7 @@ generate:
# returns the capitalized string of $(1).
capitalize = $(shell echo "$(1)"|awk '{print toupper(substr($$0,1,1)) tolower(substr($$0,2))}')

# returns the architecture name converted from GOARCH to GNU coreutils uname -m.
# returns the architecture name converted from GOARCH to GNU coreutils uname -m.
to_uname_m = $(foreach arch,$(1),$(shell echo $(arch) | sed 's/amd64/x86_64/' | sed 's/arm64/aarch64/'))

ARTIFACT_FILE_EXTENSIONS := .tar.gz
Expand Down
2 changes: 1 addition & 1 deletion pkg/downloader/downloader.go
Original file line number Diff line number Diff line change
Expand Up @@ -690,7 +690,7 @@ func downloadHTTP(ctx context.Context, localPath, lastModified, contentType, url

var tempfileCount atomic.Uint64

// To allow parallel download we use a per-process unique suffix for tempoary
// To allow parallel download we use a per-process unique suffix for temporary
// files. Renaming the temporary file to the final file is safe without
// synchronization on posix.
// To make it easy to test we also include a counter ensuring that each
Expand Down
2 changes: 1 addition & 1 deletion pkg/downloader/downloader_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ type downloadResult struct {
}

// We expect only few parallel downloads. Testing with larger number to find
// races quicker. 20 parallel downloads take about 120 milliseocnds on M1 Pro.
// races quicker. 20 parallel downloads take about 120 milliseconds on M1 Pro.
const parallelDownloads = 20

// When downloading in parallel usually all downloads completed with
Expand Down
2 changes: 1 addition & 1 deletion pkg/instance/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ func ShowMessage(inst *store.Instance) error {
scanner := bufio.NewScanner(&b)
logrus.Infof("Message from the instance %q:", inst.Name)
for scanner.Scan() {
// Avoid prepending logrus "INFO" header, for ease of copypasting
// Avoid prepending logrus "INFO" header, for ease of copy pasting
fmt.Println(scanner.Text())
}
return scanner.Err()
Expand Down
2 changes: 1 addition & 1 deletion pkg/nativeimgutil/nativeimgutil.go
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ func ConvertToRaw(source, dest string, size *int64, allowSourceWithBackingFile b
defer destTmpF.Close()

// Truncating before copy eliminates the seeks during copy and provide a
// hint to the file system that may minimize allocations and fragmanation
// hint to the file system that may minimize allocations and fragmentation
// of the file.
if err := MakeSparse(destTmpF, srcImg.Size()); err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion pkg/usrlocalsharelima/usrlocalsharelima.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ func Dir() (string, error) {
// TODO: support custom path
}
if debugutil.Debug {
// candidate 2: lauched by `~/go/bin/dlv dap`
// candidate 2: launched by `~/go/bin/dlv dap`
// - self: ${workspaceFolder}/cmd/limactl/__debug_bin_XXXXXX
// - agent: ${workspaceFolder}/_output/share/lima/lima-guestagent.Linux-x86_64
// - dir: ${workspaceFolder}/_output/share/lima
Expand Down
2 changes: 1 addition & 1 deletion pkg/vz/network_darwin.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ type qemuPacketConn struct {
}

// Read reads a QEMU packet and returns the contained raw packet. Returns (len,
// nil) if a packet was read, and (0, err) on error. Errors means the prorocol
// nil) if a packet was read, and (0, err) on error. Errors means the protocol
// is broken and the socket must be closed.
func (c *qemuPacketConn) Read(b []byte) (n int, err error) {
var size uint32
Expand Down
2 changes: 1 addition & 1 deletion pkg/vz/network_darwin_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ func TestDialQemu(t *testing.T) {
}
}
}
t.Logf("Recived and verified %d data packets", packetsCount)
t.Logf("Received and verified %d data packets", packetsCount)

for i := 0; i < 2; i++ {
err := <-errc
Expand Down
4 changes: 2 additions & 2 deletions pkg/windows/registry_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const (
wslDistroInfoPrefix = `SOFTWARE\Microsoft\Windows\CurrentVersion\Lxss`
)

// AddVSockRegistryKey makes a vsock server running on the host acceessible in guests.
// AddVSockRegistryKey makes a vsock server running on the host accessible in guests.
func AddVSockRegistryKey(port int) error {
rootKey, err := getGuestCommunicationServicesKey(true)
if err != nil {
Expand Down Expand Up @@ -74,7 +74,7 @@ func RemoveVSockRegistryKey(port int) error {
return nil
}

// IsVSockPortFree determines if a VSock port has been registiered already.
// IsVSockPortFree determines if a VSock port has been registered already.
func IsVSockPortFree(port int) (bool, error) {
rootKey, err := getGuestCommunicationServicesKey(false)
if err != nil {
Expand Down

0 comments on commit 47916aa

Please sign in to comment.