]> Cypherpunks repositories - gostls13.git/commitdiff
net: renamings
authorRob Pike <r@golang.org>
Thu, 3 Nov 2011 20:26:43 +0000 (13:26 -0700)
committerRob Pike <r@golang.org>
Thu, 3 Nov 2011 20:26:43 +0000 (13:26 -0700)
This is Go 1 package renaming CL #3.
This one merely moves the source; the import strings will be
changed after the next weekly release.
This one moves pieces into net.

http -> net/http
http/cgi -> net/http/cgi
http/fcgi -> net/http/fcgi
http/pprof -> net/http/pprof
http/httptest -> net/http/httptest
mail -> net/mail
rpc -> net/rpc
rpc/jsonrpc -> net/rpc/jsonrpc
smtp -> net/smtp
url -> net/url

Also remove rand (now math/rand) from NOTEST - it has a test.

The only edits are in Makefiles and deps.bash.

R=golang-dev, bradfitz
CC=golang-dev
https://golang.org/cl/5335048

79 files changed:
src/pkg/Makefile
src/pkg/deps.bash
src/pkg/net/http/Makefile [moved from src/pkg/http/Makefile with 90% similarity]
src/pkg/net/http/cgi/Makefile [moved from src/pkg/mail/Makefile with 64% similarity]
src/pkg/net/http/cgi/child.go [moved from src/pkg/http/cgi/child.go with 100% similarity]
src/pkg/net/http/cgi/child_test.go [moved from src/pkg/http/cgi/child_test.go with 100% similarity]
src/pkg/net/http/cgi/host.go [moved from src/pkg/http/cgi/host.go with 100% similarity]
src/pkg/net/http/cgi/host_test.go [moved from src/pkg/http/cgi/host_test.go with 100% similarity]
src/pkg/net/http/cgi/matryoshka_test.go [moved from src/pkg/http/cgi/matryoshka_test.go with 100% similarity]
src/pkg/net/http/cgi/testdata/test.cgi [moved from src/pkg/http/cgi/testdata/test.cgi with 100% similarity]
src/pkg/net/http/chunked.go [moved from src/pkg/http/chunked.go with 100% similarity]
src/pkg/net/http/client.go [moved from src/pkg/http/client.go with 100% similarity]
src/pkg/net/http/client_test.go [moved from src/pkg/http/client_test.go with 100% similarity]
src/pkg/net/http/cookie.go [moved from src/pkg/http/cookie.go with 100% similarity]
src/pkg/net/http/cookie_test.go [moved from src/pkg/http/cookie_test.go with 100% similarity]
src/pkg/net/http/doc.go [moved from src/pkg/http/doc.go with 100% similarity]
src/pkg/net/http/dump.go [moved from src/pkg/http/dump.go with 100% similarity]
src/pkg/net/http/export_test.go [moved from src/pkg/http/export_test.go with 100% similarity]
src/pkg/net/http/fcgi/Makefile [moved from src/pkg/http/fcgi/Makefile with 77% similarity]
src/pkg/net/http/fcgi/child.go [moved from src/pkg/http/fcgi/child.go with 100% similarity]
src/pkg/net/http/fcgi/fcgi.go [moved from src/pkg/http/fcgi/fcgi.go with 100% similarity]
src/pkg/net/http/fcgi/fcgi_test.go [moved from src/pkg/http/fcgi/fcgi_test.go with 100% similarity]
src/pkg/net/http/filetransport.go [moved from src/pkg/http/filetransport.go with 100% similarity]
src/pkg/net/http/filetransport_test.go [moved from src/pkg/http/filetransport_test.go with 100% similarity]
src/pkg/net/http/fs.go [moved from src/pkg/http/fs.go with 100% similarity]
src/pkg/net/http/fs_test.go [moved from src/pkg/http/fs_test.go with 100% similarity]
src/pkg/net/http/header.go [moved from src/pkg/http/header.go with 100% similarity]
src/pkg/net/http/header_test.go [moved from src/pkg/http/header_test.go with 100% similarity]
src/pkg/net/http/httptest/Makefile [moved from src/pkg/http/httptest/Makefile with 78% similarity]
src/pkg/net/http/httptest/recorder.go [moved from src/pkg/http/httptest/recorder.go with 100% similarity]
src/pkg/net/http/httptest/server.go [moved from src/pkg/http/httptest/server.go with 100% similarity]
src/pkg/net/http/lex.go [moved from src/pkg/http/lex.go with 100% similarity]
src/pkg/net/http/lex_test.go [moved from src/pkg/http/lex_test.go with 100% similarity]
src/pkg/net/http/persist.go [moved from src/pkg/http/persist.go with 100% similarity]
src/pkg/net/http/pprof/Makefile [moved from src/pkg/smtp/Makefile with 66% similarity]
src/pkg/net/http/pprof/pprof.go [moved from src/pkg/http/pprof/pprof.go with 100% similarity]
src/pkg/net/http/proxy_test.go [moved from src/pkg/http/proxy_test.go with 100% similarity]
src/pkg/net/http/range_test.go [moved from src/pkg/http/range_test.go with 100% similarity]
src/pkg/net/http/readrequest_test.go [moved from src/pkg/http/readrequest_test.go with 100% similarity]
src/pkg/net/http/request.go [moved from src/pkg/http/request.go with 100% similarity]
src/pkg/net/http/request_test.go [moved from src/pkg/http/request_test.go with 100% similarity]
src/pkg/net/http/requestwrite_test.go [moved from src/pkg/http/requestwrite_test.go with 100% similarity]
src/pkg/net/http/response.go [moved from src/pkg/http/response.go with 100% similarity]
src/pkg/net/http/response_test.go [moved from src/pkg/http/response_test.go with 100% similarity]
src/pkg/net/http/responsewrite_test.go [moved from src/pkg/http/responsewrite_test.go with 100% similarity]
src/pkg/net/http/reverseproxy.go [moved from src/pkg/http/reverseproxy.go with 100% similarity]
src/pkg/net/http/reverseproxy_test.go [moved from src/pkg/http/reverseproxy_test.go with 100% similarity]
src/pkg/net/http/serve_test.go [moved from src/pkg/http/serve_test.go with 100% similarity]
src/pkg/net/http/server.go [moved from src/pkg/http/server.go with 100% similarity]
src/pkg/net/http/sniff.go [moved from src/pkg/http/sniff.go with 100% similarity]
src/pkg/net/http/sniff_test.go [moved from src/pkg/http/sniff_test.go with 100% similarity]
src/pkg/net/http/status.go [moved from src/pkg/http/status.go with 100% similarity]
src/pkg/net/http/testdata/file [moved from src/pkg/http/testdata/file with 100% similarity]
src/pkg/net/http/testdata/index.html [moved from src/pkg/http/testdata/index.html with 100% similarity]
src/pkg/net/http/testdata/style.css [moved from src/pkg/http/testdata/style.css with 100% similarity]
src/pkg/net/http/transfer.go [moved from src/pkg/http/transfer.go with 100% similarity]
src/pkg/net/http/transport.go [moved from src/pkg/http/transport.go with 100% similarity]
src/pkg/net/http/transport_test.go [moved from src/pkg/http/transport_test.go with 100% similarity]
src/pkg/net/http/transport_windows.go [moved from src/pkg/http/transport_windows.go with 100% similarity]
src/pkg/net/http/triv.go [moved from src/pkg/http/triv.go with 100% similarity]
src/pkg/net/mail/Makefile [moved from src/pkg/http/cgi/Makefile with 86% similarity]
src/pkg/net/mail/message.go [moved from src/pkg/mail/message.go with 100% similarity]
src/pkg/net/mail/message_test.go [moved from src/pkg/mail/message_test.go with 100% similarity]
src/pkg/net/rpc/Makefile [moved from src/pkg/rpc/Makefile with 80% similarity]
src/pkg/net/rpc/client.go [moved from src/pkg/rpc/client.go with 100% similarity]
src/pkg/net/rpc/debug.go [moved from src/pkg/rpc/debug.go with 100% similarity]
src/pkg/net/rpc/jsonrpc/Makefile [moved from src/pkg/rpc/jsonrpc/Makefile with 78% similarity]
src/pkg/net/rpc/jsonrpc/all_test.go [moved from src/pkg/rpc/jsonrpc/all_test.go with 100% similarity]
src/pkg/net/rpc/jsonrpc/client.go [moved from src/pkg/rpc/jsonrpc/client.go with 100% similarity]
src/pkg/net/rpc/jsonrpc/server.go [moved from src/pkg/rpc/jsonrpc/server.go with 100% similarity]
src/pkg/net/rpc/server.go [moved from src/pkg/rpc/server.go with 100% similarity]
src/pkg/net/rpc/server_test.go [moved from src/pkg/rpc/server_test.go with 100% similarity]
src/pkg/net/smtp/Makefile [moved from src/pkg/http/pprof/Makefile with 88% similarity]
src/pkg/net/smtp/auth.go [moved from src/pkg/smtp/auth.go with 100% similarity]
src/pkg/net/smtp/smtp.go [moved from src/pkg/smtp/smtp.go with 100% similarity]
src/pkg/net/smtp/smtp_test.go [moved from src/pkg/smtp/smtp_test.go with 100% similarity]
src/pkg/net/url/Makefile [moved from src/pkg/url/Makefile with 78% similarity]
src/pkg/net/url/url.go [moved from src/pkg/url/url.go with 100% similarity]
src/pkg/net/url/url_test.go [moved from src/pkg/url/url_test.go with 100% similarity]

