-
Notifications
You must be signed in to change notification settings - Fork 2k
Merge codeql-go repository into codeql #8631
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2539 commits
Select commit
Hold shift + click to select a range
08c10bf
Merge pull request #625 from smowton/smowton/fix/minor-perf-improvements
smowton 559aec1
Merge pull request #632 from owen-mc/refactor-variadic-helper-functio…
smowton 89b2a2f
Merge pull request #633 from owen-mc/database-sql-model-incorrect
smowton 9309abf
Merge pull request #574 from sauyon/dataflow-update
smowton 6a2a829
Add missing tests for DatabaseSql function models
owen-mc c2b42ce
Fix sanitization by strings.Replace[All] in go/unsafe-quoting and go/…
smowton f86510e
Update comment
smowton bd806a8
Merge pull request #638 from owen-mc/test-database-sql-models
smowton 42ecc9b
Move new change notes to appropriate pack
a3e5b4c
Move pre-packaging change notes to `old-change-notes` directory
d14ea51
Merge pull request #639 from github/dbartol/fix-change-notes
ee6ea0f
Release preparation for version 2.7.4
invalid-email-address e1417f1
Merge pull request #640 from github/release-prep/2.7.4
9de1532
Add log-injection test using strings.ReplaceAll
smowton f510844
Update change-notes/2021-12-14-strings-replace-sanitizers.md
smowton ede57b6
Merge pull request #637 from smowton/smowton/fix/log-injection-saniti…
smowton 9b2f29b
Allow data flow through receiver for modelled methods
owen-mc ec3dd1e
Revert "Update tests for no flow through receivers when no function b…
owen-mc da8f8e2
Refactor to use SummarizedCallable, sourceElement and sinkElement
owen-mc 92d3da5
Declassify fmt.Fprintf as a log sink
smowton 4459c8e
run the redundant-cast patch
erik-krogh d339f13
run the non-us-language patch
erik-krogh afe7ee1
run the use-set-literals patch
erik-krogh 00aae7c
Post-release version bumps
invalid-email-address 091906d
Merge pull request #644 from github/post-release-prep/codeql-cli-2.7.4
171aa8b
Move change notes to proper location
50457d1
Merge pull request #653 from dbartol/dbartol/move-change-notes
hvitved daa55ea
Merge pull request #651 from erik-krogh/patches
owen-mc 980c162
Release preparation for version 2.7.5
invalid-email-address a0766e0
Merge pull request #656 from github/release-prep/2.7.5
hvitved 49d239f
Push upgrades pack into lib pack
aeisenberg 5760841
Merge pull request #647 from smowton/smowton/admin/not-all-you-fmt-is…
smowton 7496987
Note that the %q format directive escapes newlines, and therefore pre…
smowton e0a3ec8
Path transformer: use fully resolved path
smowton 6b4a505
Merge pull request #659 from smowton/smowton/fix/path-transformer-use…
smowton ae5eade
Update ql/lib/semmle/go/frameworks/stdlib/Log.qll
smowton 6f598a6
Fix formatting regex comment
smowton 6afd570
Merge pull request #658 from smowton/smowton/feature/q-format-directi…
smowton 6ceebc7
Merge branch 'main' into aeisenberg/upgrades/work
aeisenberg 2b8e4b2
Merge pull request #628 from github/aeisenberg/upgrades/work
aeisenberg 970e8e1
Post-release preparation for codeql-cli-2.7.5
invalid-email-address 8a4120a
Changenotes: Add changenotes for upgrades refactoring
aeisenberg c86e96b
Merge branch 'main' into post-release-prep/codeql-cli-2.7.5
aeisenberg 156588a
Update change note
aeisenberg a83af5e
Merge pull request #661 from github/aeisenberg/changenote-upgrades-re…
aeisenberg 429a965
Merge pull request #657 from github/post-release-prep/codeql-cli-2.7.5
hvitved fd1136a
Add change note for change to `Function.getACall`
owen-mc 84116e1
Update ql/lib/change-notes/2022-01-18-function-get-a-call.md
owen-mc 1aebf4c
Merge pull request #664 from owen-mc/add-change-note-function-getacall
owen-mc 3c02403
Do not use getACall() when we only want direct calls
owen-mc 84f9b74
t Improve documentation of `Function.getACall`
owen-mc 85319b2
Add tests for tainted path sanitizers and sanitizer guards
owen-mc 7fd2fff
Merge pull request #666 from owen-mc/tainted-path-add-more-tests
owen-mc 4d1dcb3
Remove first disjunct as it is a subset of second disjunct
owen-mc 7f39b1e
Don't use codeql pack install --verify
smowton 5a2a15c
Merge pull request #668 from github/smowton/fix/no-pack-install-verify
smowton bfae3fd
Merge pull request #665 from owen-mc/update-function-get-a-call
owen-mc 1e5721b
Release preparation for version 2.7.6
invalid-email-address 8c00d3e
Merge pull request #669 from github/release-prep/2.7.6
hvitved 8111fbb
Delete m
smowton de07035
Merge pull request #670 from github/smowton/admin/remove-committed-bi…
smowton 5485511
Correct module name in file comment
owen-mc c52caa6
Post-release preparation for codeql-cli-2.7.6
invalid-email-address 691bb97
Move ReturnValue[]-specific code to non-shared file
owen-mc 44641de
Represent ReturnValue[n] correctly in test output
owen-mc 3804839
Merge pull request #671 from owen-mc/misc-clean-ups
smowton 99994ee
use set literals instead of big disjunctions
erik-krogh 504e7a1
simplify an redundant any() expression
erik-krogh d6d1c94
Merge pull request #674 from erik-krogh/patches
smowton daabd3a
Merge pull request #673 from owen-mc/refactor-returnvalue-n
owen-mc 6a2f471
Merge pull request #672 from github/post-release-prep/codeql-cli-2.7.6
hvitved cc7b72a
Merge branch `rc/3.4` into `main`
edoardopirovano 4a3e945
Merge pull request #676 from github/edoardo/3.4-mergeback
edoardopirovano 9e0580d
Add new groups for examples packs
aeisenberg d545716
Release preparation for version 2.8.0
invalid-email-address 14d227a
Merge pull request #677 from github/release-prep/2.8.0
tamasvajk 28461f5
Merge pull request #675 from github/aeisenberg/examples-groups
aeisenberg de2ed83
Note that `filepath.Clean("/" + e)` is a sanitizer against path trave…
smowton d064b17
Merge pull request #678 from smowton/smowton/feature/note-filepath-cl…
smowton 613a85b
Add ErrorExpr to dbscheme
owen-mc ee85d6c
Undo whitespace change
smowton f351924
Merge pull request #679 from owen-mc/add-error-expr-to-dbscheme
owen-mc 4a4b9c3
Add an example query for inexhaustive switches
rneatherway e3feece
Merge pull request #680 from github/rneatherway/example-query
rneatherway dea1959
Match gopkg.in import of squirrel for SQLi query
lyoung-confluent 3b32425
remove .v1 from gopkg.in
lyoung-confluent 324f8f7
codeql query format
lyoung-confluent 034f3d5
Merge pull request #683 from lyoung-confluent/patch-2
owen-mc c547f47
CI: Run on Windows 2019
smowton 85db49c
Merge pull request #685 from github/smowton/fix/windows-2019-ci
owen-mc 9c12f1a
Release preparation for version 2.8.0
invalid-email-address b3d63ac
Post-release preparation for codeql-cli-2.8.0
invalid-email-address 92862fa
Merge pull request #684 from github/post-release-prep/codeql-cli-2.8.0
tamasvajk 29391a1
Merge branch 'main' into codeql-cli-2.8.0-copy
tamasvajk b51b606
Merge pull request #689 from github/codeql-cli-2.8.0-copy
smowton f66cad8
Go: sync FlowSummaryImpl.qll
asgerf 6d4b4df
Go: auto format
asgerf 9b61ed9
Add query "Wrapped error always nil"
owen-mc 98c60f3
Simplify comparison of DataFlow::Node and IR::Instruction
owen-mc 4ba4b5a
Add query help for WrappedErrorAlwaysNil
rneatherway a008bd4
Add a change note
owen-mc 3173765
Minor changes to qhelp
owen-mc 6f0e1a2
Release preparation for version 2.8.1
invalid-email-address a26bfb0
Go: add test with Argument[0..2] spec
asgerf 66545db
Go: fix parsing of n1..n2 in parseConstantOrRange
asgerf 6bfc0a7
Go: use parseConstantOrRange in parseReturn
asgerf 6403a23
Merge pull request #693 from github/release-prep/2.8.1
aibaars 620bdf2
Go: add new sink to completetest.ql as well
asgerf fbd73a3
Merge pull request #690 from asgerf/asgerf/sync-flow-summary-impl
owen-mc a89ae0b
Post-release preparation for codeql-cli-2.8.1
invalid-email-address 0f15d71
Merge pull request #694 from github/post-release-prep/codeql-cli-2.8.1
aibaars e8c2ab7
Apply suggestions from code review from docs team
owen-mc da52cb2
Go: sync FlowSummaryImpl and AccessPathSyntax.qll
asgerf 846a876
Go: update to use new API exposed by FlowSummaryImpl.qll
asgerf cb38df5
Go: rewrite access paths to dot-style
asgerf 0cd5e52
Update expected alert message
owen-mc 980c274
Merge pull request #681 from owen-mc/new-query/wrapped-error-always-nil
owen-mc 106ee5b
Merge pull request #696 from asgerf/asgerf/dot-separated-access-paths
smowton 28c3c00
Move new query change note to src pack
smowton 60bd464
Re-add change note to src pack
smowton b1cdde6
Merge pull request #697 from github/smowton/admin/move-change-note
smowton 3840ce8
Release preparation for version 2.8.2
invalid-email-address 8d329c5
Fix typo in change logs
tamasvajk 3125f49
Merge pull request #698 from github/release-prep/2.8.2
tamasvajk dd3fc2d
Post-release preparation for codeql-cli-2.8.2
invalid-email-address 30c8062
Merge pull request #699 from github/post-release-prep/codeql-cli-2.8.2
tamasvajk e808423
Treat path.Clean and filepath.Clean alike re: tainted path sanitization
smowton 807ef2e
Merge pull request #700 from smowton/smowton/fix/filepath-clean
owen-mc e7cf172
Release preparation for version 2.8.3
invalid-email-address 77b879f
Merge pull request #701 from github/release-prep/2.8.3
aibaars 4bd2553
Post-release preparation for codeql-cli-2.8.3
invalid-email-address be412b1
Merge pull request #702 from github/post-release-prep/codeql-cli-2.8.3
aibaars b96eba9
Release preparation for version 2.8.4
invalid-email-address 30bd1a6
Merge pull request #704 from github/release-prep/2.8.4
igfoo 9ba2192
Post-release preparation for codeql-cli-2.8.4
invalid-email-address 8a3a58c
Delete unused file DataFlowImplConsistency
owen-mc 79e6f78
Merge pull request #710 from owen-mc/delete-consistency
owen-mc e9acb4f
Merge pull request #706 from github/post-release-prep/codeql-cli-2.8.4
igfoo 9b6dd60
Address incorrectly reference parameter in QLdoc
rverme 314bd20
Merge pull request #711 from rverme/patch-1
smowton 950519c
Release preparation for version 2.8.5
invalid-email-address 837d1fb
Merge pull request #712 from github/release-prep/2.8.5
igfoo 469af4c
Post-release preparation for codeql-cli-2.8.5
invalid-email-address 603c1d5
Extend DataFlowCallable to include file scopes
owen-mc 880afea
Pretty-print empty interface without double space
owen-mc 76a0a51
Merge pull request #715 from owen-mc/print-empty-interface-with-singl…
owen-mc 6f6e8bf
Merge pull request #713 from github/post-release-prep/codeql-cli-2.8.5
igfoo b9ff1cc
Add change note
owen-mc 16c0f11
Bump minor version of packs
edoardopirovano f196538
Merge pull request #714 from owen-mc/fix-get-enclosing-callable
owen-mc 49e568e
Bump version of `suite-helpers` dependency
e3b7ba6
Revert "Bump version of `suite-helpers` dependency"
b953fe3
Merge pull request #716 from github/edoardo/3.5-mergeback
edoardopirovano f9f21e9
Integer conversion should ignore type assertions
owen-mc a8eeef6
Merge pull request #718 from owen-mc/fix-incorrect-integer-conversion…
smowton b6702b6
Improve documentation of CallExpr.getCalleeName
owen-mc 528a735
Improve CallNode.getCalleeName
owen-mc 373017a
Add tests for callees through function variables
owen-mc 69c9099
Look for callees through function variables
owen-mc 62489e1
Fix viableCallable for function variables
owen-mc 5f3b913
Add change note
owen-mc 355f4c6
Release preparation for version 2.9.0
invalid-email-address 6f91cc1
Merge pull request #719 from owen-mc/bugfix/find-callee-through-funct…
owen-mc d2d92fa
Merge pull request #723 from github/release-prep/2.9.0
MathiasVP 59cc289
Post-release preparation for codeql-cli-2.9.0
invalid-email-address b8165d4
Merge pull request #724 from github/post-release-prep/codeql-cli-2.9.0
MathiasVP bcd2c00
Release preparation for version 2.9.1
invalid-email-address ff677cd
Merge pull request #726 from github/release-prep/2.9.1
MathiasVP d2fccbe
Fix Beego references
cklin ee94eb5
Merge pull request #727 from cklin/fix-ql-comments-syntax
owen-mc 22ccbba
Run `go mod tidy -e` if go.mod exists
owen-mc 570d3f4
Use `os.Stat` instead of `os.File.Stat`
owen-mc fea657c
Post-release preparation for codeql-cli-2.9.1
invalid-email-address ef7363c
Merge pull request #732 from github/post-release-prep/codeql-cli-2.9.1
MathiasVP 7f0a379
Use Go 1.18
owen-mc f7dcb11
Extract uninstantiated generic types only
owen-mc 3952b1c
Extract type parameter types (and update dbscheme)
owen-mc b8ab46d
Add QL class for type parameter types
owen-mc e84db95
Extract generic function instantiations to new table
owen-mc a05a525
Extract generic type instantiations to new table
owen-mc 3510f2c
Support non-basic interfaces in extractor
owen-mc 1e08201
Extract type param declarations
owen-mc f908a6f
Rename `parm` to `param` for clarity
owen-mc 982f11f
Make ScopedObjectID take a function
owen-mc 213fa1f
Break out of loop when a match has been found
owen-mc 92c3314
Extract type parameters in types, not just decls
owen-mc 63d1663
bug fix: label pointer-typed receivers correctly
owen-mc 4d9937d
Add tests
owen-mc 0194eb9
Add an upgrade and downgrade script
owen-mc 1da5399
Fix obvious test failures
owen-mc 4fa972f
Rename variable for clarity
owen-mc 4828430
Extract all object types before emitting them
owen-mc 9abc7ea
Address review comments 1
owen-mc 59aa742
Add comments about entities without a parent scope
owen-mc 253ca2b
Address review comments 2
owen-mc 8276ca0
Use generic method not instantiated one in Uses
owen-mc 8c15199
Use generic struct field not instantiated one in Uses
owen-mc 25b91d8
Update tests
owen-mc 4e71ab5
Update comment above first extraction of packages
owen-mc 7a7ca61
Add data flow tests for generic structs, methods and functions
owen-mc ce9c9cf
`CallExpr.getCalleeExpr` should get uninstantiated function
owen-mc 26d4acd
generic function instantions aren't type exprs
owen-mc 5257c4a
Add control flow test
owen-mc 20562cb
Add missing `this.` to member predicate calls
owen-mc a8a351f
Improve comment
owen-mc 0dee215
Update CodeQL tests to go 1.18.1
owen-mc 3790c4e
Control flow for generic function instantiations
owen-mc 4a9aeac
Find callee through function instantiation
owen-mc ba147e8
Test calls through variables
owen-mc 2e8b9a9
Fix extractor crash when missing type information
owen-mc 06d1398
Fix panic when type is unknown
owen-mc aa62fab
Fix another place where type could be nil
owen-mc 7f1f428
Remove invalid code in test
owen-mc 8477053
Test calling generic functions from other files
owen-mc ac081dc
Make TypeParamParent map global
owen-mc d098bdc
Reintroduce noinlined predicate to fix performance
owen-mc 3c4b520
Fix type aliases for instantiated generic types
owen-mc d330033
Make objects-map-changed warning non-fatal
smowton 3129c3d
Remove commented-out debug code
smowton c0fbd03
Add qldoc for `getTermInIntersection`
smowton 2b51b42
fix https://github.com/github/codeql/issues/9097
440b311
Merge pull request #686 from owen-mc/extract-generics
smowton 7530943
Add change note announcing generics support
smowton 72022e6
Copyedit
smowton d9e7d34
Merge pull request #735 from github/smowton/admin/generics-change-note
smowton c703580
update fix
ebcb040
update fix
edbd5dd
Release preparation for version 2.9.2
invalid-email-address 3423729
Merge pull request #736 from github/release-prep/2.9.2
MathiasVP e68a727
Drop redundant columns from `files` and `folders` relations in `xml.d…
hvitved 11c95c5
Post-release preparation for codeql-cli-2.9.2
invalid-email-address 211580e
Merge pull request #738 from hvitved/xml-dbscheme-files-folders
smowton 252b190
Merge branch 'github:main' into main
cokeBeer 808dde2
add v2modulePath()
75f2edd
add v2modulePath()
aa2d445
add v1modulePath()
7f21c0c
fix format
2930bd4
Only attempt go.mod updating if go >= 1.16
smowton 32e2949
Merge pull request #734 from cokeBeer/main
smowton 77461f7
Merge pull request #730 from owen-mc/bugfix/build/go-mod-tidy
smowton 0b0161f
Merge pull request #737 from github/post-release-prep/codeql-cli-2.9.2
MathiasVP 3b4d04d
Update Lua tracing config.
criemen 415c3d1
Merge pull request #740 from github/criemen/lua-tracing-config
criemen aa514ff
codeql-go merge prep: move into go/ directory
cklin 097d518
Merge branch 'main' into cklin/merge-codeql-go-prep
cklin 1276c41
codeql-go merge prep: integrate go/ into codeql
cklin c58b539
Go: delete test qhelp file
cklin 7bc6c10
Go: fix search-path for 'make test'
aibaars 827c7ab
Go: fix search and tool paths for 'make test'
cklin 7f96319
Clean up direct references to codeql-go
cklin File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| { | ||
| "problemMatcher": [ | ||
| { | ||
| "owner": "codeql-query-format", | ||
| "pattern": [ | ||
| { | ||
| "regexp": "^((.*) would change by autoformatting\\.)$", | ||
| "file": 2, | ||
| "message": 1 | ||
| } | ||
| ] | ||
| } | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| { | ||
| "problemMatcher": [ | ||
| { | ||
| "owner": "codeql-syntax-check", | ||
| "pattern": [ | ||
| { | ||
| "regexp": "^((ERROR|WARNING): .* \\((.*):(\\d+),(\\d+)-\\d+\\))$", | ||
| "message": 1, | ||
| "file": 3, | ||
| "line": 4, | ||
| "col": 5, | ||
| "severity": 2 | ||
| } | ||
| ] | ||
| } | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| { | ||
| "problemMatcher": [ | ||
| { | ||
| "owner": "codeql-test-run", | ||
| "pattern": [ | ||
| { | ||
| "regexp": "(\\[.*\\] FAILED\\((RESULT|COMPILATION)\\) (.*))$", | ||
| "file": 3, | ||
| "message": 1 | ||
| } | ||
| ] | ||
| } | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| { | ||
| "problemMatcher": [ | ||
| { | ||
| "owner": "make", | ||
| "pattern": [ | ||
| { | ||
| "regexp": "^(make: \\*\\*\\* .*)$", | ||
| "message": 1 | ||
| } | ||
| ] | ||
| } | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,157 @@ | ||
| name: "Go: Run Tests" | ||
| on: [pull_request] | ||
| jobs: | ||
|
|
||
| test-linux: | ||
| name: Test Linux (Ubuntu) | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
|
|
||
| - name: Set up Go 1.18.1 | ||
| uses: actions/setup-go@v1 | ||
| with: | ||
| go-version: 1.18.1 | ||
| id: go | ||
|
|
||
| - name: Set up CodeQL CLI | ||
| run: | | ||
| echo "Removing old CodeQL Directory..." | ||
| rm -rf $HOME/codeql | ||
| echo "Done" | ||
| cd $HOME | ||
| echo "Downloading CodeQL CLI..." | ||
| LATEST=$(gh release list --repo https://github.com/github/codeql-cli-binaries | cut -f 1 | sort --version-sort | grep -v beta | tail -1) | ||
| gh release download --repo https://github.com/github/codeql-cli-binaries --pattern codeql-linux64.zip "$LATEST" | ||
| echo "Done" | ||
| echo "Unpacking CodeQL CLI..." | ||
| unzip -q codeql-linux64.zip | ||
| rm -f codeql-linux64.zip | ||
| echo "Done" | ||
| env: | ||
| GITHUB_TOKEN: ${{ github.token }} | ||
|
|
||
| - name: Check out code | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Enable problem matchers in repository | ||
| shell: bash | ||
| run: 'find .github/problem-matchers -name \*.json -exec echo "::add-matcher::{}" \;' | ||
|
|
||
| - name: Build | ||
| run: | | ||
| cd go | ||
| env PATH=$PATH:$HOME/codeql make | ||
|
|
||
| - name: Check that all QL and Go code is autoformatted | ||
| run: | | ||
| cd go | ||
| env PATH=$PATH:$HOME/codeql make check-formatting | ||
|
|
||
| - name: Compile qhelp files to markdown | ||
| run: | | ||
| cd go | ||
| env PATH=$PATH:$HOME/codeql QHELP_OUT_DIR=qhelp-out make qhelp-to-markdown | ||
|
|
||
| - name: Upload qhelp markdown | ||
| uses: actions/upload-artifact@v2 | ||
| with: | ||
| name: qhelp-markdown | ||
| path: go/qhelp-out/**/*.md | ||
|
|
||
| - name: Test | ||
| run: | | ||
| cd go | ||
| env PATH=$PATH:$HOME/codeql make test | ||
|
|
||
| test-mac: | ||
| name: Test MacOS | ||
| runs-on: macOS-latest | ||
| steps: | ||
| - name: Set up Go 1.18.1 | ||
| uses: actions/setup-go@v1 | ||
| with: | ||
| go-version: 1.18.1 | ||
| id: go | ||
|
|
||
| - name: Set up CodeQL CLI | ||
| run: | | ||
| echo "Removing old CodeQL Directory..." | ||
| rm -rf $HOME/codeql | ||
| echo "Done" | ||
| cd $HOME | ||
| echo "Downloading CodeQL CLI..." | ||
| LATEST=$(gh release list --repo https://github.com/github/codeql-cli-binaries | cut -f 1 | sort --version-sort | grep -v beta | tail -1) | ||
| gh release download --repo https://github.com/github/codeql-cli-binaries --pattern codeql-osx64.zip "$LATEST" | ||
| echo "Done" | ||
| echo "Unpacking CodeQL CLI..." | ||
| unzip -q codeql-osx64.zip | ||
| rm -f codeql-osx64.zip | ||
| echo "Done" | ||
| env: | ||
| GITHUB_TOKEN: ${{ github.token }} | ||
|
|
||
| - name: Check out code | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Enable problem matchers in repository | ||
| shell: bash | ||
| run: 'find .github/problem-matchers -name \*.json -exec echo "::add-matcher::{}" \;' | ||
|
|
||
| - name: Build | ||
| run: | | ||
| cd go | ||
| env PATH=$PATH:$HOME/codeql make | ||
|
|
||
| - name: Test | ||
| run: | | ||
| cd go | ||
| env PATH=$PATH:$HOME/codeql make test | ||
|
|
||
| test-win: | ||
| name: Test Windows | ||
| runs-on: windows-2019 | ||
| steps: | ||
| - name: Set up Go 1.18.1 | ||
| uses: actions/setup-go@v1 | ||
| with: | ||
| go-version: 1.18.1 | ||
| id: go | ||
|
|
||
| - name: Set up CodeQL CLI | ||
| run: | | ||
| echo "Removing old CodeQL Directory..." | ||
| rm -rf $HOME/codeql | ||
| echo "Done" | ||
| cd "$HOME" | ||
| echo "Downloading CodeQL CLI..." | ||
| LATEST=$(gh release list --repo https://github.com/github/codeql-cli-binaries | cut -f 1 | sort --version-sort | grep -v beta | tail -1) | ||
| gh release download --repo https://github.com/github/codeql-cli-binaries --pattern codeql-win64.zip "$LATEST" | ||
| echo "Done" | ||
| echo "Unpacking CodeQL CLI..." | ||
| unzip -q -o codeql-win64.zip | ||
| unzip -q -o codeql-win64.zip codeql/codeql.exe | ||
| rm -f codeql-win64.zip | ||
| echo "Done" | ||
| env: | ||
| GITHUB_TOKEN: ${{ github.token }} | ||
| shell: | ||
| bash | ||
|
|
||
| - name: Check out code | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Enable problem matchers in repository | ||
| shell: bash | ||
| run: 'find .github/problem-matchers -name \*.json -exec echo "::add-matcher::{}" \;' | ||
|
|
||
| - name: Build | ||
| run: | | ||
| $Env:Path += ";$HOME\codeql" | ||
| cd go | ||
| make | ||
|
|
||
| - name: Test | ||
| run: | | ||
| $Env:Path += ";$HOME\codeql" | ||
| cd go | ||
| make test |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,76 @@ | ||
| # Contributor Covenant Code of Conduct | ||
|
|
||
| ## Our Pledge | ||
|
|
||
| In the interest of fostering an open and welcoming environment, we as | ||
| contributors and maintainers pledge to make participation in our project and | ||
| our community a harassment-free experience for everyone, regardless of age, body | ||
| size, disability, ethnicity, sex characteristics, gender identity and expression, | ||
| level of experience, education, socio-economic status, nationality, personal | ||
| appearance, race, religion, or sexual identity and orientation. | ||
|
|
||
| ## Our Standards | ||
|
|
||
| Examples of behavior that contributes to creating a positive environment | ||
| include: | ||
|
|
||
| * Using welcoming and inclusive language | ||
| * Being respectful of differing viewpoints and experiences | ||
| * Gracefully accepting constructive criticism | ||
| * Focusing on what is best for the community | ||
| * Showing empathy towards other community members | ||
|
|
||
| Examples of unacceptable behavior by participants include: | ||
|
|
||
| * The use of sexualized language or imagery and unwelcome sexual attention or | ||
| advances | ||
| * Trolling, insulting/derogatory comments, and personal or political attacks | ||
| * Public or private harassment | ||
| * Publishing others' private information, such as a physical or electronic | ||
| address, without explicit permission | ||
| * Other conduct which could reasonably be considered inappropriate in a | ||
| professional setting | ||
|
|
||
| ## Our Responsibilities | ||
|
|
||
| Project maintainers are responsible for clarifying the standards of acceptable | ||
| behavior and are expected to take appropriate and fair corrective action in | ||
| response to any instances of unacceptable behavior. | ||
|
|
||
| Project maintainers have the right and responsibility to remove, edit, or | ||
| reject comments, commits, code, wiki edits, issues, and other contributions | ||
| that are not aligned to this Code of Conduct, or to ban temporarily or | ||
| permanently any contributor for other behaviors that they deem inappropriate, | ||
| threatening, offensive, or harmful. | ||
|
|
||
| ## Scope | ||
|
|
||
| This Code of Conduct applies within all project spaces, and it also applies when | ||
| an individual is representing the project or its community in public spaces. | ||
| Examples of representing a project or community include using an official | ||
| project e-mail address, posting via an official social media account, or acting | ||
| as an appointed representative at an online or offline event. Representation of | ||
| a project may be further defined and clarified by project maintainers. | ||
|
|
||
| ## Enforcement | ||
|
|
||
| Instances of abusive, harassing, or otherwise unacceptable behavior may be | ||
| reported by contacting the project team at opensource@github.com. All | ||
| complaints will be reviewed and investigated and will result in a response that | ||
| is deemed necessary and appropriate to the circumstances. The project team is | ||
| obligated to maintain confidentiality with regard to the reporter of an incident. | ||
| Further details of specific enforcement policies may be posted separately. | ||
|
|
||
| Project maintainers who do not follow or enforce the Code of Conduct in good | ||
| faith may face temporary or permanent repercussions as determined by other | ||
| members of the project's leadership. | ||
|
|
||
| ## Attribution | ||
|
|
||
| This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, | ||
| available at https://www.contributor-covenant.org/version/1/4/code-of-conduct/ | ||
|
|
||
| [homepage]: https://www.contributor-covenant.org | ||
|
|
||
| For answers to common questions about this code of conduct, see | ||
| https://www.contributor-covenant.org/faq/ |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does this do? And why does it only exist for go?
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a config file for https://lgtm.com/projects/g/github/codeql . These lines classify all Go source code in
go/ql/srcasexamplecode so LGTM will filter out any results in QHelp samples .See also: https://lgtm.com/projects/g/github/codeql-go/latest/files/?sort=name&dir=ASC&mode=heatmap&showExcluded=true and toggle the
show excluded filesfilter.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why don't other languages have a similar entry?