Skip to content

Commit 7a50794

Browse files
authored
Merge pull request #2730 from v2fly/master
merge fly
2 parents 1d759b4 + 8661477 commit 7a50794

File tree

21 files changed

+101
-128
lines changed

21 files changed

+101
-128
lines changed

.github/linters/.golangci.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
run:
2-
modules-download-mode: vendor
32
skip-dirs:
4-
- generated.*
53
- external
4+
skip-files:
5+
- generated.*
66

77
linters:
88
enable:
@@ -44,3 +44,6 @@ linters:
4444
- unused
4545
- varcheck
4646
- whitespace
47+
48+
issues:
49+
new: true

.github/workflows/coverage.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
- name: Set up Go 1.x
1414
uses: actions/setup-go@v2
1515
with:
16-
go-version: ^1.14
16+
go-version: ^1.15
1717

1818
- name: Checkout codebase
1919
uses: actions/checkout@v2

.github/workflows/linter.yml

Lines changed: 8 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Lint
1+
name: Linter
22

33
on:
44
push:
@@ -14,7 +14,7 @@ jobs:
1414
- name: Set up Go 1.x
1515
uses: actions/setup-go@v2
1616
with:
17-
go-version: ^1.14
17+
go-version: ^1.15
1818

1919
- name: Checkout codebase
2020
uses: actions/checkout@v2
@@ -26,17 +26,9 @@ jobs:
2626
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
2727
restore-keys: ${{ runner.os }}-go-
2828

29-
- name: Lint *.go files
30-
if: ${{ always() }}
31-
run: |
32-
go vet $(go list ./... | grep -v /external/)
33-
if [[ $? != 0 ]]; then
34-
exit 1
35-
fi
36-
3729
- name: Lint other files
3830
if: ${{ always() }}
39-
uses: github/super-linter@v3.9.4
31+
uses: github/super-linter@v3.10.0
4032
env:
4133
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4234
VALIDATE_ALL_CODEBASE: false
@@ -48,12 +40,8 @@ jobs:
4840
VALIDATE_MD: false
4941
VALIDATE_PROTOBUF: false
5042

51-
- name: Show if need to format code
52-
if: ${{ always() }}
53-
run: |
54-
filesNeedToFormat=$(go fmt ./...)
55-
if [[ $filesNeedToFormat ]]; then
56-
echo -e "\033[0;36m[Error] The following Go files need to be formatted:\033[0m"
57-
echo -e "\033[0;31m$filesNeedToFormat\033[0m"
58-
exit 1
59-
fi
43+
- name: golangci-lint
44+
uses: golangci/golangci-lint-action@v2
45+
with:
46+
version: v1.31
47+
args: --config=.github/linters/.golangci.yml

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- name: Set up Go 1.x
2626
uses: actions/setup-go@v2
2727
with:
28-
go-version: ^1.14
28+
go-version: ^1.15
2929

