Created
October 1, 2015 09:30
-
-
Save kosh04/3949827de5b36d8bfdee to your computer and use it in GitHub Desktop.
Go Playground をコマンドラインから叩く
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
#/bin/sh | |
# Description: Go Playground command line interface | |
# Link: http://blog.golang.org/playground | |
# Usage: | |
# - go-playground.sh FILENAME | |
# - go-playground.sh < FILENAME | |
compile_url=https://play.golang.org/compile | |
version=2 | |
curl -s -X POST --data "version=$version" --data-urlencode "body@${1:--}" $compile_url |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
出力の整形は以下を参照
ただし標準で提供されている
go run
を利用した方が簡単だと思う