Owen Mansel-Chan
874a426779
Add identify-environment scripts
2023-05-11 11:51:42 +01:00
Owen Mansel-Chan
b306807046
Merge pull request #13040 from owen-mc/go/identify-environment-change-logic
...
Go: change logic in `go-autobuilder --identify-environment`
2023-05-11 08:22:01 +01:00
Owen Mansel-Chan
5ef74c96de
Merge pull request #13105 from owen-mc/go/change-diagnostic-message
...
Go: Update "go/autobuilder/package-not-found" diagnostic message
2023-05-11 05:27:09 +01:00
Owen Mansel-Chan
270ba09ffb
Merge pull request #11732 from owen-mc/go/fix/model-data-flow-through-varargs
...
Go: Allow data flow through varargs parameters
2023-05-11 05:26:40 +01:00
Owen Mansel-Chan
9334cfb22c
Change logic when go mod version above max supported version
2023-05-10 21:56:56 +01:00
Owen Mansel-Chan
9c5fc9714a
Use "Requesting" instead of "Writing environment file"
2023-05-10 21:53:10 +01:00
Owen Mansel-Chan
97ec7a07eb
Address review comments
2023-05-10 15:53:08 +01:00
Owen Mansel-Chan
1c66564ccc
address review comments
2023-05-10 14:05:09 +01:00
Owen Mansel-Chan
8f41ff36fb
Add change note
2023-05-10 13:50:04 +01:00
Owen Mansel-Chan
50d3cffe61
Accept review comments
2023-05-10 13:28:11 +01:00
Owen Mansel-Chan
fcf3cb7ea4
Update "go/autobuilder/package-not-found" message
2023-05-10 12:24:03 +01:00
Owen Mansel-Chan
375be68492
Fix diagnostics
2023-05-10 11:12:48 +01:00
Owen Mansel-Chan
edebebf603
Refactor for clarity
2023-05-10 11:12:47 +01:00
Owen Mansel-Chan
f9d2467eaa
Downgrade package-not-found diagnostic to warning
...
error is reserved for when the build fails.
2023-05-10 09:58:58 +01:00
Owen Mansel-Chan
12f996ff56
Deal better with goModVersion < minGoVersion
2023-05-10 09:45:48 +01:00
Owen Mansel-Chan
32b5df69c3
Add comments explaining version choice logic
2023-05-10 09:26:18 +01:00
Michael Nebel
4ac0396b67
Go/Python/Ruby/Swift: Sync files and make dummy implementation.
2023-05-08 16:18:59 +02:00
Owen Mansel-Chan
d329da673a
Refactor logic for which version to install
...
This does not change the version returned. In the case the the go mod
version is supported and the go env version is below goMinVersion, the
message now talks about go env version being unsupported instead of
it being less than go mod version. This seems more sensible to me.
2023-05-05 15:44:55 +01:00
Owen Mansel-Chan
3f7a230a11
Sometimes install Go version even when one exists
2023-05-05 15:44:54 +01:00
Owen Mansel-Chan
bb3101e649
Merge pull request #13022 from owen-mc/go/identify-environment-fixes
...
Go: `go-autobuilder --identify-environment` fixes
2023-05-04 14:30:31 +01:00
Owen Mansel-Chan
d2cf1a24e0
Merge pull request #13014 from owen-mc/go/misc-go-cleanups
...
Go: Misc go cleanups
2023-05-04 10:34:32 +01:00
Owen Mansel-Chan
011c9272cf
Remove inconsistent line break in message
2023-05-04 10:33:05 +01:00
Owen Mansel-Chan
c21b1a6e3b
Be clear when no Go version in environment file
2023-05-04 10:32:21 +01:00
Owen Mansel-Chan
5d06adb1e6
Only check if go env version is supported if go mod version is supported
...
This is what I meant to implement in the first place.
2023-05-04 10:24:43 +01:00
Kasper Svendsen
a7f5decb2b
Merge branch 'main' into kaspersv/go-enable-warn-on-implicit-this
2023-05-04 07:45:07 +02:00
Owen Mansel-Chan
62653fbec5
Simplify return statements in tryReadGoDirective
...
This makes it easier to reason about what is returned and would have
avoided the bug with variable shadowing.
2023-05-03 16:55:19 +01:00
Owen Mansel-Chan
d30b736eb2
Move check for EmitNewerGoVersionNeeded diagnostic
...
This should only be done when --identify-environment has not been passed
2023-05-03 16:52:48 +01:00
Owen Mansel-Chan
afb692300a
Fix typo in field name
2023-05-03 16:46:44 +01:00
Owen Mansel-Chan
742a6d9264
Fix accidental variable shadowing
2023-05-03 16:32:53 +01:00
Owen Mansel-Chan
347b5f1b1a
Remove unused code
2023-05-03 16:03:17 +01:00
Owen Mansel-Chan
509dda5af5
Use raw string literals to avoid double-escaping
2023-05-03 16:02:36 +01:00
Owen Mansel-Chan
4de4f35855
Merge pull request #12957 from owen-mc/go/autobuilder-identify-environment
...
Go: Add `go-autobuilder --identify-environment`
2023-05-03 16:01:45 +01:00
Kasper Svendsen
46727af948
Go: Enable warnings for implicit this receivers
2023-05-03 15:41:55 +02:00
Owen Mansel-Chan
3f645e9401
Merge pull request #13006 from kaspersv/kaspersv/go-explicit-this-receivers
...
Go: Make implicit this receivers explicit
2023-05-03 13:47:10 +01:00
Ian Lynagh
b56b843d13
Merge pull request #12987 from github/post-release-prep/codeql-cli-2.13.1
...
Post-release preparation for codeql-cli-2.13.1
2023-05-03 13:12:10 +01:00
Owen Mansel-Chan
841db151f6
Improve naming
2023-05-03 13:01:23 +01:00
Owen Mansel-Chan
0f134c6a3c
Wrap long line
2023-05-03 12:52:11 +01:00
Owen Mansel-Chan
f86e540d2a
`msg` is always non-empty
2023-05-03 12:50:58 +01:00
Owen Mansel-Chan
af2a9b21ab
Add function comments
2023-05-03 12:47:28 +01:00
Owen Mansel-Chan
a9d3cfccd4
use severityNote for all diagnostics
2023-05-03 12:03:12 +01:00
Owen Mansel-Chan
532e1446f0
Change diagnostic ids and use "lower than or equal to"
2023-05-03 12:03:12 +01:00
Owen Mansel-Chan
4b88279ccc
Improve usage message formatting
2023-05-03 12:03:11 +01:00
Kasper Svendsen
e969018f99
Go: Make implicit this receivers explicit
2023-05-03 12:45:42 +02:00
Owen Mansel-Chan
27fb42db76
Env var for path to environment file
2023-05-03 11:11:09 +01:00
Owen Mansel-Chan
0c6efb8c84
Add telemetry-only diagnostics
2023-05-02 17:17:06 +01:00
Owen Mansel-Chan
3bfcbbf7af
Add unit test
2023-05-02 17:17:05 +01:00
Owen Mansel-Chan
0710ed97db
Refactor to be more easily testable
2023-05-02 17:17:05 +01:00
Owen Mansel-Chan
2db304edee
Choose which version to install and write file
2023-05-02 17:17:04 +01:00
Owen Mansel-Chan
644d7f18c2
Factor out tryReadGoDirective()
2023-05-02 14:15:03 +01:00
Owen Mansel-Chan
5e87111a8b
Stop using deprecate `io/ioutil` package
2023-05-02 14:15:02 +01:00