mirror of
https://github.com/kevin-DL/revel-cmd.git
synced 2026-01-11 18:54:31 +00:00
Upatede Error type to SourceError
Added processor object to code Verified compile errors appearing Signed-off-by: notzippy@gmail.com
This commit is contained in:
@@ -85,7 +85,7 @@ func (pc *processContainer) processPath(path string, info os.FileInfo, err error
|
||||
if err != nil {
|
||||
if errList, ok := err.(scanner.ErrorList); ok {
|
||||
var pos = errList[0].Pos
|
||||
newError := &utils.Error{
|
||||
newError := &utils.SourceError{
|
||||
SourceType: ".go source",
|
||||
Title: "Go Compilation Error",
|
||||
Path: pos.Filename,
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
package parser
|
||||
|
||||
import (
|
||||
//"golang.org/x/tools/go/packages"
|
||||
//"github.com/revel/cmd/utils"
|
||||
)
|
||||
//import "golang.org/x/tools/go/packages"
|
||||
//
|
||||
//func GetPackage(appPath, importPath string) {
|
||||
// config := &packages.Config{
|
||||
// Mode: packages.NeedName | packages.NeedFiles,
|
||||
// Dir:appPath,
|
||||
// }
|
||||
//
|
||||
// pkgs, err := packages.Load(config, []string{importPath})
|
||||
// utils.Logger.Info("Loaded packegs ", "len results", len(pkgs), "error",err)
|
||||
//
|
||||
//}
|
||||
Reference in New Issue
Block a user