Theia Go Extension

Theia Go Extension

An extension for the Theia-IDE to support the Go language, using the Go language server.

Getting started

Install nvm.

curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.5/install.sh | bash

Install npm and node.

nvm install 8
nvm use 8

Install yarn.

npm install -g yarn

Running the browser example

yarn rebuild:browser
cd browser-app
yarn start

Open http://localhost:3000 in the browser.

Running the Electron example

yarn rebuild:electron
cd electron-app
yarn start

Developing with the browser example

Start watching of the hello world extension.

cd go-extension
yarn watch

Start watching of the browser example.

yarn rebuild:browser
cd browser-app
yarn watch

Launch Start Browser Backend configuration from VS code.

Open http://localhost:3000 in the browser.

Developing with the Electron example

Start watching of the hello world extension.

cd go-extension
yarn watch

Start watching of the electron example.

yarn rebuild:electron
cd electron-app
yarn watch

Launch Start Electron Backend configuration from VS code.

Publishing go-extension

Each change on master triggers a build on travis against Theia next. The resulting package is automatically published to as @theia/go:next.

For a release (or when Theia releases a new major), we have to build against Theia latest. To achieve that

rm yarn.lock               # make sure to re-install deps
sh theia-version.sh latest # set all dependencies to Theia to 'latest'
yarn                       # rebuild (don't forget!)
yarn run publish:latest    # publish
rm yarn.lock               # make sure to re-install deps
sh theia-version.sh next   # reset Theia dependencies to 'next'
yarn                       # make sure yarn-lock is reset to 'next'
git add -A
git commit -m 'Bumped version number'
Owner
theia-ide
Theia is a cloud & desktop IDE implemented in TypeScript
theia-ide
Comments
  • Add language config and textmate grammar

    Add language config and textmate grammar

    Theia no longer comes with basic go support, si this extension should register the language and add the grammar and configuration.

    see

    • https://github.com/Microsoft/monaco-languages/tree/master/src/go (language config)
    • https://github.com/Microsoft/vscode/tree/master/extensions/go/syntaxes (textmate grammar)
    • https://github.com/theia-ide/theia/pull/2253/commits/1b81563144d802580ade4863b8130119aac77d29 (example)
  • Go extension is slow and sometimes

    Go extension is slow and sometimes "eats" characters when typing quickly

    When Network is not very fast Theia becomes unusable and keyboard is no accepting input or the input is showing after delay.

    Maybe related: at times, it seems like the editor rolls-back some typed characters. We do not know for sure, but one hypothesis is that adverse network conditions causes some editor updates to be lost, after being echo'ed in the editor. e.g. you type "example" and see it in the editor, then the last few characters disappear and we are left with "examp".

  • on npm,

    on npm, "latest" published @theia/go tag maps to a "next" version

    I think the latest published version of this extension might be is wrong. I would expect it to map to version 0.3.x, but it seems it instead points to "0.4.0-next.eaea5735".

    $ npm view @theia/go | grep latest
      'dist-tags': { next: '0.4.0-next.5b821fb9', latest: '0.4.0-next.eaea5735' },
    

    This might be an issue if we have "latest" version of @theia/go, as a dependency of a theia application, as then it seems to transitively pulls the next version of @theia/core, which results in:

    image

    Example package.json:

    {
        "private": true,
        "dependencies": {
            "@theia/core": "latest",
            "@theia/cpp": "latest",
            "@theia/editor": "latest",
            "@theia/extension-manager": "latest",
            "@theia/file-search": "latest",
            "@theia/filesystem": "latest",
            "@theia/git": "latest",
            "@theia/java":"latest",
            "@theia/languages": "latest",
            "@theia/markers": "latest",
            "@theia/messages": "latest",
            "@theia/metrics": "latest",
            "@theia/monaco": "latest",
            "@theia/navigator": "latest",
            "@theia/outline-view": "latest",
            "@theia/preferences": "latest",
            "@theia/process": "latest",
            "@theia/python": "latest",
            "@theia/terminal": "latest",
            "@theia/typescript": "latest",
            "@theia/userstorage": "latest",
            "@theia/go": "latest"
        },
        "devDependencies": {
            "@theia/cli": "latest"
        }
    }
    
  • 'Go: show all commands' shows too many buttons

    'Go: show all commands' shows too many buttons

    'Show all commands' yields a list of all commands which are rendered as buttons. As they are too many, you can only see the some of them, the rest is outside the viewport.

  • Last build did not pass.

    Last build did not pass.

    It looks like the last build didn't pass: https://travis-ci.org/theia-ide/theia-php-extension/builds/499128046 would you please re-run the build so it will publish an updated package to npm?

  • Revise context menu and keybindings

    Revise context menu and keybindings

    Currently, the commands go into the context menu and are not bound to any keys. We should decide which commands should be in the menu, which should have keybindings

  • [commands] Adapt to global command registry

    [commands] Adapt to global command registry

    Theia/Monaco LC now uses a singleton command registry. As a consequence, our hooks to set labels and isVisible() on the server side commands are no longer called.

    As a result, Go editor context menu entries are visible on all editors, not just go, and the other commands don't appear in the quick command list, as they have no label.

  • Can't format code

    Can't format code

    Hello,

    I'm giving the extension a go (heh), but I haven't been able to format the code, automatically nor manually. Choosing Format document/selection doesn't seem to do anything - no errors either - although code intellisense seems to be working correctly. My gopath is set, and it includes the dependencies listed in the prerequisites for Go LSP. I'm running the latest versions ("next" tag), with Go 1.11.4. Am I doing something wrong or is there no formatting?

  • [config] Find a better default for GOPATH ?

    [config] Find a better default for GOPATH ?

    The command line tools the go LS delegates to needs GOPATH to be defined correctly to find references across files. By default, it assumes GOPATH=<home>/go. If you have your workspace located elsewhere, find references and other services relying on it (code lens, call hierarchy...) will not work across file borders.

    On the Go homepage they state "Go programmers typically keep all their Go code in a single workspace.". If that was true, a globally set GOPATH would suffice.

    Nevertheless, in the IDE scenario it appears that you are more likely to work with a local GOPATH pointing to your workspace root. That is why vscode/go allows to set it in the config in various ways. Our Go LS supports exactly that, so you can override it in

    • <home>/.go/go.json
    • <wsroot>/go.json
    • <wsfolder-root>/go.json (AFAIK, Theia does not support workspace folders yet,so this is 'for future use')

    e.g.

    {
        "inferGopath": true
    }
    

    Should we make that setting the default? I can imagine that it can also cause a lot of confusion for those users who stick to the Go recommendation. Go experts, what is your opinion?

