GoSublime go to definition - go

Does go to definition work in GoSublime 2 or 3 ?
I get only
GsDoc: no docs found
It is mentioned that that feature is available
https://github.com/DisposaBoy/GoSublime
and documented
https://github.com/DisposaBoy/GoSublime/blob/master/USAGE.md
But I found similar error reports year or two years old.

This go to definition only works with expression pkgname.Funcname, but the design(general interaction) is not implemented.
By other way you must have the source code in the GOPATH or GOROOT, if not GoSublime cannot find your code.
You can read more about at:
https://github.com/DisposaBoy/GoSublime/issues/62

Have a look at GoGuru. I have made a blog post how to setup ST3 for golang development.

Related

Problem in setting the value of GOPATH on windows machine

My GOROOT path :-
C:\Go
I have set GOPATH to :-
C:\Users\kunal\go
But when I import modules (like github.com/gorilla/mux) inside VS Code. VS Code prompts me this error :-
could not import github.com/gorilla/mux (cannot find package "github.com/gorilla/mux" in any of C:\Go\src\github.com\gorilla\mux (from $GOROOT) C\src\github.com\gorilla\mux (from $GOPATH) \Users\kunal\go\src\github.com\gorilla\mux (from $GOPATH))
From above It is clear that it shows me two different GOPATH which I haven’t set. How do I fix this?
I recommend going through the following path, using official documentation pages:
Read about properly installing Go for your platform
Read the getting started tutorial which also tells you how to install 3rd-party packages and use them in your code.
It should take you no more than 20 minutes to go through these steps, and it's almost certain that you'll be able to accomplish your goal by the end of the process. As a bonus, keep going through the Getting Started guide beyond the first page to learn how to create your own Go modules, use them from other modules, write tests, build your code into a binary, and more.
This is IMHO the minimal background required to even try writing Go programs; without going through these steps, you will lack crucial fundamental understanding and it will be hard to even understand SO answers.
Specifically in your case - please remember that at this time (with Go 1.16), GOPATH is pretty much deprecated and you should be using Go modules instead. The documents linked to above will explain this in detail.
I ll give a TLDR for the solution given by #Eli Bendersky. If you don't understand GOPATH and go modules, you can look it up yourself here. Here I have assumed you are using VS Code with golang extension. I haven't tested it for other IDEs but it should work in a similiar way.
In the source directory where you have the main.go, create a file named go.mod
Name the package name to whatever you like and save the file.
go to your terminal and run go build main.go, this will download all the missing packages(if any) and will update the go.mod file and create a new file go.sum to create the checksums of the package versions.
All the package error squiggles should be gone by now in your IDE, if it doesn't try restarting your IDE once. You are good to go!
If you are stuck somewhere, let me know in the comments.
I just started to learn golang today. But it seems that I understood more from what these experts are trying to say when trying to answer this basic question.
I don't claim deep knowledge of golang. But as a 2100 rated chess player, I do claim common sense and rigorous thought process. The GOPATH environment variable is very much in use do not believe these kids. Only a kid would make such claims that GOPATH has no use.
The way I see it is that, the go.mod and go.sum plays in tandem with GOPATH.
Continue on your own journey, little tiger. I upvoted your question for moral support.

How do I generate documentation which displays files inline documentation in 1 column and code in another?

I've seen it before, but I can't remember which project or which documentor they used (if any).
I'm pretty sure it was a JS project, probably a Node.JS module.
Anyhow, the documentation was listed by file, and each page displayed as 2 columns, one with the inline documentation, and the other with the code.
Does anyone know which tools allow for this?
"Annotated Documentation" is what I was trying to think of!
The tool was docco.
The above link is docco's documentation as documented using docco.

What has happened to Dynamic LINQ?