index 036e9cae8bf0d4a8841f9ae6c8ac1c5b67b7e5c5..691eda4a080a79ac6fac7c484b2b0c46c21ef03c 100644 (file)
@@ -105,11 +105,6 @@ DIRS=\
        hash/fnv\
        html\
        html/template\
-       http\
-       http/cgi\
-       http/fcgi\
-       http/pprof\
-       http/httptest\
        image\
        image/bmp\
        image/color\
@@ -124,7 +119,6 @@ DIRS=\
        io/ioutil\
        log\
        log/syslog\
-       mail\
        math\
        math/big\
        math/cmplx\
@@ -133,7 +127,17 @@ DIRS=\
        mime/multipart\
        net\
        net/dict\
+       net/http\
+       net/http/cgi\
+       net/http/fcgi\
+       net/mail\
+       net/http/pprof\
+       net/http/httptest\
+       net/rpc\
+       net/rpc/jsonrpc\
+       net/smtp\
        net/textproto\
+       net/url\
        old/netchan\
        old/regexp\
        old/template\
@@ -146,14 +150,11 @@ DIRS=\
        reflect\
        regexp\
        regexp/syntax\
-       rpc\
-       rpc/jsonrpc\
        runtime\
        runtime/cgo\
        runtime/debug\
        runtime/pprof\
        scanner\
