浏览代码

Resolve a few typos in documentation

Chris Waldon 7 年之前
父节点
当前提交
14c1a17d77
共有 3 个文件被更改,包括 10 次插入10 次删除
  1. 1 1
      clean.go
  2. 5 5
      upgrade.go
  3. 4 4
      vcs.go

+ 1 - 1
clean.go

@@ -32,7 +32,7 @@ func removeVCSPackage(pkgs []string) {
 	return
 }
 
-// CleanDependencies removels all dangling dependencies in system
+// CleanDependencies removes all dangling dependencies in system
 func cleanDependencies(pkgs []string) error {
 	hanging, err := hangingPackages()
 	if err != nil {

+ 5 - 5
upgrade.go

@@ -22,7 +22,7 @@ type upgrade struct {
 	RemoteVersion string
 }
 
-// Slice is a slice of Upgrades
+// upSlice is a slice of Upgrades
 type upSlice []upgrade
 
 func (u upSlice) Len() int      { return len(u) }
@@ -92,7 +92,7 @@ func (u upSlice) Print(start int) {
 	}
 }
 
-// List returns lists of packages to upgrade from each source.
+// upList returns lists of packages to upgrade from each source.
 func upList() (aurUp upSlice, repoUp upSlice, err error) {
 	local, remote, _, remoteNames, err := filterPackages()
 	if err != nil {
@@ -141,7 +141,7 @@ loop:
 	return
 }
 
-// aur gathers foreign packages and checks if they have new versions.
+// upAUR gathers foreign packages and checks if they have new versions.
 // Output: Upgrade type package list.
 func upAUR(remote []alpm.Package, remoteNames []string) (toUpgrade upSlice, err error) {
 	var j int
@@ -204,7 +204,7 @@ func upAUR(remote []alpm.Package, remoteNames []string) (toUpgrade upSlice, err
 	}
 }
 
-// repo gathers local packages and checks if they have new versions.
+// upRepo gathers local packages and checks if they have new versions.
 // Output: Upgrade type package list.
 func upRepo(local []alpm.Package) (upSlice, error) {
 	dbList, err := AlpmHandle.SyncDbs()
@@ -241,7 +241,7 @@ primeloop:
 	return slice, nil
 }
 
-// Upgrade handles updating the cache and installing updates.
+// upgradePkgs handles updating the cache and installing updates.
 func upgradePkgs(flags []string) error {
 	aurUp, repoUp, err := upList()
 	if err != nil {

+ 4 - 4
vcs.go

@@ -30,7 +30,7 @@ type Info struct {
 
 type infos []Info
 
-// CreateDevelDB forces yay to create a DB of the existing development packages
+// createDevelDB forces yay to create a DB of the existing development packages
 func createDevelDB() error {
 	_, _, _, remoteNames, err := filterPackages()
 	if err != nil {
@@ -43,7 +43,7 @@ func createDevelDB() error {
 	return err
 }
 
-// ParseSource returns owner and repo from source
+// parseSource returns owner and repo from source
 func parseSource(source string) (owner string, repo string) {
 	if !(strings.Contains(source, "git://") ||
 		strings.Contains(source, ".git") ||
@@ -90,7 +90,7 @@ func (info *Info) needsUpdate() bool {
 	return false
 }
 
-// CheckUpdates returns list of outdated packages
+// checkUpdates returns list of outdated packages
 func checkUpdates(foreign map[string]alpm.Package) (toUpdate []string) {
 	for _, e := range savedInfo {
 		if e.needsUpdate() {
@@ -113,7 +113,7 @@ func inStore(pkgName string) *Info {
 	return nil
 }
 
-// BranchInfo updates saved information
+// branchInfo updates saved information
 func branchInfo(pkgName string, owner string, repo string) (err error) {
 	updated = true
 	var newRepo branches