Permalink
Browse files

use `go build`

  • Loading branch information...
1 parent 0e18642 commit 1002a0f872ada729017d4b200642d7331c856879 @bmizerany bmizerany committed Jan 4, 2012
Showing with 120 additions and 406 deletions.
  1. +4 −9 .gitignore
  2. 0 {src → }/Make.inc
  3. +4 −0 all.sh
  4. 0 {src/cmd/doozerd → }/boot.go
  5. +1 −1 {src/pkg → }/consensus/Makefile
  6. 0 {src/pkg → }/consensus/acceptor.go
  7. +1 −1 {src/pkg → }/consensus/acceptor_test.go
  8. +1 −1 {src/pkg → }/consensus/consensus.go
  9. +1 −1 {src/pkg → }/consensus/consensus_test.go
  10. 0 {src/pkg → }/consensus/coordinator.go
  11. 0 {src/pkg → }/consensus/coordinator_test.go
  12. 0 {src/pkg → }/consensus/learner.go
  13. 0 {src/pkg → }/consensus/learner_test.go
  14. 0 {src/pkg → }/consensus/m.go
  15. 0 {src/pkg → }/consensus/m.pb.go
  16. 0 {src/pkg → }/consensus/m.proto
  17. 0 {src/pkg → }/consensus/m_test.go
  18. +1 −1 {src/pkg → }/consensus/manager.go
  19. +1 −1 {src/pkg → }/consensus/manager_test.go
  20. +1 −1 {src/pkg → }/consensus/run.go
  21. +1 −1 {src/pkg → }/consensus/run_test.go
  22. 0 {src → }/dist.sh
  23. +1 −1 {src/cmd/doozerd → }/doozerd.go
  24. +1 −1 {src/pkg → }/gc/Makefile
  25. +1 −1 {src/pkg → }/gc/clean.go
  26. +1 −1 {src/pkg → }/gc/clean_test.go
  27. +2 −2 {src/pkg → }/gc/pulse.go
  28. +1 −1 {src/pkg → }/gc/pulse_test.go
  29. +22 −0 make.sh
  30. +1 −1 {src/pkg → }/member/Makefile
  31. +2 −2 {src/pkg → }/member/member.go
  32. +2 −2 {src/pkg → }/member/member_test.go
  33. +4 −0 peer/Makefile
  34. +1 −1 {src/pkg → }/peer/bench_test.go
  35. 0 {src/pkg → }/peer/liveness.go
  36. 0 {src/pkg → }/peer/liveness_test.go
  37. +1 −1 {src/pkg → }/peer/misc_test.go
  38. +6 −6 {src/pkg → }/peer/peer.go
  39. +1 −1 {src/pkg → }/peer/peer_test.go
  40. +1 −1 src/pkg/peer/prof.go → peer/prof_test.go.tmp
  41. +1 −1 {src/pkg → }/quiet/Makefile
  42. 0 {src/pkg → }/quiet/quiet.go
  43. 0 {src/pkg → }/quiet/quiet_test.go
  44. +1 −1 {src/pkg → }/server/Makefile
  45. +2 −2 {src/pkg → }/server/conn.go
  46. 0 {src/pkg → }/server/conn_test.go
  47. 0 {src/pkg → }/server/msg.pb.go
  48. 0 {src/pkg → }/server/msg.proto
  49. +2 −2 {src/pkg → }/server/server.go
  50. +1 −1 {src/pkg → }/server/server_test.go
  51. +2 −2 {src/pkg → }/server/txn.go
  52. +0 −44 src/all.sh
  53. +0 −33 src/clean.sh
  54. +0 −11 src/cmd/doozerd/Makefile
  55. +0 −28 src/env.sh
  56. +0 −35 src/pkg/peer/Makefile
  57. +0 −7 src/pkg/test/Makefile
  58. +0 −37 src/pkg/test/test.go
  59. +0 −30 src/test.sh
  60. +1 −1 {src/pkg → }/store/Makefile
  61. 0 {src/pkg → }/store/bench_test.go
  62. 0 {src/pkg → }/store/event.go
  63. 0 {src/pkg → }/store/event_test.go
  64. 0 {src/pkg → }/store/getter.go
  65. 0 {src/pkg → }/store/getter_test.go
  66. 0 {src/pkg → }/store/glob.go
  67. 0 {src/pkg → }/store/glob_test.go
  68. 0 {src/pkg → }/store/node.go
  69. 0 {src/pkg → }/store/node_test.go
  70. 0 {src/pkg → }/store/store.go
  71. 0 {src/pkg → }/store/store_test.go
  72. +4 −0 test.sh
  73. +2 −2 test/Makefile
  74. +0 −124 test/fail_test.go
  75. +35 −1 test/test.go
  76. 0 {src/pkg → }/test/test_test.go
  77. 0 {src/pkg/peer → }/version.sh
  78. +4 −4 {src/pkg → }/web/Makefile
  79. 0 {src/pkg → }/web/file2gostring
  80. 0 {src/pkg → }/web/main.css
  81. 0 {src/pkg → }/web/main.html
  82. 0 {src/pkg → }/web/main.js
  83. 0 {src/pkg → }/web/stats.html
  84. +1 −1 {src/pkg → }/web/web.go
  85. 0 {src/pkg → }/web/web_test.go
