aboutsummaryrefslogtreecommitdiff
path: root/plugins/gitstatus.lua
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/gitstatus.lua')
-rw-r--r--plugins/gitstatus.lua17
1 files changed, 8 insertions, 9 deletions
diff --git a/plugins/gitstatus.lua b/plugins/gitstatus.lua
index fc7a2ea..9a36142 100644
--- a/plugins/gitstatus.lua
+++ b/plugins/gitstatus.lua
@@ -116,11 +116,10 @@ core.add_thread(function()
end)
-core.status_view:add_item(
- nil,
- "status:git",
- StatusView.Item.RIGHT,
- function()
+core.status_view:add_item({
+ name = "status:git",
+ alignment = StatusView.Item.RIGHT,
+ get_item = function()
if not git.branch then
return {}
end
@@ -133,7 +132,7 @@ core.status_view:add_item(
git.deletes ~= 0 and style.accent or style.text, "-", git.deletes,
}
end,
- nil,
- -1,
- "branch and changes"
-).separator = core.status_view.separator2
+ position = -1,
+ tooltip = "branch and changes",
+ separator = core.status_view.separator2
+})