blob: 8c23e010e8985475962bb01dffd51d0f559c2a73 [file] [log] [blame]
Devon H. O'Dell553be842009-11-14 15:29:09 -08001#!/usr/bin/env bash
Rob Pike69b74c32008-06-12 13:26:16 -07002# Copyright 2009 The Go Authors. All rights reserved.
3# Use of this source code is governed by a BSD-style
4# license that can be found in the LICENSE file.
5
Christopher Wedgwood2ef330e2009-12-13 12:27:19 -08006set -e
7
Mikio Hara0724e5c2012-02-15 23:52:07 +09008eval $(go tool dist env)
9
10if [ ! -x $GOTOOLDIR/dist ]; then
11 echo 'cannot find $GOTOOLDIR/dist; nothing to clean' >&2
Christopher Wedgwood2ef330e2009-12-13 12:27:19 -080012 exit 1
13fi
Devon H. O'Dell857d4cf2009-12-11 15:14:09 -080014
Russ Cox82905362012-02-04 00:54:08 -050015"$GOBIN/go" clean -i std
Shenghou Ma01187f72015-05-07 02:12:23 -040016"$GOBIN/go" tool dist clean
17"$GOBIN/go" clean -i cmd