Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for Wf (0.12 sec)

  1. src/cmd/go/internal/modload/init.go

    func WriteWorkFile(path string, wf *modfile.WorkFile) error {
    	wf.SortBlocks()
    	wf.Cleanup()
    	out := modfile.Format(wf.Syntax)
    
    	return os.WriteFile(path, out, 0666)
    }
    
    // UpdateWorkGoVersion updates the go line in wf to be at least goVers,
    // reporting whether it changed the file.
    func UpdateWorkGoVersion(wf *modfile.WorkFile, goVers string) (changed bool) {
    	old := gover.FromGoWork(wf)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jun 06 18:36:30 UTC 2024
    - 69.8K bytes
    - Viewed (0)
  2. src/cmd/go/internal/modget/get.go

    	newReqs := reqsFromGoMod(modload.ModFile())
    	r.reportChanges(oldReqs, newReqs)
    
    	if gowork := modload.FindGoWork(base.Cwd()); gowork != "" {
    		wf, err := modload.ReadWorkFile(gowork)
    		if err == nil && modload.UpdateWorkGoVersion(wf, modload.MainModules.GoVersion()) {
    			modload.WriteWorkFile(gowork, wf)
    		}
    	}
    }
    
    // parseArgs parses command-line arguments and reports errors.
    //
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 18:26:32 UTC 2024
    - 66.5K bytes
    - Viewed (0)
Back to top