From bbd932c5385c7c927f311eb8d772b86c465cba82 Mon Sep 17 00:00:00 2001 From: DisposaBoy Date: Mon, 2 Jan 2012 19:01:07 +0000 Subject: [PATCH] - add new example build system configs --- README.md | 2 +- USAGE.md | 4 ++++ examples/Go build.sublime-build.example | 5 +++++ examples/Go-Gb.sublime-build.example | 5 +++++ examples/Goinstall.sublime-build.example | 5 +++++ 5 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 examples/Go build.sublime-build.example create mode 100644 examples/Go-Gb.sublime-build.example create mode 100644 examples/Goinstall.sublime-build.example diff --git a/README.md b/README.md index 15f51fd5..a6814c11 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ Features * code completion from [Gocode](https://github.com/nsf/gocode) * context aware snippets via the code-completion popup to complement the existing SublimeText Go package. -* a sublime build system(ctrl+b) for gomake including support for cycling errors with F4/Shift+F4 +* sublime build system(ctrl+b) for gomake, go build, goinstall and [gb](https://github.com/skelterjohn/go-gb) including support for cycling errors with F4/Shift+F4 * gotype support with errors highlighted in the editor view * gofmt support for quickly reformatting your source to conform with the Go standards * automatic code completion popup when you press dot(.) diff --git a/USAGE.md b/USAGE.md index bf9ff2fc..76d8cfb3 100644 --- a/USAGE.md +++ b/USAGE.md @@ -67,6 +67,8 @@ A sample file is provided in `Packages/GoSublime/examples/Default.sublime-keymap Build System ------------ +A number of build system configs are provided which covers gomake, go build, goinstall and [gb](https://github.com/skelterjohn/go-gb). + The gomake build system enables Sublime Text 2 to recognize the 5g/6g/8g output so you can jump to compile errors by clicking on the output or cycle through them by using F4/Shift+F4. If you want to use the gomake build system you will have to copy the file `Packages/GoSublime/examples/Gomake.sublime-build.example` to `Packages/GoSublime/Gomake.sublime-build`. @@ -75,6 +77,8 @@ If gomake is not in your system path you will have to add the following key/valu "path": "/path/to/go/bin:$PATH", +The instructions above apply to all example build system configs in `Packages/GoSublime/examples/[BUILD SYSTEM].sublime-build.example`. + Gofmt ----- diff --git a/examples/Go build.sublime-build.example b/examples/Go build.sublime-build.example new file mode 100644 index 00000000..7b180442 --- /dev/null +++ b/examples/Go build.sublime-build.example @@ -0,0 +1,5 @@ +{ + "cmd": ["go", "build"], + "file_regex": "^(.+):([0-9]+):.*", + "selector": "source.go" +} \ No newline at end of file diff --git a/examples/Go-Gb.sublime-build.example b/examples/Go-Gb.sublime-build.example new file mode 100644 index 00000000..fd63a1ac --- /dev/null +++ b/examples/Go-Gb.sublime-build.example @@ -0,0 +1,5 @@ +{ + "cmd": "gb", + "file_regex": "^(.+):([0-9]+):.*", + "selector": "source.go" +} \ No newline at end of file diff --git a/examples/Goinstall.sublime-build.example b/examples/Goinstall.sublime-build.example new file mode 100644 index 00000000..b0a41b3d --- /dev/null +++ b/examples/Goinstall.sublime-build.example @@ -0,0 +1,5 @@ +{ + "cmd": ["goinstall", "."], + "file_regex": "^(.+):([0-9]+):.*", + "selector": "source.go" +} \ No newline at end of file