Last active
March 11, 2018 15:08
-
-
Save lambrospetrou/791aae8bd148f34c5290b541eced0583 to your computer and use it in GitHub Desktop.
Shebang for Go scripts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 2>/dev/null;/usr/bin/env go run $0 $@; exit $? | |
// Found at https://gist.github.com/posener/73ffd326d88483df6b1cb66e8ed1e0bd | |
package main | |
import "fmt" | |
// You can run the script with one of two ways | |
// 1. chmod +x test-script.go && ./test-script.go | |
// 2. go run test-script.go | |
func main() { | |
fmt.Println("vim-go") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment