403Webshell
Server IP : 217.160.0.212  /  Your IP : 216.73.216.228
Web Server : Apache
System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64
User : sws1073854427 ( 1073854427)
PHP Version : 8.4.23
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /lib/go/src/cmd/go/testdata/script/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/go/src/cmd/go/testdata/script/mod_clean_cache.txt
env GO111MODULE=on

# 'mod download' should download the module to the cache.
go mod download rsc.io/quote@v1.5.0
exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.info
exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.mod
exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.zip

# '-n' should print commands but not actually execute them.
go clean -modcache -n
stdout '^rm -rf .*pkg.mod$'
exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.info
exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.mod
exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.zip

# 'go clean -modcache' should actually delete the files.
go clean -modcache
! exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.info
! exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.mod
! exists $GOPATH/pkg/mod/cache/download/rsc.io/quote/@v/v1.5.0.zip

# 'go clean -r -modcache' should clean only the dependencies that are within the
# main module.
# BUG(golang.org/issue/28680): Today, it cleans across module boundaries.
cd r
exists ./test.out
exists ../replaced/test.out
go clean -r -modcache
! exists ./test.out
! exists ../replaced/test.out  # BUG: should still exist

# 'go clean -modcache' should not download anything before cleaning.
go mod edit -require rsc.io/quote@v1.99999999.0-not-a-real-version
go clean -modcache
! stderr 'finding rsc.io'
go mod edit -droprequire rsc.io/quote

! go clean -modcache m
stderr 'go: clean -modcache cannot be used with package arguments'

-- go.mod --
module m
-- m.go --
package m

-- r/go.mod --
module example.com/r
require example.com/r/replaced v0.0.0
replace example.com/r/replaced => ../replaced
-- r/r.go --
package r
import _ "example.com/r/replaced"
-- r/test.out --
DELETE ME

-- replaced/go.mod --
module example.com/r/replaced
-- replaced/replaced.go --
package replaced
-- replaced/test.out --
DO NOT DELETE

Youez - 2016 - github.com/yon3zu
LinuXploit