View
@@ -1,18 +1,13 @@
*-test.sh
*.DS_Store
*.[568]
-*.css.go
-*.html.go
-*.js.go
*.log
*.out
*.prof
.roundup.*
-_obj
-_pb
-_test
-_testmain.go
+*.css.go
+*.html.go
+*.js.go
doc/*.html
doc/*.[0-9]
-src/cmd/doozerd/doozerd
-src/pkg/peer/version.go
+peer/version.go
File renamed without changes.
View
4 all.sh
@@ -0,0 +1,4 @@
+#!/bin/sh
+set -e
+sh make.sh
+sh test.sh
File renamed without changes.
@@ -1,6 +1,6 @@
include ../../Make.inc
-TARG=doozer/consensus
+TARG=github.com/ha/doozerd/consensus
GOFILES=\
consensus.go\
run.go\
File renamed without changes.
@@ -1,7 +1,7 @@
package consensus
import (
- _ "doozer/quiet"
+ _ "github.com/ha/doozerd/quiet"
"github.com/bmizerany/assert"
"testing"
)
@@ -1,7 +1,7 @@
package consensus
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
)
@@ -1,7 +1,7 @@
package consensus
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
"errors"
"github.com/bmizerany/assert"
"net"
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -3,7 +3,7 @@ package consensus
import (
"code.google.com/p/goprotobuf/proto"
"container/heap"
- "doozer/store"
+ "github.com/ha/doozerd/store"
"log"
"net"
"sort"
@@ -3,7 +3,7 @@ package consensus
import (
"code.google.com/p/goprotobuf/proto"
"container/heap"
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/bmizerany/assert"
"net"
"sort"
@@ -3,7 +3,7 @@ package consensus
import (
"code.google.com/p/goprotobuf/proto"
"container/heap"
- "doozer/store"
+ "github.com/ha/doozerd/store"
"log"
"math/rand"
"net"
@@ -2,7 +2,7 @@ package consensus
import (
"code.google.com/p/goprotobuf/proto"
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/bmizerany/assert"
"net"
"testing"
View
File renamed without changes.
@@ -2,7 +2,7 @@ package main
import (
"crypto/tls"
- "doozer/peer"
+ "github.com/ha/doozerd/peer"
_ "expvar"
"flag"
"fmt"
@@ -1,6 +1,6 @@
include ../../Make.inc
-TARG=doozer/gc
+TARG=github.com/ha/doozerd/gc
GOFILES=\
clean.go\
pulse.go\
@@ -1,7 +1,7 @@
package gc
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
"time"
)
@@ -1,7 +1,7 @@
package gc
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/bmizerany/assert"
"testing"
"time"
@@ -1,8 +1,8 @@
package gc
import (
- "doozer/consensus"
- "doozer/store"
+ "github.com/ha/doozerd/consensus"
+ "github.com/ha/doozerd/store"
"log"
"strconv"
"time"
@@ -1,7 +1,7 @@
package gc
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/bmizerany/assert"
"testing"
)
View
22 make.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+set -e
+
+PKG=web
+
+GOFILES="
+ main.css.go
+ main.html.go
+ stats.html.go
+ main.js.go
+"
+
+for f in $GOFILES
+do
+ b="web/$(basename $f .go)"
+ ./web/file2gostring $PKG $b < $b > web/$f.part
+ mv web/$f.part web/$f
+done
+
+ver=$(./version.sh)
+printf "package peer;const Version = \`%s\`\n" "$ver" > peer/version.go
+go install
@@ -1,6 +1,6 @@
include ../../Make.inc
-TARG=doozer/member
+TARG=github.com/ha/doozerd/member
GOFILES=\
member.go\
@@ -1,8 +1,8 @@
package member
import (
- "doozer/consensus"
- "doozer/store"
+ "github.com/ha/doozerd/consensus"
+ "github.com/ha/doozerd/store"
"log"
)
@@ -2,8 +2,8 @@ package member
import (
"github.com/bmizerany/assert"
- "doozer/store"
- "doozer/test"
+ "github.com/ha/doozerd/store"
+ "github.com/ha/doozerd/test"
"sort"
"testing"
)
View
@@ -0,0 +1,4 @@
+VERS ?= $(shell ./version.sh)
+GVERS := $(shell sed 's/[^`]*`//' version.go 2>/dev/null | sed 's/`.*//')
+version.go:
+ printf 'package peer;const Version = `%s`\n' '$(VERS)' > $@
@@ -1,7 +1,7 @@
package peer
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/ha/doozer"
"testing"
)
File renamed without changes.
File renamed without changes.
@@ -1,7 +1,7 @@
package peer
import (
- _ "doozer/quiet"
+ _ "github.com/ha/doozerd/quiet"
"github.com/ha/doozer"
"net"
)
@@ -1,12 +1,12 @@
package peer
import (
- "doozer/consensus"
- "doozer/gc"
- "doozer/member"
- "doozer/server"
- "doozer/store"
- "doozer/web"
+ "github.com/ha/doozerd/consensus"
+ "github.com/ha/doozerd/gc"
+ "github.com/ha/doozerd/member"
+ "github.com/ha/doozerd/server"
+ "github.com/ha/doozerd/store"
+ "github.com/ha/doozerd/web"
"github.com/ha/doozer"
"io"
"log"
@@ -1,7 +1,7 @@
package peer
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/bmizerany/assert"
"github.com/ha/doozer"
"os/exec"
@@ -1,7 +1,7 @@
package peer
import (
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/ha/doozer"
"testing"
)
@@ -1,6 +1,6 @@
include ../../Make.inc
-TARG=doozer/quiet
+TARG=github.com/ha/doozerd/quiet
GOFILES=\
quiet.go\
File renamed without changes.
File renamed without changes.
@@ -1,6 +1,6 @@
include ../../Make.inc
-TARG=doozer/server
+TARG=github.com/ha/doozerd/server
GOFILES=\
conn.go\
msg.pb.go\
@@ -2,8 +2,8 @@ package server
import (
"code.google.com/p/goprotobuf/proto"
- "doozer/consensus"
- "doozer/store"
+ "github.com/ha/doozerd/consensus"
+ "github.com/ha/doozerd/store"
"encoding/binary"
"io"
"log"
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -1,8 +1,8 @@
package server
import (
- "doozer/consensus"
- "doozer/store"
+ "github.com/ha/doozerd/consensus"
+ "github.com/ha/doozerd/store"
"log"
"net"
"os"
@@ -3,7 +3,7 @@ package server
import (
"bytes"
"code.google.com/p/goprotobuf/proto"
- "doozer/store"
+ "github.com/ha/doozerd/store"
"github.com/bmizerany/assert"
"io"
@@ -2,8 +2,8 @@ package server
import (
"code.google.com/p/goprotobuf/proto"
- "doozer/consensus"
- "doozer/store"
+ "github.com/ha/doozerd/consensus"
+ "github.com/ha/doozerd/store"
"io"
"log"
"os"
View
@@ -1,44 +0,0 @@
-#!/bin/sh
-set -e
-if [ -f env.sh ]
-then . ./env.sh
-else
- echo 1>&2 "! $0 must be run from the root directory"
- exit 1
-fi
-
-
-if [ "$GOPATH" != "" ]
-then
- echo "You may need to unset GOPATH because this still uses Makefiles to build"
-fi
-
-xcd() {
- echo
- cd $1
- echo --- cd $1
-}
-
-mk() {
- d=$PWD
- xcd $1
- gomake install
- cd "$d"
-}
-
-for req in $PKG_REQS
-do goinstall $req
-done
-
-for pkg in $PKGS
-do mk pkg/$pkg
-done
-
-for cmd in $CMDS
-do mk cmd/$cmd
-done
-
-echo
-echo "--- TESTING"
-
-/bin/sh test.sh
Oops, something went wrong.

0 comments on commit 1002a0f

Please sign in to comment.