I have a need to use dynamic LINQ where I can use variables in place of field names. Now I have done some googling and found that there is a sample for VS2008 where we can get this functionality.
My question is what has happened to this DLINQ ? It's been 4 years and I wonder whether it's made it into framework proper or some other new solutions have been invented to replace this? I only have my interest in DLINQ now so it is rather difficult to find further info on google, beside not knowing what exactly I am looking for other than 'better incarnation of DLINQ'. Can anyone shed some light?
This was never an "official" part of LINQ so has never been included in the framework.
The source was freely available and versions of it have appeared in CodePlex and on GitHub
The GitHub source appears to be the origin of the Nuget package
I've resurrected Dynamic LINQ, adding support for .NET 4.0/4.5, added support documentation (a work in progress), and added lots of new features.
Here is the link to the docs page, and from there, you can find the NuGet package and GitHub Project

What do I need to know to create Xcode project templates?

I know some of the tutorials for creating Xcode project templates, for example this one here: http://robnapier.net/blog/project-templates-364
This is the best one I could find. All others basically repeat the same info, or are no longer up to date, or worse tell me that even they don't know what they're doing. Possibly useful tools that are linked to here and in other places are no longer available.
I keep running into roadblocks, and would like to gather as much information as possible on the process of creating Xcode project templates. Info that is most importantly up to date (at least it must be relevant for Xcode 3 or higher).
For example, what I'd like to see is:
a description of the
TemplateChooser.plist and similar
plist files and what these options do
(in my case, once I add a
TemplateChooser.plist, my project
disappears from the Xcode project
template list)
how to create a project template that references another .xcodeproj (when I do that, the other .xcodeproj appears in the project template list even though it doesn't use the special naming convention)
processes that can be applied, for example is it possible to run a script during the creating of a project from a template? This would be useful to unzip certain files into the newly created project.
If you have the answer or suggestions to any of the issues above, I'd appreciate that. Otherwise any link to good Xcode project template resources would be highly recommended. Especially if there is an official documentation from Apple - I haven't found one yet which seems to imply that project templates are undocumented.
Have you seen these:
http://www.sodeso.nl/?p=895
http://www.codeproject.com/KB/iPhone/CreatingXcodeProject.aspx
If you say you have searched, I'm pretty sure you've already seen the links but these are the best resources I could find with my 'googlabilities'
You might try contact this guy - http://linkedin.com/in/mottishneor he has some related messages around the web
The links suggested by FX are also not bad at all!
There is indeed little XCode template info out there. What I have found of interest are the following links (I documented myself on the topic, but haven't yet gone any further):
a Google Code search reveals a few examples, but not much
in particular, I found interesting to look at the code provided by Three20; they have some basic examples, like here
referencing another project worked for me, so maybe you could open a specific question about that giving more details?
there is information scattered on the Apple mailing-lists
there is no official documentation from Apple, as is evidenced by the lack of results to this query
I'm sorry if this is not a Enlighting, concise answer. As you said, it's not well documented, and sources are all over the place. I just hope I could highlight some places to find information that your own searches might not have reached :)
I don't have a Mac anymore, so this is as much as I can give you without testing this myself. As far as I can tell, Xcode templates are undocumented by Apple.
This guy has some guides for messing with Xcode templates but the info is pretty sparse. My suggestion for working with templateChooser.plist is to try to only edit that file in the interface builder.
This guide is a good example of how to add a reference to another .xcodeproj. For the reason you were having trouble adding a reference to your project we probably need more information.
If you scroll way down in this doc you can that each template already includes a script called myscript.sh. This script will show up in the scripts menu for projects built with that template. That isn't quite as convenient as running scripts automatically, but it's better than nothing.
In conclusion, Xcode template documentation is a nightmare. It looks like there are a lot of powerful features there, but they are obscured because of lack of user friendlyness and because documentation lags far behind Apples updates of Xcode. It just doesn't seem to be a priority for them. I hope this helps.
And yet another video link http://howtomakeiphoneapps.com/2010/10/how-to-make-custom-xcode-templates-with-video/

Boost documentation problem

I'm trying to view the boost documentation at their website: http://www.boost.org/doc/
But it says Forbidden.
Any way I can download the documentation, or get past this error?
I'm getting a similar error from the front page for the link to the docs. However I vaguely remember that if you download the boost libraries, the tarball/zip contains a copy of the docs.
We've had some hosting problems related to the Boost documentation. Things should get resolved really soon. In fact at least the docs for the latest 2 releases are already up again (for me), see http://www.boost.org/doc/.

Resources