BUILDDATE=$(date --iso-8601=seconds)

BUILDREPO=$(git config --get remote.origin.url)

BUILDREV=$(git rev-parse --short HEAD)

GOVERSION=$(go version | perl -ne '/go version (.*?) / && print $1')

DEPENDENCIES=$(echo -n "{" && go list -f '{{range $dep := .Deps}}{{printf "%s\n" $dep}}{{end}}' | xargs go list -f '{{if not .Standard}}{{.ImportPath}}{{end}}' | xargs -I pkg bash -c 'cd $GOPATH/src/pkg && echo -n "\"pkg\":\"$(git rev-parse --short HEAD)\","' | sed 's/,$/}/')

LDFLAGS="\

-X github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common.buildDate=$BUILDDATE \

-X github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common.buildRepo=$BUILDREPO \go build

-X github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common.buildgo buildRev=$BUILDREV \

-X github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common.goVersion=$GOVERSION \

-X github.com/Psiphon-Labs/psiphon-tunnel-core/psiphon/common.dependencies=$DEPENDENCIES \

"

Please run the above, I noticed medium formatted the special characters causing the error.

Software Engineer, Excellent reader, Novice writer. https://www.linkedin.com/in/alexssanya

Software Engineer, Excellent reader, Novice writer. https://www.linkedin.com/in/alexssanya