waigani / GoOracle

GoOracle is a Golang plugin for SublimeText that integrates the Go oracle tool.
MIT License
73 stars 17 forks source link

GoOracle Setting is not configurable On Mac Sublime3 #16

Closed ypwu1 closed 3 years ago

ypwu1 commented 9 years ago

GoOracle Setting is not configurable On Mac Sublime3. config file can be open but just read only.

kylebrandt commented 9 years ago

Same problem

nfiniteset commented 9 years ago

I ran into the same problem. To get around it save this stuff:

{
  // Example settings. Replace these with your own.
  // "env": {},
  // "oracle_scope": ["github.com/juju/juju/cmd/juju", "github.com/juju/juju/cmd/jujud"],
  // "oracle_format": "",
}

into a new file here:

~/Library/Application Support/Sublime Text 3/Packages/GoOracle/User.sublime-settings
gobijan commented 9 years ago

Same Problem here... Needs to be fixed I guess :+1:

jasdel commented 9 years ago

Same issue with Ubuntu 14.04 & SublimeText 3

~/.config/sublime-text-3/Packages/GoOracle/User.sublime-settings
brakmic commented 9 years ago

Windows 8.1 & ST3 too

brakmic commented 9 years ago

Windows users should do this:

a) first, unpack the GoOracle.sublime-package in AppData\Roaming\Sublime...\Installed Packages directory b) then modify the User.sublime.settings c) Compress the modified settings file plus all other files into a new package called GoOracle.sublime-package but DO NOT put those files into a new directory. Just create a new package with all the files bundled in. Also don't use any kind of compression: simply save them.

Now you can use GoOracle with your individual settings applied.

hkic commented 9 years ago

(Tested on ST3 and Mac Yosemite)

To run GoOracle properly and SAVE YOUR TIME!

  1. Install must-have components go get golang.org/x/tools/oracle go get golang.org/x/tools/cmd/oracle

    Otherwise, oracle not found.

  2. Create and Save user setting file (refer to above @nfiniteset workaround)

    Mac: ~/Library/Application Support/Sublime Text 3/Packages/GoOracle/User.sublime-settings

    Must-have settings: Change PATH accordingly. oracle_scope is path under $GOPATH/src/.

    • It can be specified for individual project: @dr2chase solution
    • But you can also manually change the oracle_scope for each project

      {
      "env": { "GOPATH": "$HOME/Go", "GOROOT": "/usr/local/opt/go/libexec", "PATH": "$GOROOT/bin:$GOPATH/bin:$PATH" },
      "oracle_scope": ["projects/myproj"],
      }

    Otherwise, get stuck in "Running oracle callees command..." and no output returned. "View">"Show Console" shows console error. Traceback (most recent call last): File "goOracle in /Users/gopher/Library/Application Support/Sublime Text 3/Installed Packages/GoOracle.sublime-package", line 46, in on_done File "goOracle in /Users/gopher/Library/Application Support/Sublime Text 3/Installed Packages/GoOracle.sublime-package", line 115, in oracle TypeError GoOracle issue: Oracle never returns

    Otherwise, cgo failed: exec: "go": executable file not found in $PATH Related: Oracle invocation error

ikandaswamy commented 8 years ago

Is there any update on this issue ? I recently tried to use Go oracle with Sublime text 3 on osx and i keep hitting the error oracle: no packages specified for pointer analysis scope.

I manually downloaded the go-oracle package into my Packages dir for Sublime text 3, edited the user settings. Still get the above error.

Does anyone have a solution to this issue ?