Carbon for Golang, an extension for Time

Carbon A simple extension for Time based on PHP's Carbon library. Features: Time is embedded into Carbon (provides access to all of Time's functionali

Dec 20, 2022
Go extension for VS Code
Go extension for VS Code

Go for Visual Studio Code The VS Code Go extension provides rich language support for the Go programming language. Quick Start Welcome! ???? Whether y

Jan 7, 2023
kubequery is a Osquery extension that provides SQL based analytics for Kubernetes clusters

kubequery powered by Osquery kubequery is a Osquery extension that provides SQL based analytics for Kubernetes clusters kubequery will be packaged as

Dec 27, 2022
Clojure-esque extension language for Go.
Clojure-esque extension language for Go.

let-go Greetings loafers! (λ-gophers haha, get it?) This is supposed to be a compiler and bytecode VM for a language resembling Clojure as close as po

Jan 1, 2023
Client extension for interacting with Kubernetes clusters from your k6 tests.

⚠️ This is a proof of concept As this is a proof of concept, it won't be supported by the k6 team. It may also break in the future as xk6 evolves. USE

Jan 2, 2023
⚙️ A k6 extension for Tarantool

xk6-tarantool This is a k6 extension using the xk6 system. ❗ This is a proof of concept, isn't supported by the k6 team, and may break in the future.

Nov 29, 2022
Worker failover support for PostgreSQL Citus extension using pg_auto_failover.

citus-failover Worker failover support for citus community version using pg_auto_failover. What is this? This is a simple service to monitor changes i

Dec 7, 2022
Lambda Extension for iamlive

iamlive Lambda Extension The iamlive Lambda Extension helps generate a least-privilege IAM policy by monitoring the AWS calls made within the Lambda e

Dec 17, 2022
Kubernetes OS Server - Kubernetes Extension API server exposing OS configuration like sysctl via Kubernetes API

KOSS is a Extension API Server which exposes OS properties and functionality using Kubernetes API, so it can be accessed using e.g. kubectl. At the moment this is highly experimental and only managing sysctl is supported. To make things actually usable, you must run KOSS binary as root on the machine you will be managing.

May 19, 2021
k6 prometheus output extension

xk6-prometheus A k6 extension implements Prometheus HTTP exporter as k6 output extension. Using xk6-prometheus output extension you can collect metric

Nov 22, 2022
General Pod Autoscaler(GPA) is a extension for K8s HPA, which can be used not only for serving, also for game.
General Pod Autoscaler(GPA) is a extension for K8s HPA, which can be used not only for serving, also for game.

Introduction General Pod Autoscaler(GPA) is a extension for K8s HPA, which can be used not only for serving, also for game. Features Compatible with a

Aug 19, 2022
Standalone client for proxies of Windscribe browser extension

windscribe-proxy Standalone Windscribe proxy client. Younger brother of opera-proxy. Just run it and it'll start a plain HTTP proxy server forwarding

Dec 29, 2022
An extension for the GitHub Cli application that displays your current contribution graph
An extension for the GitHub Cli application that displays your current contribution graph

gh-graph An extension for the GitHub Cli application that displays your current contribution graph in the terminal (logged out contribution graph) Ins

Sep 29, 2021
An extension for discordgo to create a Discord bot quickly using the Builder pattern.

botbuilder An extension for discordgo to create a Discord bot quickly using the Builder pattern. Example usage: package main import ( "log" "os"

Oct 12, 2022
Small gh extension that suggests issues to work on in a given GitHub repository

gh contribute being a gh extension for finding issues to help with in a GitHub repository. This extension suggests an issue in a given repository to w

Dec 24, 2022
entviz is an ent extension that provides visualization of the schema graph
entviz is an ent extension that provides visualization of the schema graph

entviz entviz is an ent extension that creates visual graph (html file) of your ent's schema. install go get github.com/hedwigz/entviz add this exten

Dec 9, 2022
being a gh extension that runs animated terminal "screensavers"

gh-screensaver being a gh extension that runs animated terminal "screensavers" usage gh screensaver run a random screensaver gh screensaver -s pipes r

Nov 29, 2022
extension of SMx crypto support for go standard lib

Crypto Extension support of China crypto standards for go lib. You can simply copy and replace them to [your_go_src_path]/crypto Use as vendor is alte

Sep 21, 2022
gh extension for bumping version of a repository
gh extension for bumping version of a repository

gh bump a gh extension for bumping version of a repository. Usage gh bump with another repository. gh bump -R <repository> Installation gh extension

Dec 14, 2022
a gh extension that prints out an oblique strategy

gh-oblique being a gh extension that prints one of the oblique strategies install gh extension install vilmibm/gh-oblique run $ gh oblique Be dirty.

Dec 13, 2022