3030
- name: Checkout codebase
3131
uses: actions/checkout@v2

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
# Project V
66
![](https://github.com/v2fly/v2ray-core/workflows/Test/badge.svg)
7-
[![codecov.io][3]][4] [![GoDoc][5]][6] [![codebeat][7]][8] [![Downloads][9]][10]
7+
[![codecov.io][3]][4] [![GoDoc][5]][6] [![codebeat][7]][8] [![Downloads][9]][10] [![Downloads][11]][12]
88

99
[3]: https://codecov.io/gh/v2fly/v2ray-core/branch/master/graph/badge.svg?branch=master "Coverage badge"
1010
[4]: https://codecov.io/gh/v2fly/v2ray-core?branch=master "Codecov Status"
@@ -14,12 +14,14 @@
1414
[8]: https://codebeat.co/projects/github-com-v2ray-v2ray-core-master "Codebeat"
1515
[9]: https://img.shields.io/github/downloads/v2ray/v2ray-core/total.svg "All releases badge"
1616
[10]: https://github.com/v2ray/v2ray-core/releases/ "All releases number"
17+
[11]: https://img.shields.io/github/downloads/v2fly/v2ray-core/total.svg "All releases badge"
18+
[12]: https://github.com/v2fly/v2ray-core/releases/ "All releases number"
1719

1820
Project V is a set of network tools that help you to build your own computer network. It secures your network connections and thus protects your privacy. See [our website](https://www.v2fly.org/) for more information.
1921

2022
## License
2123

22-
[The MIT License (MIT)](https://raw.githubusercontent.com/v2ray/v2ray-core/master/LICENSE)
24+
[The MIT License (MIT)](https://raw.githubusercontent.com/v2fly/v2ray-core/master/LICENSE)
2325

2426
## Credits
2527

azure-pipelines.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ variables:
1414
- name: GOPATH
1515
value: '$(system.defaultWorkingDirectory)/gopath'
1616
- name: BAZEL_VER
17-
value: '0.23.0'
17+
value: '3.5.0'
1818

1919
steps:
2020
- checkout: self
2121
- task: GoTool@0
2222
inputs:
23-
version: '1.15.1'
23+
version: '1.15.2'
2424
- script: |
2525
mkdir triggersrc
2626
ls -I "triggersrc" | xargs cp -rf -t triggersrc

core.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import (
1919
)
2020

2121
var (
22-
version = "4.27.5"
22+
version = "4.28.0"
2323
build = "Custom"
2424
codename = "V2Fly, a community-driven edition of V2Ray."
2525
intro = "A unified platform for anti-censorship."

infra/conf/vless.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ func (c *VLessInboundConfig) Build() (proto.Message, error) {
4848
return nil, newError(`VLESS clients: invalid user`).Base(err)
4949
}
5050

51-
if account.Schedulers != "" {
52-
return nil, newError(`VLESS clients: "schedulers" is not available in this version`)
51+
if account.Flow != "" {
52+
return nil, newError(`VLESS clients: "flow" is not available in this version`)
5353
}
5454
if account.Encryption != "" {
5555
return nil, newError(`VLESS clients: "encryption" should not in inbound settings`)
@@ -161,8 +161,8 @@ func (c *VLessOutboundConfig) Build() (proto.Message, error) {
161161
return nil, newError(`VLESS users: invalid user`).Base(err)
162162
}
163163

164-
if account.Schedulers != "" {
165-
return nil, newError(`VLESS users: "schedulers" is not available in this version`)
164+
if account.Flow != "" {
165+
return nil, newError(`VLESS users: "flow" is not available in this version`)
166166
}
167167
if account.Encryption != "none" {
168168
return nil, newError(`VLESS users: please add/set "encryption":"none" for every user`)

infra/conf/vmess.go

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,9 @@ import (
1414
)
1515

1616
type VMessAccount struct {
17-
ID string `json:"id"`
18-
AlterIds uint16 `json:"alterId"`
19-
Security string `json:"security"`
20-
TestsEnabled string `json:"testsEnabled"`
17+
ID string `json:"id"`
18+
AlterIds uint16 `json:"alterId"`
19+
Security string `json:"security"`
2120
}
2221

2322
// Build implements Buildable
@@ -41,7 +40,6 @@ func (a *VMessAccount) Build() *vmess.Account {
4140
SecuritySettings: &protocol.SecurityConfig{
4241
Type: st,
4342
},
44-
TestsEnabled: a.TestsEnabled,
4543
}
4644
}
4745

proxy/vless/account.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ func (a *Account) AsAccount() (protocol.Account, error) {
1515
}
1616
return &MemoryAccount{
1717
ID: protocol.NewID(id),
18-
Schedulers: a.Schedulers, // needs parser here?
18+
Flow: a.Flow, // needs parser here?
1919
Encryption: a.Encryption, // needs parser here?
2020
}, nil
2121
}
@@ -24,8 +24,8 @@ func (a *Account) AsAccount() (protocol.Account, error) {
2424
type MemoryAccount struct {
2525
// ID of the account.
2626
ID *protocol.ID
27-
// Schedulers of the account.
28-
Schedulers string
27+
// Flow of the account. May be "xtls-rprx-origin".
28+
Flow string
2929
// Encryption of the account. Used for client connections, and only accepts "none" for now.
3030
Encryption string
3131
}

0 commit comments

Comments
 (0)