Documentation ¶
Index ¶
- Variables
- func ClearQuery(g *gocui.Gui, v *gocui.View) error
- func DisplayInformation(g *gocui.Gui, ag *askgit.AskGit, length time.Duration) error
- func GoLeft(g *gocui.Gui, v *gocui.View) error
- func GoRight(g *gocui.Gui, v *gocui.View) error
- func HandleClick(g *gocui.Gui, v *gocui.View) error
- func HandleCursor(g *gocui.Gui, v *gocui.View) error
- func JumpDown(g *gocui.Gui, v *gocui.View) error
- func JumpLeft(g *gocui.Gui, v *gocui.View) error
- func JumpRight(g *gocui.Gui, v *gocui.View) error
- func JumpUp(g *gocui.Gui, v *gocui.View) error
- func NextLine(g *gocui.Gui, v *gocui.View) error
- func NextView(g *gocui.Gui, v *gocui.View) error
- func PreviousLine(g *gocui.Gui, v *gocui.View) error
- func RunGUI(askgitInstance *askgit.AskGit, q string)
- func RunQuery(g *gocui.Gui, v *gocui.View) error
- func SetCurrentViewOnTop(g *gocui.Gui, name string) (*gocui.View, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var (
Queries = map[string]string{
"commit-info": "SELECT * FROM commits",
"distinct-authors": "SELECT DISTINCT author_email FROM commits",
"commits-per-author": `SELECT
author_email, count(*)
FROM commits GROUP BY author_email
ORDER BY count(*) DESC`,
"author-stats": `SELECT count(DISTINCT commits.id) AS commits, SUM(additions) AS additions, SUM(deletions) AS deletions, author_email
FROM commits LEFT JOIN stats ON commits.id = stats.commit_id
WHERE commits.parent_count < 2
GROUP BY author_email ORDER BY commits`,
"author-commits-dow": `SELECT
count(*) AS commits,
count(CASE WHEN strftime('%w',author_when)='0' THEN 1 END) AS sunday,
count(CASE WHEN strftime('%w',author_when)='1' THEN 1 END) AS monday,
count(CASE WHEN strftime('%w',author_when)='2' THEN 1 END) AS tuesday,
count(CASE WHEN strftime('%w',author_when)='3' THEN 1 END) AS wednesday,
count(CASE WHEN strftime('%w',author_when)='4' THEN 1 END) AS thursday,
count(CASE WHEN strftime('%w',author_when)='5' THEN 1 END) AS friday,
count(CASE WHEN strftime('%w',author_when)='6' THEN 1 END) AS saturday,
author_email
FROM commits GROUP BY author_email ORDER BY commits`,
"tables": `
SELECT name FROM sqlite_master
WHERE
type IN ('table','view') AND
name NOT LIKE 'sqlite_%'
`,
}
)
Functions ¶
func DisplayInformation ¶
Displays a selection of information into the Info view
func HandleCursor ¶
Makes sure Cursor is not more right or more down than allowed
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.