-       smtp\
        sort\
        strconv\
        strings\
@@ -169,7 +170,6 @@ DIRS=\
        testing/script\
        time\
        unicode\
-       url\
        utf16\
        utf8\
        websocket\
@@ -205,13 +205,12 @@ NOTEST+=\
        exp/gui/x11\
        go/doc\
        hash\
-       http/pprof\
-       http/httptest\
        image/bmp\
        image/color\
        image/gif\
        net/dict\
-       rand\
+       net/http/pprof\
+       net/http/httptest\
        runtime/cgo\
        syscall\
        testing\
index 3f2a3abc661cd60652a61f8130aa63dfcb4469e7..d17e1c7cf1326cf4fd764727e1f026ecd7de49df 100755 (executable)
@@ -31,9 +31,18 @@ dirpat="$dirpat
 /^(csv)$/
 /^(exp\/template\/html)$/
 /^(gob)$/
+/^(http)/
+/^(http\/cgi)$/
+/^(http\/fcgi)$/
+/^(http\/httptest)$/
+/^(http\/pprof)$/
 /^(json)$/
+/^(mail)$/
 /^(rand)$/
+/^(rpc)$/
+/^(smtp)$/
 /^(syslog)$/
+/^(url)$/
 /^(xml)$/
 "
 
@@ -60,9 +69,19 @@ for dir in $dirs; do (
                s;^csv.install$;encoding/csv.install;
                s;^exp/template/html.install$;html/template.install;
                s;^gob.install$;encoding/gob.install;
+               s;^http.install$;net/http.install;
+               s;^http/cgi.install$;net/http/cgi.install;
+               s;^http/fcgi.install$;net/http/fcgi.install;
+               s;^http/httptest.install$;net/http/httptest.install;
+               s;^http/pprof.install$;net/http/pprof.install;
                s;^json.install$;encoding/json.install;
+               s;^mail.install$;net/mail.install;
+               s;^rpc.install$;net/rpc.install;
+               s;^rpc/jsonrpc.install$;net/rpc/jsonrpc.install;
+               s;^smtp.install$;net/smtp.install;
                s;^syslog.install$;log/syslog.install;
                s;^rand.install$;math/rand.install;
+               s;^url.install$;net/url.install;
                s;^xml.install$;encoding/xml.install;' |
                # TODO: end of renamings.
                sed 's;^C\.install;runtime/cgo.install;' |
similarity index 90%
rename from src/pkg/http/Makefile
rename to src/pkg/net/http/Makefile
index bde50cf7a251166c6cb6fa37f93f624c1503ef03..1fde30cf361af96a71e6820ec6a3c861bf90f56b 100644 (file)
@@ -2,7 +2,7 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../Make.inc
+include ../../../Make.inc
 
 TARG=http
 GOFILES=\
@@ -29,4 +29,4 @@ GOFILES_windows=\
        
 GOFILES+=$(GOFILES_$(GOOS))
 
-include ../../Make.pkg
+include ../../../Make.pkg
similarity index 64%
rename from src/pkg/mail/Makefile
rename to src/pkg/net/http/cgi/Makefile
index e4de5428ee1aa7c0d72abe29522bf260326fed83..fce7aed41bb31ba857464ac3bb01f770bbf60268 100644 (file)
@@ -2,10 +2,11 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../Make.inc
+include ../../../../Make.inc
 
-TARG=mail
+TARG=http/cgi
 GOFILES=\
-       message.go\
+       child.go\
+       host.go\
 
-include ../../Make.pkg
+include ../../../../Make.pkg
similarity index 100%
rename from src/pkg/http/doc.go
rename to src/pkg/net/http/doc.go
similarity index 77%
rename from src/pkg/http/fcgi/Makefile
rename to src/pkg/net/http/fcgi/Makefile
index bc01cdea9e1888a6279bc70143aac658e06b5232..65914361b9a058d57b5d999ed22cfb95e493516e 100644 (file)
@@ -2,11 +2,11 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../../Make.inc
+include ../../../../Make.inc
 
 TARG=http/fcgi
 GOFILES=\
        child.go\
        fcgi.go\
 
-include ../../../Make.pkg
+include ../../../../Make.pkg
similarity index 100%
rename from src/pkg/http/fs.go
rename to src/pkg/net/http/fs.go
similarity index 78%
rename from src/pkg/http/httptest/Makefile
rename to src/pkg/net/http/httptest/Makefile
index eb35d8aec6b6c40850bbaeeecf3b6f1320d6b4ec..217cb9bbd6b33dea9b58f6569909ff5efebbb637 100644 (file)
@@ -2,11 +2,11 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../../Make.inc
+include ../../../../Make.inc
 
 TARG=http/httptest
 GOFILES=\
        recorder.go\
        server.go\
 
-include ../../../Make.pkg
+include ../../../../Make.pkg
similarity index 100%
rename from src/pkg/http/lex.go
rename to src/pkg/net/http/lex.go
similarity index 66%
rename from src/pkg/smtp/Makefile
rename to src/pkg/net/http/pprof/Makefile
index 0e7d8d5f7b857ccdac6cd5d1fae9566ccfc672eb..9b60273bf8fe9776e2178dec0a3deb907e11ae09 100644 (file)
@@ -2,11 +2,10 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../Make.inc
+include ../../../../Make.inc
 
-TARG=smtp
+TARG=http/pprof
 GOFILES=\
-       auth.go\
-       smtp.go\
+       pprof.go\
 
-include ../../Make.pkg
+include ../../../../Make.pkg
similarity index 86%
rename from src/pkg/http/cgi/Makefile
rename to src/pkg/net/mail/Makefile
index 19b1039c260f9f3ec5448f9b4b1d03d6427d4b9f..5ab8acfa1c8c477c885559fe34b0863add07fce0 100644 (file)
@@ -4,9 +4,8 @@
 
 include ../../../Make.inc
 
-TARG=http/cgi
+TARG=mail
 GOFILES=\
-       child.go\
-       host.go\
+       message.go\
 
 include ../../../Make.pkg
similarity index 80%
rename from src/pkg/rpc/Makefile
rename to src/pkg/net/rpc/Makefile
index 191b10d054dd4d8f949d9d0b8e1d770db2172668..b1872d6d0984ae72ce43cf8a62aa16ae6c50c39c 100644 (file)
@@ -2,7 +2,7 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../Make.inc
+include ../../../Make.inc
 
 TARG=rpc
 GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
        debug.go\
        server.go\
 
-include ../../Make.pkg
+include ../../../Make.pkg
similarity index 78%
rename from src/pkg/rpc/jsonrpc/Makefile
rename to src/pkg/net/rpc/jsonrpc/Makefile
index b9a1ac2f77751b9b067f152290ea0175e23afac0..1bb2a0d0e3ee70d2e4291dda134aedb14c40df41 100644 (file)
@@ -2,11 +2,11 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../../Make.inc
+include ../../../../Make.inc
 
 TARG=rpc/jsonrpc
 GOFILES=\
        client.go\
        server.go\
 
-include ../../../Make.pkg
+include ../../../../Make.pkg
similarity index 88%
rename from src/pkg/http/pprof/Makefile
rename to src/pkg/net/smtp/Makefile
index 5858a0efa77b39a9a2b9da630ef5b29e1dbb0510..810f3ff9142e4bee48cd8aac38baf1d67dbd998f 100644 (file)
@@ -4,8 +4,9 @@
 
 include ../../../Make.inc
 
-TARG=http/pprof
+TARG=smtp
 GOFILES=\
-       pprof.go\
+       auth.go\
+       smtp.go\
 
 include ../../../Make.pkg
similarity index 78%
rename from src/pkg/url/Makefile
rename to src/pkg/net/url/Makefile
index b9267bd085c5b251dab624c45443278b736ed185..f583cdf636caaa1cf02813b53701565f2e7a7373 100644 (file)
@@ -2,10 +2,10 @@
 # Use of this source code is governed by a BSD-style
 # license that can be found in the LICENSE file.
 
-include ../../Make.inc
+include ../../../Make.inc
 
 TARG=url
 GOFILES=\
        url.go\
 
-include ../../Make.pkg
+include ../../../Make.pkg
similarity index 100%
rename from src/pkg/url/url.go
rename to src/pkg/net/url/url.go