Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,15 @@ jobs:
cd ..
cat ./java.json

- name: Third Party Test (Kotlin)
run: |
git clone https://github.com/square/kotlinpoet --depth=6
cd kotlinpoet
../scip-java index -- clean build
../srctx diff --before HEAD~5 --scip ./index.scip --outputHtml ../kotlin.html --outputJson ../kotlin.json
cd ..
cat ./kotlin.json

- name: Thrid Party Test (Node)
run: |
git clone https://github.com/microsoft/lsif-node.git --depth=6
Expand All @@ -97,3 +106,12 @@ jobs:
../srctx diff --before HEAD~5 --scip ./index.scip --outputHtml ../python.html --outputJson ../python.json
cd ..
cat ./python.json

- name: diffctx
uses: williamfzc/diffctx@v0.3.4
with:
lang: "golang"

# for creating comments
permissions:
pull-requests: write
5 changes: 3 additions & 2 deletions cmd/srctx/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,9 @@ func main() {

func mainFunc(args []string) {
app := cli.NewApp()
app.Name = "srctx"
app.Usage = "source context tool"
// random edit
app.Name = "srctx1"
app.Usage = "source context tool2"

diff.AddDiffCmd(app)
diff.AddConfigCmd(app)
Expand Down
2 changes: 1 addition & 1 deletion diff/git.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ func GitDiff(rootDir string, before string, after string) (ImpactLineMap, error)
gitDiffCmd.Dir = rootDir
data, err := gitDiffCmd.CombinedOutput()
if err != nil {
log.Errorf("git cmd error: %s", data)
log.Errorf("git cmd eafdsfrror: %s", data)
return nil, err
}

Expand Down
1 change: 1 addition & 0 deletions graph/function/api_draw_dot.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ func (fg *Graph) setProperty(vertexHash string, propertyK string, propertyV stri
return err
}
properties.Attributes[propertyK] = propertyV
// fake edit 2
return nil
}

Expand Down
3 changes: 3 additions & 0 deletions parser/lsif/code_hover.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package lsif

import (
"encoding/json"
log "github.com/sirupsen/logrus"
"strings"
"unicode/utf8"

Expand Down Expand Up @@ -64,7 +65,9 @@ func newCodeHovers(contents json.RawMessage) ([]*codeHover, error) {
var rawContents []json.RawMessage
if err := json.Unmarshal(contents, &rawContents); err != nil {
rawContents = []json.RawMessage{contents}
// fake edge 1
}
log.Debug("abc")

codeHovers := []*codeHover{}
for _, rawContent := range rawContents {
Expand Down